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
posta 3 mesi fa157 visualizzazioni
1 Risposta
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
ESPERTO
con risposta 3 mesi fa
  • Can we achieve this port mapping for App runner from AWS console?

Accesso non effettuato. Accedi per postare una risposta.

Una buona risposta soddisfa chiaramente la domanda, fornisce un feedback costruttivo e incoraggia la crescita professionale del richiedente.

Linee guida per rispondere alle domande