Loading Dockerfile +1 −0 Original line number Diff line number Diff line Loading @@ -26,6 +26,7 @@ COPY --from=compile /usr/local/lib/php /usr/local/lib/php RUN --mount=type=bind,source=scripts/install-wp.sh,target=/stage \ /stage ${wp_version} COPY probe.php wp-content/mu-plugins/ COPY opcache.ini /usr/local/etc/php/conf.d/opcache-recommended.ini COPY wp-config.php /usr/share/wordpress/wp-config.php COPY entrypoint.sh /bin/entrypoint Loading probe.php 0 → 100644 +16 −0 Original line number Diff line number Diff line <?php /** * Plugin Name: Liveness probe * Description: Responds to requests to /.probe with an HTTP code indicating the * status of the app * Licence: MPL-2.0 * Author: Dominik Sekotill */ if ( parse_url($_SERVER['REQUEST_URI'], PHP_URL_PATH) == '/.probe' ): add_filter('option_active_plugins', function( $plugins ) { return array(); }); add_action('setup_theme', function() { exit(200); }); endif; Loading
Dockerfile +1 −0 Original line number Diff line number Diff line Loading @@ -26,6 +26,7 @@ COPY --from=compile /usr/local/lib/php /usr/local/lib/php RUN --mount=type=bind,source=scripts/install-wp.sh,target=/stage \ /stage ${wp_version} COPY probe.php wp-content/mu-plugins/ COPY opcache.ini /usr/local/etc/php/conf.d/opcache-recommended.ini COPY wp-config.php /usr/share/wordpress/wp-config.php COPY entrypoint.sh /bin/entrypoint Loading
probe.php 0 → 100644 +16 −0 Original line number Diff line number Diff line <?php /** * Plugin Name: Liveness probe * Description: Responds to requests to /.probe with an HTTP code indicating the * status of the app * Licence: MPL-2.0 * Author: Dominik Sekotill */ if ( parse_url($_SERVER['REQUEST_URI'], PHP_URL_PATH) == '/.probe' ): add_filter('option_active_plugins', function( $plugins ) { return array(); }); add_action('setup_theme', function() { exit(200); }); endif;