moving to docker

This commit is contained in:
2023-05-14 20:28:29 +03:00
parent 6f7219ff7b
commit d5802fa48f
62 changed files with 87 additions and 0 deletions

View File

@ -0,0 +1,34 @@
services:
api:
build:
context: api
ports:
- "5000"
environment:
- POSTGRES_PASSWORD=password
- POSTGRES_USER=postgres
- POSTGRES_DB=flask
- PYTHONBUFFERED=0
react:
build:
context: react
ports:
- "3000"
nginx:
image: nginx:1.23.4
volumes:
- ./nginx.conf:/etc/nginx/conf.d/default.conf:ro
- ./static:/static
depends_on:
- api
ports:
- "3000:3000"
postgres:
image: postgres:15.1
restart: always
volumes:
- ./postgres_data:/var/lib/postgresql/data/
environment:
POSTGRES_USER: user
POSTGRES_PASSWORD: password
POSTGRES_DB: db