Closed ncknuna closed 5 years ago
If you've correctly setup your ~/.aws/credentials and ~/.aws/config files for role assumption, the Amplify CLI has the ability to assume the role, just like how that aws cli consumes a role from those two files. check here for a details description.
If you configured your EC2 instance to use IAM roles, the Amplify CLI can automatically assume the IAM credentials for your application, eliminating the need to manually provide credentials. This can be done in two ways:
amplify init
in headless mode and set the awscloudformation provider's configuration level to be general
, see hereamplify configure project
, and when prompted Do you want to update or remove the project level configuration
, select remove
. The cli will then automatically assume the EC2 role for your project. Ah, thanks so much for clarifying! I missed the "general" configuration level setting. Marking this closed :)
All the links specified above to resolve this are broken. This is a requirement for Cloud9 setups.
This issue has been automatically locked since there hasn't been any recent activity after it was closed. Please open a new issue for related bugs.
Looking for a help forum? We recommend joining the Amplify Community Discord server *-help
channels for those types of questions.
Is your feature request related to a problem? Please describe. I'm attempting to run the amplify cli on a Jenkins worker, which gets its credentials from its instance profile, not from a ~/.aws/credentials or ~/.aws/config file. I can run
aws s3 ls
and other aws cli commands just fine, but when I runamplify init
, it says "AWS access credentials can not be found."Describe the solution you'd like
amplify
should work automagically just like the aws cli :)Describe alternatives you've considered Per these docs I could fetch the credentials via the AWS STS API, but that's a bit of a pain.