thomasmichaelwallace / serverless-better-credentials

Better AWS credentials resolution plugin for serverless
MIT License
54 stars 9 forks source link

Add support for serverless print #11

Closed tonivdv closed 1 year ago

tonivdv commented 1 year ago

Is your feature request related to a problem? Please describe. It seems when using sls print the serverless-better-credentials is not being used causing errors like:

cannot resolve variable at "custom.xxxx": Profile default not found

Describe the solution you'd like Add support for the serverless print command

thomasmichaelwallace commented 1 year ago

Hi there,

Thanks for reporting this - although I'm struggling to reproduce it.

I actually can use serverless print without any issue.

Would you be able to include the stack trace, or maybe the verbose/debug logging?

Note that a common cause of the cannot resolve variable is simply that you don't have the same environment setup that you do when deploying &c.

prabodh1194 commented 1 year ago

i just setup this plugin and tested it using the print command & it works. I had some issue with credentials file missing, so I had to set this variable to get things to work -- export AWS_SDK_LOAD_CONFIG=1

tonivdv commented 1 year ago

Hi @thomasmichaelwallace and @prabodh1194 ,

Thanks for both your help. It allowed me to get out of my tunnel vision. I confirm that it works and the AWS_SDK_LOAD_CONFIG=1 triggered me.

I indeed scripted the deployment procedure where AWS_SDK_LOAD_CONFIG=1 is set, while when executing the print command I did it manually forgetting that important piece!

As usual, the issue lays in between the keyboard and the chair.

But many thanks for the help, and more importantly many thangs for taking the time writing this very useful plugin!

Cheers