feat: add docker healthcheck to dokku container

The official dokku/dokku image gains a HEALTHCHECK directive backed by a loopback-only HTTP endpoint at `127.0.0.1:18080/_dokku/health`. The endpoint reports 200 once first-boot bootstrap finishes, sshd and nginx are accepting connections, and `dokku ps:restore` completes; otherwise it returns 503. Changes are scoped to the Docker overlay and Dockerfile so debian-package installs are unaffected.
This commit is contained in:
Jose Diaz-Gonzalez
2026-05-10 21:17:09 -04:00
parent a553f04966
commit cc0843391f
5 changed files with 60 additions and 3 deletions

View File

@@ -81,3 +81,6 @@ RUN \
&& rm -f /usr/local/openresty/nginx/conf/sites-enabled/default /usr/share/openresty/html/index.html \
&& sed -i '/imklog/d' /etc/rsyslog.conf \
&& rm -f /var/log/btmp /var/log/wtmp /var/log/*log /var/log/apt/* /var/log/dokku/*.log /var/log/nginx/* /var/log/openresty/*
HEALTHCHECK --interval=30s --timeout=10s --start-period=5m --retries=3 \
CMD curl -fsS http://127.0.0.1:18080/_dokku/health || exit 1