Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PLAT-1798 - set env vars for AWS creds from cached credentials… #6938

Merged
merged 1 commit into from
Nov 8, 2019

Conversation

dschep
Copy link
Contributor

@dschep dschep commented Nov 7, 2019

What did you implement

Allows for use of credentials provided by a deploy profile in the
serverless dashboard

Closes PLAT-1798

How can we verify it

on a system with no credentials, set up a project using serverless dashbaord with an access role in your deploy profile. then create a project with sls create -t aws-nodejs then replace the handler.js with

const AWS = require('aws-sdk');
const sts = new AWS.STS();
module.exports.hello = async () => {
  await sts.getCallerIdentity();
}

and configure your app/org in serverless.yml with the respective values from your dashboard config.

then install this branch and invoke

npm i -g serverless/serverless#sfe-creds-invoke-local
sls invoke local -f hello

it should work. on master it should fail due to lack of creds

Todos

Useful Scripts
  • npm run test-ci --> Run all validation checks on proposed changes
  • npm run lint-updated --> Lint all the updated files
  • npm run lint:fix --> Automatically fix lint problems (if possible)
  • npm run prettier-check-updated --> Check if updated files adhere to Prettier config
  • npm run prettify-updated --> Prettify all the updated files
  • Write and run all tests
  • Write documentation
  • Enable "Allow edits from maintainers" for this PR
  • Update the messages below

Is this ready for review?: YES
Is it a breaking change?: NO

…oke local

this allows for use of credentials provided by a deploy profile in the
serverless dashboard
@dschep dschep changed the title PLAT-1798 - set env vars for AWS creds from cached credentials in invoke local PLAT-1798 - set env vars for AWS creds from cached credentials… Nov 8, 2019
@dschep dschep merged commit b5c0117 into master Nov 8, 2019
@dschep dschep deleted the sfe-creds-invoke-local branch November 8, 2019 20:24
@medikoo medikoo added this to the 1.58.0 milestone Nov 20, 2019
@medikoo medikoo mentioned this pull request Dec 4, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants