Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- version: '3.9'
- name: admin-panel
- services:
- backend:
- container_name: admin-panel-api
- build:
- context: ..
- dockerfile: compose/Dockerfile
- working_dir: /code/src
- command: >
- sh -c "(cd .. && alembic upgrade head) &&
- uvicorn main:app --reload --host 0.0.0.0 --port 80 --forwarded-allow-ips='*' --proxy-headers"
- ports:
- - "8081:80"
- expose:
- - 80
- env_file:
- - .env
- volumes:
- - ../src:/code/src
- depends_on:
- - redis
- - db
- networks:
- - paynocchio
- db:
- image: postgres:14-alpine
- restart: always
- env_file:
- - .env.db
- expose:
- - 5432
- ports:
- - "5432:5432"
- networks:
- - paynocchio
- volumes:
- - postgres-data-local:/var/lib/postgresql/data/
- - ./init_db.sql:/docker-entrypoint-initdb.d/init_db.sql
- redis:
- image: redis:7-alpine3.18
- ports:
- - "6379:6379"
- networks:
- - paynocchio
- volumes:
- postgres-data-local:
- networks:
- paynocchio:
- driver: bridge
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement