From d608b4595044d31f3346fcc85161d83aae9b5a10 Mon Sep 17 00:00:00 2001 From: Tim de Pater Date: Sat, 5 Jan 2019 09:27:58 +0100 Subject: [PATCH] Added HEALTHCHECK instruction to the Dockefile and enabled PHP FPM ping path --- Dockerfile | 2 ++ config/fpm-pool.conf | 3 +++ 2 files changed, 5 insertions(+) diff --git a/Dockerfile b/Dockerfile index e76ef71..a362c5d 100644 --- a/Dockerfile +++ b/Dockerfile @@ -24,3 +24,5 @@ COPY src/ /var/www/html/ EXPOSE 80 443 CMD ["/usr/bin/supervisord", "-c", "/etc/supervisor/conf.d/supervisord.conf"] + +HEALTHCHECK --timeout=10s CMD curl --silent --fail http://127.0.0.1/fpm-ping diff --git a/config/fpm-pool.conf b/config/fpm-pool.conf index 741c1ed..67cd711 100644 --- a/config/fpm-pool.conf +++ b/config/fpm-pool.conf @@ -36,3 +36,6 @@ clear_env = no ; Catch output from PHP catch_workers_output = yes + +; Enable ping page to use in healthcheck +ping.path = /fpm-ping