added healthcheck and release note
This commit is contained in:
26
compose.yml
26
compose.yml
@ -8,6 +8,7 @@ services:
|
||||
database__connection__user: root
|
||||
database__connection__database: ghost
|
||||
database__connection__password_FILE: /run/secrets/db_password
|
||||
# database__connection__password_FILE: /run/secrets/db_password
|
||||
url: https://$DOMAIN
|
||||
mail__transport: ${MAIL_TRANSPORT}
|
||||
mail__from: ${MAIL_FROM}
|
||||
@ -25,8 +26,10 @@ services:
|
||||
- source: ghost_entrypoint
|
||||
target: /abra-entrypoint.sh
|
||||
mode: 0555
|
||||
command: node current/index.js
|
||||
command: ["node", "current/index.js"]
|
||||
entrypoint: /abra-entrypoint.sh
|
||||
depends_on:
|
||||
- db
|
||||
networks:
|
||||
- proxy
|
||||
- backend
|
||||
@ -48,12 +51,12 @@ services:
|
||||
- "backupbot.backup=true"
|
||||
- "backupbot.backup.path=/var/lib/ghost/content"
|
||||
- "coop-cloud.${STACK_NAME}.version=0.1.0+5-alpine"
|
||||
# healthcheck:
|
||||
# test: ["CMD", "curl", "-f", "http://localhost"]
|
||||
# interval: 30s
|
||||
# timeout: 10s
|
||||
# retries: 10
|
||||
# start_period: 1m
|
||||
healthcheck:
|
||||
test: ["CMD", "wget", "--header=X-Forwarded-Proto: https", "--spider", "-q", "http://localhost:2368/ghost/api/admin/site"]
|
||||
interval: 30s
|
||||
timeout: 10s
|
||||
retries: 10
|
||||
start_period: 1m
|
||||
|
||||
db:
|
||||
image: mysql:8.0
|
||||
@ -68,10 +71,17 @@ services:
|
||||
deploy:
|
||||
labels:
|
||||
- "backupbot.backup=true"
|
||||
- "backupbot.backup.pre-hook=mysqldump -u root -pghost ghost --tab /var/lib/mysql-files/"
|
||||
- "backupbot.backup.pre-hook=mysqldump -u root -p\"$$(cat /run/secrets/db_password)\" ghost --tab /var/lib/mysql-files/"
|
||||
- "backupbot.backup.post-hook=rm -rf /var/lib/mysql-files/*"
|
||||
- "backupbot.backup.path=/var/lib/mysql-files/"
|
||||
|
||||
healthcheck:
|
||||
test: ["CMD", "mysqladmin", "ping", "-h", "localhost", "-u", "root", "-p\"$$(cat /run/secrets/db_password)\""]
|
||||
interval: 30s
|
||||
timeout: 10s
|
||||
retries: 10
|
||||
start_period: 1m
|
||||
|
||||
networks:
|
||||
proxy:
|
||||
external: true
|
||||
|
||||
Reference in New Issue
Block a user