mirror of
https://github.com/LucasVbr/game-lib.git
synced 2026-05-13 17:21:51 +00:00
chore: update docker-compose configuration for web-legacy and web services
This commit is contained in:
@@ -27,9 +27,20 @@ build:
|
|||||||
logs:
|
logs:
|
||||||
$(DC) logs -f $(service)
|
$(DC) logs -f $(service)
|
||||||
|
|
||||||
|
## shell: Open a shell in the application container
|
||||||
|
.PHONY: shell
|
||||||
shell:
|
shell:
|
||||||
$(DC) exec $(service) sh
|
$(DC) exec $(service) sh
|
||||||
|
|
||||||
|
## prune: Stop the application and remove volumes
|
||||||
|
.PHONY: prune
|
||||||
|
prune:
|
||||||
|
$(DC) down -v
|
||||||
|
|
||||||
|
## restart: Restart the application
|
||||||
|
.PHONY: restart
|
||||||
|
restart: down up
|
||||||
|
|
||||||
# https://stackoverflow.com/a/6273809/1826109
|
# https://stackoverflow.com/a/6273809/1826109
|
||||||
%:
|
%:
|
||||||
@:
|
@:
|
||||||
|
|||||||
+15
-1
@@ -4,13 +4,27 @@ services:
|
|||||||
web-legacy:
|
web-legacy:
|
||||||
image: caddy:alpine
|
image: caddy:alpine
|
||||||
volumes:
|
volumes:
|
||||||
- ./apps/web:/usr/share/caddy:ro
|
- ./apps/web-legacy:/usr/share/caddy:ro
|
||||||
labels:
|
labels:
|
||||||
- "traefik.enable=true"
|
- "traefik.enable=true"
|
||||||
- "traefik.http.routers.${PROJECT}_web_legacy.rule=Host(`web-legacy.${PROJECT}.localhost`)"
|
- "traefik.http.routers.${PROJECT}_web_legacy.rule=Host(`web-legacy.${PROJECT}.localhost`)"
|
||||||
- "traefik.http.services.${PROJECT}_web_legacy.loadbalancer.server.port=80"
|
- "traefik.http.services.${PROJECT}_web_legacy.loadbalancer.server.port=80"
|
||||||
networks:
|
networks:
|
||||||
- traefik
|
- traefik
|
||||||
|
|
||||||
|
web:
|
||||||
|
build:
|
||||||
|
context: ./apps/web
|
||||||
|
target: ${ENV_MODE:-production}
|
||||||
|
volumes:
|
||||||
|
- ./apps/web:/app:cached
|
||||||
|
- /app/node_modules
|
||||||
|
labels:
|
||||||
|
- "traefik.enable=true"
|
||||||
|
- "traefik.http.routers.${PROJECT}_web.rule=Host(`web.${PROJECT}.localhost`)"
|
||||||
|
- "traefik.http.services.${PROJECT}_web.loadbalancer.server.port=3000"
|
||||||
|
networks:
|
||||||
|
- traefik
|
||||||
|
|
||||||
networks:
|
networks:
|
||||||
traefik:
|
traefik:
|
||||||
|
|||||||
Reference in New Issue
Block a user