mirror of
https://github.com/aws-actions/configure-aws-credentials.git
synced 2026-11-30 11:44:23 +01:00
feat: add support for assuming a role (#17)
* first draft attempt at adding role assumption option * refinements * const not var * clean up asserts * set explicit sts endpoint and clarify required inputs error message * streamline mocks * add new inputs to Action definition * ignore .idea directory * add initial assume role test * make tests fail usefully when not in GitHub Actions * add logic to handle suppression of stack trace * pull credentials exports out into function * convert environment variable patching to use object for source and add needed members * add test for STS call * compartmentalization and use custom user agent in role assumption STS client * change DO_NOT_SUPRESS_STACK_TRACE to SHOW_STACK_TRACE * update role-to-assume input description
This commit is contained in:
1 parent
e3c83cfe60
commit
25960ab095
4 files changed
+277
-58
No files matched your search
@@ -19,6 +19,12 @@ inputs:
|
||||
mask-aws-account-id:
|
||||
description: "Whether to set the AWS account ID for these credentials as a secret value, so that it is masked in logs. Valid values are 'true' and 'false'. Defaults to true"
|
||||
required: false
|
||||
role-to-assume:
|
||||
description: "Use the provided credentials to assume a Role and output the assumed credentials for that Role rather than the provided credentials"
|
||||
required: false
|
||||
role-duration-seconds:
|
||||
description: "Role duration in seconds (default: 6 hours)"
|
||||
required: false
|
||||
outputs:
|
||||
aws-account-id:
|
||||
description: 'The AWS account ID for the provided credentials'
|
||||
|
||||
Reference in new issue
Block a user