I'm attempting to deploy a docker image from AWS ECR to Elastic Beanstalk. I've set up all required permissions for Elastic Beanstalk to both S3 and ECR. Communication between these services seems fine, however I get the following errors when attempting to fire up an Elastic Beanstalk environment:
No Docker image specified in either Dockerfile or Dockerrun.aws.json. Abort deployment.
[Instance: i-01cf0bac1863e4eda] Command failed on instance. Return code: 1 Output: No Docker image specified in either Dockerfile or Dockerrun.aws.json. Abort deployment. Hook /opt/elasticbeanstalk/hooks/appdeploy/pre/03build.sh failed. For more detail, check /var/log/eb-activity.log using console or EB CLI.
I'm uploading a single Dockerrun.aws.json
which points to the image on ECR. Below is my Dockerrun.aws.json
file:
{
"AWSEBDockerrunVersion": "1",
"containerDefinitions": {
"Name": "***.eu-central-1.amazonaws.com/***:latest",
"Update": "true"
},
"Ports": [
{
"ContainerPort": "5000"
}
],
"Logging": "/var/log/nginx"
}
The docker image does exist on ECR at the location specified in the containerDefinitions
Name
field.
Am I missing something here?