mirror of
https://github.com/aws-actions/configure-aws-credentials.git
synced 2026-09-03 06:05:04 +09:00
Compare commits
17 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 13d241b293 | |||
| 230d25f14e | |||
| 65b54d1a99 | |||
| ef2b041797 | |||
| e1cbb915a6 | |||
| 7c6941c992 | |||
| 0af073e722 | |||
| 47603571fa | |||
| 819cc639a4 | |||
| 9a884abe4a | |||
| 8ad8d14cff | |||
| 55f5493fd1 | |||
| 30d0c4e632 | |||
| 4900858c22 | |||
| 745b3becf5 | |||
| 74dad352c3 | |||
| d3caf7c609 |
@@ -2,6 +2,13 @@
|
|||||||
|
|
||||||
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
|
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
|
||||||
|
|
||||||
|
### [1.5.10](https://github.com/aws-actions/configure-aws-credentials/compare/v1.5.9...v1.5.10) (2021-06-01)
|
||||||
|
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* skips session tagging ([#209](https://github.com/aws-actions/configure-aws-credentials/issues/209)) ([4900858](https://github.com/aws-actions/configure-aws-credentials/commit/4900858c22f8f07170e3032d4105f99c2aafa9e7))
|
||||||
|
|
||||||
### [1.5.9](https://github.com/aws-actions/configure-aws-credentials/compare/v1.5.8...v1.5.9) (2021-05-10)
|
### [1.5.9](https://github.com/aws-actions/configure-aws-credentials/compare/v1.5.8...v1.5.9) (2021-05-10)
|
||||||
|
|
||||||
### [1.5.8](https://github.com/aws-actions/configure-aws-credentials/compare/v1.5.7...v1.5.8) (2021-03-02)
|
### [1.5.8](https://github.com/aws-actions/configure-aws-credentials/compare/v1.5.7...v1.5.8) (2021-03-02)
|
||||||
|
|||||||
Vendored
+530
-286
File diff suppressed because one or more lines are too long
@@ -57,6 +57,12 @@ async function assumeRole(params) {
|
|||||||
|
|
||||||
const roleSessionTags = roleSkipSessionTagging ? undefined : tagArray;
|
const roleSessionTags = roleSkipSessionTagging ? undefined : tagArray;
|
||||||
|
|
||||||
|
if(roleSessionTags == undefined){
|
||||||
|
core.debug("Role session tagging has been skipped.")
|
||||||
|
} else {
|
||||||
|
core.debug(roleSessionTags.length + " role session tags are being used.")
|
||||||
|
}
|
||||||
|
|
||||||
const assumeRoleRequest = {
|
const assumeRoleRequest = {
|
||||||
RoleArn: roleArn,
|
RoleArn: roleArn,
|
||||||
RoleSessionName: roleSessionName,
|
RoleSessionName: roleSessionName,
|
||||||
@@ -203,8 +209,9 @@ async function run() {
|
|||||||
const roleExternalId = core.getInput('role-external-id', { required: false });
|
const roleExternalId = core.getInput('role-external-id', { required: false });
|
||||||
const roleDurationSeconds = core.getInput('role-duration-seconds', {required: false}) || MAX_ACTION_RUNTIME;
|
const roleDurationSeconds = core.getInput('role-duration-seconds', {required: false}) || MAX_ACTION_RUNTIME;
|
||||||
const roleSessionName = core.getInput('role-session-name', { required: false }) || ROLE_SESSION_NAME;
|
const roleSessionName = core.getInput('role-session-name', { required: false }) || ROLE_SESSION_NAME;
|
||||||
const roleSkipSessionTagging = core.getInput('role-skip-session-tagging', { required: false });
|
const roleSkipSessionTaggingInput = core.getInput('role-skip-session-tagging', { required: false })|| 'false';
|
||||||
|
const roleSkipSessionTagging = roleSkipSessionTaggingInput.toLowerCase() === 'true';
|
||||||
|
|
||||||
if (!region.match(REGION_REGEX)) {
|
if (!region.match(REGION_REGEX)) {
|
||||||
throw new Error(`Region is not valid: ${region}`);
|
throw new Error(`Region is not valid: ${region}`);
|
||||||
}
|
}
|
||||||
|
|||||||
+2
-2
@@ -559,7 +559,7 @@ describe('Configure AWS Credentials', () => {
|
|||||||
test('skip tagging provided as true', async () => {
|
test('skip tagging provided as true', async () => {
|
||||||
core.getInput = jest
|
core.getInput = jest
|
||||||
.fn()
|
.fn()
|
||||||
.mockImplementation(mockGetInput({...ASSUME_ROLE_INPUTS, 'role-skip-session-tagging': true}));
|
.mockImplementation(mockGetInput({...ASSUME_ROLE_INPUTS, 'role-skip-session-tagging': 'true'}));
|
||||||
|
|
||||||
await run();
|
await run();
|
||||||
expect(mockStsAssumeRole).toHaveBeenCalledWith({
|
expect(mockStsAssumeRole).toHaveBeenCalledWith({
|
||||||
@@ -573,7 +573,7 @@ describe('Configure AWS Credentials', () => {
|
|||||||
test('skip tagging provided as false', async () => {
|
test('skip tagging provided as false', async () => {
|
||||||
core.getInput = jest
|
core.getInput = jest
|
||||||
.fn()
|
.fn()
|
||||||
.mockImplementation(mockGetInput({...ASSUME_ROLE_INPUTS, 'role-skip-session-tagging': false}));
|
.mockImplementation(mockGetInput({...ASSUME_ROLE_INPUTS, 'role-skip-session-tagging': 'false'}));
|
||||||
|
|
||||||
await run();
|
await run();
|
||||||
expect(mockStsAssumeRole).toHaveBeenCalledWith({
|
expect(mockStsAssumeRole).toHaveBeenCalledWith({
|
||||||
|
|||||||
Generated
+1054
-3752
File diff suppressed because it is too large
Load Diff
+4
-4
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "aws-actions-configure-aws-credentials",
|
"name": "aws-actions-configure-aws-credentials",
|
||||||
"version": "1.5.9",
|
"version": "1.5.10",
|
||||||
"description": "Configure AWS Credentials",
|
"description": "Configure AWS Credentials",
|
||||||
"main": "index.js",
|
"main": "index.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
@@ -26,11 +26,11 @@
|
|||||||
"homepage": "https://github.com/aws-actions/configure-aws-credentials#readme",
|
"homepage": "https://github.com/aws-actions/configure-aws-credentials#readme",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@actions/core": "^1.2.7",
|
"@actions/core": "^1.2.7",
|
||||||
"aws-sdk": "^2.899.0"
|
"aws-sdk": "^2.918.0"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@zeit/ncc": "^0.22.3",
|
"@zeit/ncc": "^0.22.3",
|
||||||
"eslint": "^7.25.0",
|
"eslint": "^7.27.0",
|
||||||
"jest": "^26.6.3"
|
"jest": "^27.0.3"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user