Deploy https://gallery.ecr.aws/docker/library/httpd to apprunner failed

0

I tried to deploy https://gallery.ecr.aws/docker/library/httpd to apprunner and it failed.

Service settings has

Service name
sampleapprunner-service
Virtual CPU & memory
1 vCPU & 2 GB
Port
8080

App Runner event logs

02-01-2024 01:11:11 PM [AppRunner] Deployment with ID : d706d4935b7840d4ba12ff7ec8ac3a86 started. Triggering event : SERVICE_CREATE
02-01-2024 01:11:11 PM [AppRunner] Deployment Artifact: [Repo Type: ECR-Public], [Image URL: public.ecr.aws/docker/library/httpd], [Image Tag: alpine3.19]
02-01-2024 01:11:37 PM [AppRunner] Pulling image public.ecr.aws/docker/library/httpd from ECR-Public repository.
02-01-2024 01:11:38 PM [AppRunner] Successfully pulled your application image from ECR.
02-01-2024 01:11:48 PM [AppRunner] Provisioning instances and deploying image for publicly accessible service.
02-01-2024 01:11:58 PM [AppRunner] Performing health check on protocol `TCP` [Port: '8080'].
02-01-2024 01:18:09 PM [AppRunner] Health check failed on protocol `TCP` [Port: '8080']. Check your configured port number. For more information, see the application logs.
02-01-2024 01:18:21 PM [AppRunner] Deployment with ID : d706d4935b7840d4ba12ff7ec8ac3a86 failed. Failure reason : Health check failed.

Health check settings

Protocol
TCP
Path
—
Timeout
5 seconds
Interval
10 seconds
Unhealthy threshold
5 requests
Health threshold
1 requests
gefragt vor 3 Monaten158 Aufrufe
1 Antwort
0

Hi,

based on https://gallery.ecr.aws/docker/library/httpd

The container responds initially on port 80. There is a port remapping done to 8080 via -p on the doc

Then, run the commands to build and run the Docker image:

$ docker build -t my-apache2 .
$ docker run -dit --name my-running-app -p 8080:80 my-apache2

Best,

Didier

profile pictureAWS
EXPERTE
beantwortet vor 3 Monaten
  • Can we achieve this port mapping for App runner from AWS console?

Du bist nicht angemeldet. Anmelden um eine Antwort zu veröffentlichen.

Eine gute Antwort beantwortet die Frage klar, gibt konstruktives Feedback und fördert die berufliche Weiterentwicklung des Fragenstellers.

Richtlinien für die Beantwortung von Fragen