ERROR - Container didn't respond to HTTP pings on port: 80 or <port no.>, failing site start. See container logs for debugging.

Sriharsha Ramachandra 5 Reputation points
2023-06-20T12:38:05.94+00:00

I am trying to run a node js container, using a docker image in acr. The docker image is running well in the local, but when trying to run on app services, it's saying this

ERROR - Container didn't respond to HTTP pings on port: 80 or <port no.>, failing site start. See container logs for debugging.

Seen other questions related to this, but none seem to point out the proper solution

Any known solution for this problem?

Tried below things

  1. Restarted -- multiple times
  2. Set below mentioned Env variables as well

App Details
Node js Application

Docker is exposing 8080 port
App running on 8080 port

gave PORT as env variable which is set to 8080 - used in App to run the server

set WEBSITES_PORT to 8080

gave high number for WEBSITES_CONTAINER_START_TIME_LIMIT

Stopped and started the container multiple times

Azure App Service
Azure App Service
Azure App Service is a service used to create and deploy scalable, mission-critical web apps.
8,790 questions
0 comments No comments
{count} votes

2 answers

Sort by: Most helpful
  1. Grmacjon-MSFT 19,076 Reputation points Moderator
    2023-06-22T06:24:19.4966667+00:00

    @Sriharsha Ramachandra

    Hi@Sriharsha Ramachandra , we're sorry to hear you're facing this issue. thanks for sharing all the troubleshooting steps you've tried so far. You can also try the following:

    1. Expose port 80 in your Dockerfile
    2. Set DEBUG = TRUE
    3. Add these values in app settings:
    • Port:80 (port 80 is the default)
    • WEBSITED_PORT:80
    1. Restart your container

    If the issue persists after, could you please send us an email to AzCommunity[at]Microsoft[dot]com with the below details, so that we can enable a one-time-free support for you to work closely on this issue? Please include: Email subject: <Attn - Grace > , Thread URL: <Microsoft Q&A Thread> , Subscription ID: <your Azure subscription id>

    Let me know here once the email is sent along with above requested details.

    Thanks,

    Grace


  2. Karlsson Anja 1 Reputation point
    2023-10-27T06:40:39.95+00:00

    Hi,

    Had the same issue but my dockerfile exposed 80 and 443.

    Changing to port 8080 in dockerfile and both PORT and WEBSITED_PORT to 8080 made it work for me.

    Best,
    Anja


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.