Set outer ports in .env

This commit is contained in:
cdricms
2025-01-14 14:10:40 +01:00
parent fd834ea84a
commit 8aadc810d1
5 changed files with 26 additions and 17 deletions

View File

@@ -2,11 +2,9 @@ services:
latosa-escrima.fr-frontend:
container_name: latosa-frontend
image: cems.dev:5000/latosa-escrima.fr:latest
env_file: .env
ports:
- 3000:${FRONTEND_PORT}
environment:
- NODE_ENV=production
- FRONTEND_PORT=${FRONTEND_PORT}
- ${FRONTEND_PORT}:${FRONTEND_DOCKER_PORT}
restart: always # Ensures the container restarts on failure or Docker restart
networks:
- le-network
@@ -16,22 +14,17 @@ services:
context: ./backend/
dockerfile: Dockerfile
env_file: .env
environment:
- PORT="3001"
ports:
- "3001:${BACKEND_PORT}"
- ${BACKEND_PORT}:${BACKEND_DOCKER_PORT}
networks:
- le-network
psql:
container_name: latosa-database
image: postgres:17.2-alpine
restart: always
environment:
POSTGRES_USER: ${POSTGRES_USER}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
POSTGRES_DB: ${POSTGRES_DB}
env_file: .env
ports:
- "5432:5432"
- ${POSTGRES_PORT}:${POSTGRES_DOCKER_PORT}
volumes:
- le-data:/var/lib/postgresql/data
networks: