project-knedita/docker-compose.yml

66 lines
1.2 KiB
YAML
Raw Normal View History

2023-06-20 20:05:15 +00:00
version: '3.8'
networks:
localstack-net:
name: localstack-net
driver: bridge
2023-06-20 20:05:15 +00:00
services:
api:
container_name: api
restart: unless-stopped
build:
context: .
dockerfile: Dockerfile
ports:
- 8080:8080
depends_on:
- postgres
- redis
- localstack
2023-06-20 20:05:15 +00:00
env_file:
- .env
postgres:
image: postgres:alpine
restart: unless-stopped
container_name: postgres
ports:
- 5432:5432
env_file:
- .env
volumes:
- postgres:/var/lib/postgresql/data
localstack:
image: localstack/localstack
container_name: localstack_main
restart: unless-stopped
networks:
- localstack-net
ports:
- 4566:4566
- 4572:4572
env_file:
- .env
volumes:
- localstack:/data
- '/var/run/docker.sock:/var/run/docker.sock'
2023-06-20 20:05:15 +00:00
redis:
image: redis:alpine
restart: unless-stopped
container_name: redis
ports:
- 6379:6379
command: redis-server --save 20 1 --loglevel warning --requirepass not_a_production_pass
volumes:
- redis:/data
2023-06-20 20:05:15 +00:00
volumes:
postgres:
name: backend-db
redis:
driver: local
localstack: