How to troubleshoot failing health checks with the App Platform & Dockerfile setup

I’m trying to understand why my healthchecks are failing, and frankly it could be any number of issues, but I can’t even understand how I can properly troubleshoot this.

I’m using the App Platform service, and have configured a very basic Dockerfile to spin up a wordpress site.

The build seems to succeed without issue, but the health check fails without giving an error or even sharing what the response was.

Any tips on what might be happening would be great, or tips on how to get further with troubleshooting with this service.

FROM wordpress

COPY wp-content/plugins/ /var/www/html/wp-content/plugins/
COPY wp-content/themes/ /var/www/html/wp-content/themes/

RUN echo "ServerName localhost" >> /etc/apache2/apache2.conf


Side note: Running the docker run command locally seems to work fine, and exposes port 8080 as I would expect. docker run --name some-wordpress -p 8080:80 -d wordpress

Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Bobby Iliev
Site Moderator
Site Moderator badge
April 1, 2023

Hi there,

In your apache2.conf is the listen port set to 80 or 8080?

The Docker run command that you’ve shared indicates that the Apache listen port is 80, if this is indeed the case, you will have to change the EXPOSE port from 8080 to 80 and it should work as normal.

Let me know how it goes!



Try DigitalOcean for free

Click below to sign up and get $200 of credit to try our products over 60 days!

Sign up

Get our biweekly newsletter

Sign up for Infrastructure as a Newsletter.

Hollie's Hub for Good

Working on improving health and education, reducing inequality, and spurring economic growth? We'd like to help.

Become a contributor

Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.

Welcome to the developer cloud

DigitalOcean makes it simple to launch in the cloud and scale up as you grow — whether you're running one virtual machine or ten thousand.

Learn more
DigitalOcean Cloud Control Panel