mirror of
https://github.com/frappe/frappe_docker.git
synced 2026-06-17 13:55:08 +00:00
feat(mariadb): make use of healthcheck.sh
This commit is contained in:
parent
d23176ca34
commit
2be02ab112
3 changed files with 10 additions and 8 deletions
|
|
@ -3,8 +3,6 @@ services:
|
|||
environment:
|
||||
MYSQL_ROOT_PASSWORD: !reset null
|
||||
MYSQL_ROOT_PASSWORD_FILE: /run/secrets/db_password
|
||||
healthcheck:
|
||||
test: mariadb-admin ping -h localhost --password="$(cat /run/secrets/db_password)"
|
||||
secrets:
|
||||
- db_password
|
||||
|
||||
|
|
|
|||
|
|
@ -6,9 +6,11 @@ services:
|
|||
image: mariadb:11.8
|
||||
restart: unless-stopped
|
||||
healthcheck:
|
||||
test: mariadb-admin ping -h localhost --password=${DB_PASSWORD:-changeit}
|
||||
interval: 1s
|
||||
retries: 20
|
||||
test: ["CMD", "healthcheck.sh", "--connect", "--innodb_initialized"]
|
||||
start_period: 5s
|
||||
interval: 5s
|
||||
timeout: 5s
|
||||
retries: 5
|
||||
command:
|
||||
- --character-set-server=utf8mb4
|
||||
- --collation-server=utf8mb4_unicode_ci
|
||||
|
|
|
|||
|
|
@ -10,9 +10,11 @@ services:
|
|||
db:
|
||||
image: mariadb:11.8
|
||||
healthcheck:
|
||||
test: mariadb-admin ping -h localhost --password=${DB_PASSWORD:-123}
|
||||
interval: 1s
|
||||
retries: 20
|
||||
test: ["CMD", "healthcheck.sh", "--connect", "--innodb_initialized"]
|
||||
start_period: 5s
|
||||
interval: 5s
|
||||
timeout: 5s
|
||||
retries: 5
|
||||
restart: unless-stopped
|
||||
command:
|
||||
- --character-set-server=utf8mb4
|
||||
|
|
|
|||
Loading…
Reference in a new issue