I try to initialize an elastic beanstalk application with eb cli using command eb init. After several steps it asks for some input to create a public key. However, when I enter input it gives "ERROR: NotAuthorizedError - Operation Denied. You are not authorized to perform this operation. Encoded authorization failure message: " error. My IAM user roles are listed here :
AWSCodeCommitFullAccess
AmazonEC2ContainerRegistryFullAccess
AWSElasticBeanstalkMulticontainerDocker
AmazonECS_FullAccess
AmazonECSTaskExecutionRolePolicy
AmazonEC2ContainerServiceforEC2Role
AmazonEC2ContainerServiceRole
AdministratorAccess-AWSElasticBeanstalk
AWSElasticBeanstalkReadOnly
Do I need an additional permission to be able to intialize a beanstalk application?
CodePudding user response:
It fails to create an ssh public key for your instance during the eb init
.
You need a IAM policy that has ec2:CreateKeyPair
permission.
CodePudding user response:
You need to add AmazonEC2FullAccess permission to the default iam user on your local machine. access aws console
- search iam.
- select the iam user, which is your default user.
- click on button with attach existing permission.
- click on add permission and search for AmazonEC2FullAccess then add it