eb693b89d4
Signed-off-by: Huaxin Zhang <zhx_zhx12@163.com>
20 lines
549 B
YAML
20 lines
549 B
YAML
version: "3.7"
|
|
services:
|
|
frontend:
|
|
image: traefik:v2.4
|
|
command: --providers.docker --entrypoints.web.address=:80 --providers.docker.exposedbydefault=false
|
|
ports:
|
|
# The HTTP port
|
|
- "80:80"
|
|
volumes:
|
|
# So that Traefik can listen to the Docker events
|
|
- /var/run/docker.sock:/var/run/docker.sock
|
|
depends_on:
|
|
- backend
|
|
backend:
|
|
build: backend
|
|
labels:
|
|
- "traefik.enable=true"
|
|
- "traefik.http.routers.go.rule=Path(`/`)"
|
|
- "traefik.http.services.go.loadbalancer.server.port=80"
|