88 lines
1.7 KiB
YAML
88 lines
1.7 KiB
YAML
version: "3.3"
|
|
|
|
services:
|
|
|
|
nginx:
|
|
build:
|
|
context : ./
|
|
dockerfile: ./dockerfiles/Dockerfile.nginx
|
|
container_name: nginx
|
|
env_file: .env
|
|
depends_on:
|
|
- backend
|
|
ports:
|
|
- 80:80
|
|
# - 443:443
|
|
volumes:
|
|
- ./frontend:/var/www/html
|
|
restart: unless-stopped
|
|
networks:
|
|
- pongNetwork
|
|
|
|
backend:
|
|
build:
|
|
context : ./
|
|
dockerfile: ./dockerfiles/Dockerfile.backEnd
|
|
container_name: backend
|
|
ports:
|
|
- 5000:5000
|
|
env_file: .env
|
|
volumes:
|
|
- ./frontend:/var/www/html
|
|
# volumes:
|
|
# - ./backend:/home/node/app
|
|
depends_on:
|
|
- postgresql
|
|
restart: unless-stopped
|
|
networks:
|
|
- pongNetwork
|
|
|
|
postgresql:
|
|
build: #./dockerfiles/Dockerfile.PostgreSQL
|
|
context : ./
|
|
dockerfile: ./dockerfiles/Dockerfile.PostgreSQL
|
|
container_name: postgresql
|
|
#image: mariadb:homemade
|
|
ports:
|
|
- 5432:5432
|
|
# - ${POSTGRES_PORT}:${POSTGRES_PORT}
|
|
env_file: .env
|
|
#volumes:
|
|
# - dbdata:/var/lib/mysql
|
|
networks:
|
|
- pongNetwork
|
|
restart: unless-stopped
|
|
|
|
networks:
|
|
pongNetwork:
|
|
driver: bridge
|
|
|
|
volumes:
|
|
front_files:
|
|
driver: local
|
|
driver_opts:
|
|
type: none
|
|
o: 'bind'
|
|
device: '/frontend'
|
|
dbdata:
|
|
driver: local
|
|
driver_opts:
|
|
type: none
|
|
o: 'bind'
|
|
device: '/home/apommier/data/mariadb'
|
|
|
|
# version: "3.3"
|
|
# services:
|
|
# backend:
|
|
# build:
|
|
# context: ./dockerfiles
|
|
# dockerfile: Dockerfile.backEnd
|
|
# ports:
|
|
# - "5000:5000"
|
|
# nginx:
|
|
# restart: always
|
|
# build:
|
|
# context: ./dockerfiles
|
|
# dockerfile: Dockerfile.nginx
|
|
# ports:
|
|
# - "80:80" |