Update docker-compose.yml

add healthchecks and depends_on
pull/23/head
LRVT 2024-03-23 03:13:53 +01:00 zatwierdzone przez GitHub
rodzic df759de44b
commit 0487485c06
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: B5690EEEBB952194
1 zmienionych plików z 10 dodań i 1 usunięć

Wyświetl plik

@ -6,8 +6,13 @@ services:
image: ghost:5-alpine
container_name: ghost
restart: always
depends_on:
database:
condition: service_healthy
expose:
- 2368
ports:
- 8080:2368
- 2368:2368
volumes:
- ${DOCKER_VOLUME_STORAGE:-/mnt/docker-volumes}/ghost/content:/var/lib/ghost/content
environment:
@ -39,6 +44,10 @@ services:
image: mysql:8
container_name: ghost_db
restart: always
healthcheck:
test: ["CMD", 'mysqladmin', 'ping', '-h', 'localhost', '-u', 'root', '-p$$DB_ROOT_PASS' ]
timeout: 20s
retries: 10
volumes:
- ${DOCKER_VOLUME_STORAGE:-/mnt/docker-volumes}/ghost/mysql:/var/lib/mysql
expose: