split docker compose file
This commit is contained in:
43
docker/parts/docker-compose-external.yaml
Normal file
43
docker/parts/docker-compose-external.yaml
Normal file
@@ -0,0 +1,43 @@
|
||||
services:
|
||||
redis:
|
||||
image: redis/redis-stack:7.4.0-v3
|
||||
healthcheck:
|
||||
test: [ "CMD", "redis-cli", "--raw", "incr", "ping" ]
|
||||
volumes:
|
||||
- redis_data:/data
|
||||
- redisinsight_data:/redisinsight
|
||||
|
||||
flyway:
|
||||
image: flyway/flyway
|
||||
command: migrate
|
||||
depends_on:
|
||||
postgresql:
|
||||
condition: service_healthy
|
||||
volumes:
|
||||
- ../../migrations/events:/flyway/sql
|
||||
- ../flyway.conf:/flyway/conf/flyway.conf
|
||||
restart: no
|
||||
|
||||
postgresql:
|
||||
image: postgres:17.4
|
||||
environment:
|
||||
POSTGRES_PASSWORD_FILE: /run/secrets/postgresql_password
|
||||
POSTGRES_USER: event-demo
|
||||
secrets:
|
||||
- postgresql_password
|
||||
healthcheck:
|
||||
test: ["CMD-SHELL", "sh -c 'pg_isready -U event-demo'"]
|
||||
interval: 1s
|
||||
timeout: 5s
|
||||
retries: 10
|
||||
volumes:
|
||||
- postgresql_data:/var/lib/postgresql/data
|
||||
|
||||
secrets:
|
||||
postgresql_password:
|
||||
file: ../postgresql.secret
|
||||
|
||||
volumes:
|
||||
redis_data:
|
||||
redisinsight_data:
|
||||
postgresql_data:
|
||||
Reference in New Issue
Block a user