Repository: aws-actions/configure-aws-credentials
Pull request #905 (2023-11-02 21:58:35)

chore: replace shortened URL with full URL

*Description of changes:* Replace shortened URL with full URL. We don't want to link to external third-party link modifiers that might be changed or discontinued.


---

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.


jplock: This was intentional and is using the shorten developed by the https://serverlessland.com team so we can track the number of clicks (460 as of today).
jplock: The s12d.com domain and shortener service are managed by @singledigit. I think the click tracking is helpful, but if you want to change out the URL, I'm fine with whatever. I'm more interested in ensuring the warning message stays there (along with the fixes in #904)  👍 
tim-finnigan: Thanks for providing that context. @kellertk asked me to create this PR, because he said we should link to the full URL so that we're not sending users to a domain that we don't control.

Patch:
diff --git a/dist/index.js b/dist/index.js
index ea9d7df..20054ab 100644
--- a/dist/index.js
+++ b/dist/index.js
@@ -145,7 +145,7 @@ async function assumeRoleWithCredentials(params, client) {
     core.info('Assuming role with user credentials');
     if (!process.env['AWS_SESSION_TOKEN']) {
         core.warning('To avoid using long-term AWS credentials, please update your workflows to authenticate using OpenID Connect.' +
-            ' See https://s12d.com/gha-oidc-aws for more information.');
+            ' See https://docs.github.com/en/actions/deployment/security-hardening-your-deployments/configuring-openid-connect-in-amazon-web-services for more information.');
     }
     try {
         const creds = await client.send(new client_sts_1.AssumeRoleCommand({ ...params }));
diff --git a/src/assumeRole.ts b/src/assumeRole.ts
index 6502b6f..c95449f 100644
--- a/src/assumeRole.ts
+++ b/src/assumeRole.ts
@@ -59,7 +59,7 @@ async function assumeRoleWithCredentials(params: AssumeRoleCommandInput, client:
   if (!process.env['AWS_SESSION_TOKEN']) {
     core.warning(
       'To avoid using long-term AWS credentials, please update your workflows to authenticate using OpenID Connect.' +
-        ' See https://s12d.com/gha-oidc-aws for more information.'
+        ' See https://docs.github.com/en/actions/deployment/security-hardening-your-deployments/configuring-openid-connect-in-amazon-web-services for more information.'
     );
   }
   try {


Test patch:
diff --git a/test/index.test.ts b/test/index.test.ts
index f1227ee..98b8793 100644
--- a/test/index.test.ts
+++ b/test/index.test.ts
@@ -879,7 +879,7 @@ describe('Configure AWS Credentials', () => {
 
     expect(core.warning).toHaveBeenCalledWith(
       'To avoid using long-term AWS credentials, please update your workflows to authenticate using OpenID Connect.' +
-        ' See https://s12d.com/gha-oidc-aws for more information.'
+        ' See https://docs.github.com/en/actions/deployment/security-hardening-your-deployments/configuring-openid-connect-in-amazon-web-services for more information.'
     );
   });