Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Nextcloud app health check improve #45

Open
a3linux opened this issue Dec 28, 2023 · 0 comments
Open

Nextcloud app health check improve #45

a3linux opened this issue Dec 28, 2023 · 0 comments

Comments

@a3linux
Copy link
Owner

a3linux commented Dec 28, 2023

Improve the health check of Nextcloudapp(service), then apply the restart: on-failure

Two options,

healthcheck:
test: curl -sSf 'http://localhost/status.php' | grep '"installed":true' | grep '"maintenance":false' | grep '"needsDbUpgrade":false' || exit 1
interval: 10s
timeout: 5s
retries: 10

or

  test: "SCRIPT_NAME=/var/www/html/status.php SCRIPT_FILENAME=/var/www/html/status.php REQUEST_METHOD=GET /usr/bin/cgi-fcgi -connect /var/run/php-fpm/php-fpm.sock / | grep '\"installed\":true' | grep '\"maintenance\":false' | grep '\"needsDbUpgrade\":false' || exit 1"

Reference,
nextcloud/docker#676

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant