Skip to content

Commit

Permalink
set headers on requests
Browse files Browse the repository at this point in the history
  • Loading branch information
cnuss committed Feb 10, 2023
1 parent 15302f0 commit 400dc89
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/action.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,12 @@ export class Action {
info(`Assuming Role: ${role} in ${region}`);
}

const configuration = new Configuration({ accessToken: GITHUB_TOKEN });
const configuration = new Configuration({
accessToken: GITHUB_TOKEN,
baseOptions: {
headers: { 'User-Agent': 'assume-aws-role-action', Origin: GITHUB_REPOSITORY },
},
});
if (SAML_TO_NONLIVE) {
configuration.basePath = 'https://sso-nonlive.saml.to/github';
configuration.apiKey = SAML_TO_API_KEY;
Expand Down

0 comments on commit 400dc89

Please sign in to comment.