TP_JO2024/docker-compose.yaml

88 lines
3 KiB
YAML
Raw Permalink Normal View History

2024-03-27 13:17:05 +00:00
version: "3.3"
services:
traefik:
image: "traefik:v2.11"
2024-03-27 16:19:37 +00:00
restart: unless-stopped
2024-03-27 13:17:05 +00:00
container_name: "proxy"
command:
- "--log.level=DEBUG"
- "--providers.docker=true"
- "--providers.docker.exposedbydefault=false"
- "--entrypoints.web.address=:8082"
ports:
- "8082:8082"
volumes:
- "/var/run/docker.sock:/var/run/docker.sock:ro"
2024-03-27 16:19:37 +00:00
home:
image: "jo2024/home"
restart: unless-stopped
container_name: "home-service"
build:
context: .
dockerfile: ./home/Dockerfile
labels:
- "traefik.enable=true"
- "traefik.http.routers.home-service.entrypoints=web"
- "traefik.http.routers.home.rule=PathPrefix(`/`)"
- "traefik.http.routers.home.middlewares=home-stripprefix"
- "traefik.http.middlewares.home-stripprefix.stripprefix.prefixes=/"
- "traefik.http.routers.home-service.priority=1"
- "traefik.http.routers.home-service.service=home-service"
- "traefik.http.services.home-service.loadbalancer.server.port=80"
- "traefik.http.services.home-service.loadbalancer.server.scheme=http"
- "traefik.http.services.home-service.loadbalancer.passhostheader=true"
2024-03-27 13:17:05 +00:00
athlete:
image: "jo2024/athlete"
2024-03-27 16:19:37 +00:00
restart: unless-stopped
2024-03-27 13:17:05 +00:00
container_name: "athlete-service"
build:
context: .
dockerfile: ./athlete/Dockerfile
labels:
- "traefik.enable=true"
2024-03-27 16:19:37 +00:00
- "traefik.http.routers.athletes-service.entrypoints=web"
- "traefik.http.routers.athletes.rule=PathPrefix(`/athletes{regex:$$|/.*}`) || PathPrefix(`/swagger{regex:$$|/.*}`)"
- "traefik.http.routers.athletes.middlewares=athletes-stripprefix"
- "traefik.http.middlewares.athletes-stripprefix.stripprefix.prefixes=/athletes"
2024-03-27 13:17:05 +00:00
volumes:
- "athlete:/app/data"
discipline:
image: "jo2024/discipline"
2024-03-27 16:19:37 +00:00
restart: unless-stopped
2024-03-27 13:17:05 +00:00
container_name: "discipline-service"
build:
context: .
dockerfile: ./discipline/Dockerfile
labels:
- "traefik.enable=true"
- "traefik.http.routers.disciplines-service.entrypoints=web"
- "traefik.http.routers.disciplines.rule=PathPrefix(`/disciplines{regex:$$|/.*}`)"
- "traefik.http.routers.disciplines.middlewares=disciplines-stripprefix"
- "traefik.http.middlewares.disciplines-stripprefix.stripprefix.prefixes=/disciplines"
volumes:
2024-03-27 14:31:11 +00:00
- "discipline:/app/data"
medaille:
image: "jo2024/medaille"
2024-03-27 16:19:37 +00:00
restart: unless-stopped
2024-03-27 14:31:11 +00:00
container_name: "medaille-service"
build:
context: .
dockerfile: ./medaille/Dockerfile
labels:
- "traefik.enable=true"
- "traefik.http.routers.medaille-service.entrypoints=web"
- "traefik.http.routers.medaille.rule=PathPrefix(`/medailles{regex:$$|/.*}`)"
- "traefik.http.routers.medaille.middlewares=medaille-stripprefix"
- "traefik.http.middlewares.medaille-stripprefix.stripprefix.prefixes=/medailles"
volumes:
- "medaille:/app/data"
volumes:
athlete:
discipline:
medaille: