compose fixes

This commit is contained in:
Maxim Dolgushin 2023-11-06 14:41:11 +07:00
parent 6c1792f023
commit b2417d9100
2 changed files with 19 additions and 19 deletions

@ -39,24 +39,23 @@ services:
- 8082:8000
- 9092:9000
depends_on:
- customer-db
- customer-migration
- redpanda
customer-db:
condition: service_started
customer-migration:
condition: service_completed_successfully
redpanda:
condition: service_healthy
networks:
- test
customer-migration:
container_name: customer-migration
build:
context: ../../.
dockerfile: Dockerfile
target: test
command:
[
"sh",
"-c",
'migrate -source file://migrations -database "mongodb://test:test@customer-db:27017/admin?authSource=admin" up',
]
image: alpine
command: migrate -source file://migrations -database "mongodb://test:test@customer-db:27017/admin" up
volumes:
- ../../migrations/test:/app/migrations:ro
- ../../tools/migrate:/usr/local/bin/migrate:ro
working_dir: /app
depends_on:
- customer-db
networks:
@ -105,17 +104,18 @@ services:
networks:
- test
healthcheck:
test: ["CMD-SHELL", "rpk cluster health | grep -E 'Healthy:.+true' || exit 1"]
interval: 15s
timeout: 3s
test: rpk cluster health | grep -q 'Healthy:.*true'
interval: 2s
timeout: 2s
retries: 5
start_period: 5s
console:
tty: true
container_name: customer-console
image: docker.redpanda.com/redpandadata/console:v2.2.4
entrypoint: /bin/sh
command: -c "echo \"$$CONSOLE_CONFIG_FILE\" > /tmp/config.yml; /app/console"
entrypoint: ''
command: sh -c 'echo "$$CONSOLE_CONFIG_FILE" > /tmp/config.yml && exec /app/console'
environment:
CONFIG_FILEPATH: /tmp/config.yml
CONSOLE_CONFIG_FILE: |
@ -172,4 +172,4 @@ services:
CONNECT_LOG_LEVEL: info
networks:
test:
test:

0
tools/migrate Normal file → Executable file