skip to Main Content

I am deploying a Django app to AWS EB. Everything works the day i create the AWS EB environment. AWS Health Checks work, I can update environment configuration and deploy new versions. When I try to update the app in the following days, I get the following errors from AWS:

Failed to deploy configuration.

Failed to check health. Verify the permissions on the environment’s service role and try again later. Permissions changes take up to two hours to propagate.

This happens whether or not I use the EB CLI or the AWS Management Console to update the environment. The service role for the environment is the default AWS EB service role, with health check and managed update permissions policies attached. And because the service role worked initially, I am guessing the permissions aren’t the issue (I confirmed this with Permissions Simulator). Similarly, I am also using the same IAM user throughout.

If I create a new environment in the same application, I am able to deploy and update without any issues, until I try it the following day.

Any help would be appreciated!

Similar question posted here 2 years ago with no answer ๐Ÿ™ – Elastic Beanstalk Deployment – Verify the permissions on the environment's service role

2

Answers


  1. Chosen as BEST ANSWER

    It turns out that the ec2 instance profile I was using did not have the correct permissions. I'm not sure why this only stopped the deployment after a day, but I just added more permissions to the ec2 profile and waited a few hours and it is working again.


  2. Based on my findings, the primary reason for this behavior is:

    "Unable to assume role "arn:aws:iam::xxxxxxx:role/aws-elasticbeanstalk-service-role". Verify that the role exists and is configured correctly."

    Despite having sufficient permissions, the Elastic Beanstalk (EBS) environment is unable to assume the default "aws-elasticbeanstalk-service-role" for some reason. The solution was to create a new service role with permissions similar to "aws-elasticbeanstalk-service-role" and configure the Elastic Beanstalk environment’s service role to use this custom role.

    In my case, the environment’s health status was transitioning to the "Suspended" state because Elastic Beanstalk couldn’t access the environment’s service roles for monitoring health, leading to the halting of the deployment.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search