빡코

[aws] Elastic Beanstalk: error: Environment must have instance profile asscociated with it. 본문

카테고리 없음

[aws] Elastic Beanstalk: error: Environment must have instance profile asscociated with it.

chris.djang 2023. 5. 17. 17:25

에러 메시지 

Environment health has transitioned from Ok to Warning. Initialization completed 78 seconds ago and took 90 seconds. Unable to assume role "arn:aws:iam:: 0000000000:role/역할이름". Verify that the role exists and is configured correctly.

 

 

Elastic Beanstalk 에서 신규 웹 어플리케이션 생성시, 서비스 액세스 채우지 않거나 또는 적저한 IAM 역할과 권한 정책을 부여하지 않으면 발생한다. 

해결 방법

 

aws  IAM (Identity and Access Management)  콘솔에서 신규 역할 생성 및 권한 정책을 부여하고 

웹 어플리케이션 생성시 '서비스 액세스 구성'에  추가한다. 

 

 

역할 생성 

 

권한 정책 추가 

aws docs 

https://docs.aws.amazon.com/elasticbeanstalk/latest/dg/concepts-roles-service.html

 

Elastic Beanstalk service role - AWS Elastic Beanstalk

Elastic Beanstalk service role A service role is the IAM role that Elastic Beanstalk assumes when calling other services on your behalf. For example, Elastic Beanstalk uses a service role when it calls Amazon Elastic Compute Cloud (Amazon EC2), Elastic Loa

docs.aws.amazon.com

aws docs

https://docs.aws.amazon.com/elasticbeanstalk/latest/dg/iam-servicerole.html

 

Managing Elastic Beanstalk service roles - AWS Elastic Beanstalk

Because of permission issues, the Elastic Beanstalk service doesn't always successfully create this service-linked role for you. Therefore, the console tries to explicitly create it. To ensure your account has this service-linked role, create an environmen

docs.aws.amazon.com