EvalueTonSavoir/docker-compose.yaml
louis-antoine-etsmtl 05a7bd8d93 update dockercompose
2024-04-05 13:40:59 -04:00

65 lines
1.7 KiB
YAML

version: '3'
services:
frontend:
image: evaluetonsavoir/EvalueTonSavoir-frontend:latest
container_name: frontend
ports:
- "5173:5173"
backend:
image: evaluetonsavoir/EvalueTonSavoir-backend:latest
container_name: backend
ports:
- "3000:3000"
environment:
PORT: 3000
MONGO_URI: "mongodb://mongo:27017/evaluetonsavoir"
MONGO_DATABASE: evaluetonsavoir
EMAIL_SERVICE: gmail
SENDER_EMAIL: infoevaluetonsavoir@gmail.com
EMAIL_PSW: 'vvml wmfr dkzb vjzb'
JWT_SECRET: haQdgd2jp09qb897GeBZyJetC8ECSpbFJe
FRONTEND_URL: "http://evalsa.etsmtl.ca"
depends_on:
- mongo
# Ce conteneur sert de routeur pour assurer le bon fonctionnement de l'application
nginx:
image: evaluetonsavoir/EvalueTonSavoir-router:latest
container_name: nginx
ports:
- "80:80"
depends_on:
- backend
- frontend
# Ce conteneur est la base de données principale pour l'application
mongo:
image: mongo
container_name: mongo
ports:
- "27017:27017"
tty: true
volumes:
- mongodb_data:/data/db
restart: unless-stopped
# Ce conteneur assure que l'application est à jour en allant chercher s'il y a des mises à jours à chaque heure
watchtower:
image: containrrr/watchtower
container_name: watchtower
volumes:
- /var/run/docker.sock:/var/run/docker.sock
environment:
- TZ=America/Montreal
- WATCHTOWER_CLEANUP=true
- WATCHTOWER_DEBUG=true
- WATCHTOWER_INCLUDE_RESTARTING=true
- WATCHTOWER_POLL_INTERVAL=7200 # every hour
restart: unless-stopped
volumes:
mongodb_data:
external: false