Skip to content

Commit

Permalink
mid work
Browse files Browse the repository at this point in the history
  • Loading branch information
iliapolo committed Sep 3, 2024
1 parent 2e79a94 commit d1281af
Showing 1 changed file with 3 additions and 7 deletions.
10 changes: 3 additions & 7 deletions lib/aws.ts
Original file line number Diff line number Diff line change
Expand Up @@ -151,18 +151,14 @@ export class DefaultAwsClient implements IAws {
externalId?: string,
additionalOptions?: AssumeRoleAdditionalOptions
): Promise<AWS.Credentials> {
if (
additionalOptions?.Tags &&
additionalOptions.Tags.length > 0 &&
!additionalOptions.TransitiveTagKeys
) {
additionalOptions.TransitiveTagKeys = additionalOptions.Tags?.map((t) => t.Key);
}
return new this.AWS.ChainableTemporaryCredentials({
params: {
RoleArn: roleArn,
ExternalId: externalId,
RoleSessionName: `cdk-assets-${safeUsername()}`,
TransitiveTagKeys: additionalOptions?.Tags
? additionalOptions.Tags.map((t) => t.Key)
: undefined,
...(additionalOptions ?? {}),
},
stsConfig: {
Expand Down

0 comments on commit d1281af

Please sign in to comment.