postcat/docker-compose.yml

40 lines
818 B
YAML
Raw Normal View History

2022-11-01 21:41:26 +08:00
version: '3'
services:
postcat:
2022-11-01 21:41:26 +08:00
# build: 从当前路径构建镜像
build:
context: .
dockerfile: Dockerfile
target: production
image: eolinker/postcat:${VERSION}
container_name: postcat
2022-11-01 21:41:26 +08:00
restart: always
extra_hosts:
- 'host.docker.internal:host-gateway'
ports:
- '8000:80'
networks:
- postcat_net
2022-11-01 21:41:26 +08:00
postcat-test-server:
2022-11-01 21:41:26 +08:00
# build: 从当前路径构建镜像
build:
context: .
dockerfile: Dockerfile
target: builder
image: eolinker/postcat-test-server:${VERSION}
container_name: postcat-test-server
2022-11-01 21:41:26 +08:00
restart: always
extra_hosts:
- 'host.docker.internal:host-gateway'
ports:
- '4201:4201'
- '4202:4202'
networks:
- postcat_net
2022-11-01 21:41:26 +08:00
networks:
postcat_net:
name: postcat_net