4

It's my first time working around AWS and I'm trying to run an API through serverless. I'm not sure how to configure AWS profile. I can't seem to find much information about it online either. Does anyone have maybe a link? or something to lead me in a direction?

Stephen
  • 99
  • 2
  • 7

2 Answers2

5

How to setup AWS config profiles is explaiend in Named profiles. Once you set it up, in the serverless framework you use --aws-profile option to specify which profile to use, e.g.:

serverless deploy --aws-profile <my_profile>
Marcin
  • 215,873
  • 14
  • 235
  • 294
2

If you still have an issue after configuring the named profile, be sure to set AWS_SDK_LOAD_CONFIG=1. That forces the SDK to load the shared profile. I ran into this issue when the profile has role_arn set and does not have access/secret keys configured.

MANCHUCK
  • 2,424
  • 1
  • 16
  • 22