46 lines
850 B
YAML
46 lines
850 B
YAML
version: '3'
|
|
services:
|
|
nginx:
|
|
image: nginx:alpine
|
|
volumes:
|
|
- './conf/nginx:/etc/nginx'
|
|
- './static:/var/www/html'
|
|
restart: always
|
|
ports:
|
|
- '${APP_PORT:-80}:80'
|
|
networks:
|
|
pairent:
|
|
aliases:
|
|
- nginx
|
|
depends_on:
|
|
- back
|
|
back:
|
|
build:
|
|
context: ./pairent_backend
|
|
dockerfile: Dockerfile
|
|
networks:
|
|
pairent:
|
|
aliases:
|
|
- back
|
|
volumes:
|
|
- './pairent_backend:/opt/code'
|
|
environment:
|
|
DB_PASS: '${DB_PASSWORD}'
|
|
depends_on:
|
|
- db
|
|
db:
|
|
image: postgres
|
|
networks:
|
|
pairent:
|
|
aliases:
|
|
- db
|
|
volumes:
|
|
- './data/db:/etc/mysql'
|
|
environment:
|
|
POSTGRES_PASSWORD: '${DB_PASSWORD}'
|
|
POSTGRES_DB: 'pairent_db'
|
|
POSTGRES_USER: 'root'
|
|
|
|
networks:
|
|
pairent:
|
|
driver: bridge |