From 013c18180ffe7eb3b404194f170ce8339bceff40 Mon Sep 17 00:00:00 2001 From: Harold Sun Date: Thu, 15 Aug 2019 00:37:43 +0800 Subject: [PATCH] fix(region-info): IAM service principal for China regions (#3491) * fix IAM service principal for China regions * fix integration testings for correct China region service principals * fix IAM service principal for China regions * fix integration testings for correct China region service principals * fix IAM principal for China region - ( aws-s3-deployment / aws-eks ) * remove two regions where we don't have the CDK Metadata resource * remove two regions where we don't have the CDK Metadata resource * remove two regions where we don't have the CDK Metadata resource * fix additional Principal values for China region * fix(region-info): merge changes from v1.4.0 --- .../test/integ.cicd.expected.json | 24 +--- .../test/integ.restapi.books.expected.json | 48 +------ .../test/integ.restapi.defaults.expected.json | 12 +- .../test/integ.restapi.expected.json | 24 +--- .../test/integ.restapi.multiuse.expected.json | 36 +---- .../aws-apigateway/test/test.restapi.ts | 2 +- .../test/test.lifecyclehooks.ts | 4 +- ...nteg.trivial-lambda-resource.expected.json | 12 +- .../aws-cloudformation/test/test.resource.ts | 2 +- ...loudfront-lambda-association.expected.json | 12 +- .../test/integ.cloudtrail.lit.expected.json | 34 +---- .../aws-cloudtrail/test/test.cloudtrail.ts | 8 +- .../test/integ.caching.expected.json | 12 +- .../test/integ.defaults.lit.expected.json | 12 +- .../test/integ.docker-asset.lit.expected.json | 24 +--- .../integ.docker-registry.lit.expected.json | 12 +- .../test/integ.ecr.lit.expected.json | 12 +- .../test/integ.github.expected.json | 12 +- .../test/integ.project-bucket.expected.json | 12 +- ...-secondary-sources-artifacts.expected.json | 12 +- .../test/integ.project-vpc.expected.json | 12 +- .../aws-codebuild/test/test.codebuild.ts | 6 +- .../integ.deployment-group.expected.json | 36 +---- ...g.cfn-template-from-repo.lit.expected.json | 24 +--- ...yed-through-codepipeline.lit.expected.json | 60 +------- .../test/integ.lambda-pipeline.expected.json | 60 +------- .../integ.pipeline-alexa-deploy.expected.json | 12 +- ...eg.pipeline-cfn-cross-region.expected.json | 24 +--- ...ipeline-cfn-with-action-role.expected.json | 24 +--- .../test/integ.pipeline-cfn.expected.json | 24 +--- ...uild-multiple-inputs-outputs.expected.json | 36 +---- ...g.pipeline-code-commit-build.expected.json | 24 +--- .../integ.pipeline-code-commit.expected.json | 24 +--- .../integ.pipeline-code-deploy.expected.json | 12 +- .../integ.pipeline-ecr-source.expected.json | 24 +--- .../integ.pipeline-ecs-deploy.expected.json | 36 +---- .../test/integ.pipeline-events.expected.json | 36 +---- .../test/integ.pipeline-jenkins.expected.json | 12 +- ...teg.pipeline-manual-approval.expected.json | 12 +- .../integ.pipeline-s3-deploy.expected.json | 12 +- .../test/integ.rule.lit.expected.json | 36 +---- .../aws-config/test/test.managed-rules.ts | 12 +- .../test/integ.dynamodb.global.expected.json | 12 +- .../test/integ.assets-docker.expected.json | 12 +- ...integ.scheduled-ecs-task.lit.expected.json | 128 ++++++------------ .../fargate/integ.asset-image.expected.json | 36 +---- .../fargate/integ.executionrole.expected.json | 36 +---- .../fargate/integ.l3-autocreate.expected.json | 48 +------ .../fargate/integ.l3-vpconly.expected.json | 72 +--------- .../test/fargate/integ.l3.expected.json | 24 +--- ...g.scheduled-fargate-task.lit.expected.json | 60 +------- .../test/ec2/integ.lb-awsvpc-nw.expected.json | 36 +---- .../test/ec2/integ.lb-bridge-nw.expected.json | 36 +---- .../test/ec2/integ.sd-awsvpc-nw.expected.json | 36 +---- .../test/ec2/integ.sd-bridge-nw.expected.json | 36 +---- .../fargate/integ.lb-awsvpc-nw.expected.json | 12 +- .../integ.eks-cluster.defaults.expected.json | 24 +--- ...eks-cluster.kubectl-disabled.expected.json | 12 +- .../test/integ.eks-cluster.lit.expected.json | 24 +--- .../test/integ.eks-kubectl.lit.expected.json | 24 +--- .../test/codebuild/codebuild.test.ts | 2 +- .../integ.project-events.expected.json | 36 +---- .../integ.pipeline-event-target.expected.json | 24 +--- .../integ.event-ec2-task.lit.expected.json | 72 +--------- .../integ.event-fargate-task.expected.json | 60 +------- .../test/lambda/integ.events.expected.json | 12 +- .../integ.sns-event-rule-target.expected.json | 12 +- .../aws-events-targets/test/sns/sns.test.ts | 4 +- .../integ.sqs-event-rule-target.expected.json | 12 +- .../aws-events-targets/test/sqs/sqs.test.ts | 6 +- .../test/integ.dynamodb.expected.json | 12 +- .../test/integ.kinesis.expected.json | 12 +- .../test/integ.s3.expected.json | 24 +--- .../test/integ.sns.expected.json | 12 +- .../test/integ.sqs.expected.json | 12 +- .../test/integ.assets.file.expected.json | 12 +- .../test/integ.assets.lit.expected.json | 12 +- .../test/integ.lambda.expected.json | 12 +- .../integ.layer-version.lit.expected.json | 12 +- .../test/integ.log-retention.expected.json | 48 +------ .../test/integ.vpc-lambda.expected.json | 12 +- .../@aws-cdk/aws-lambda/test/test.lambda.ts | 20 +-- .../aws-lambda/test/test.singleton-lambda.ts | 2 +- .../test/integ.instance.lit.expected.json | 24 +--- ...nteg.api-gateway-domain-name.expected.json | 24 +--- ...bucket-deployment-cloudfront.expected.json | 12 +- .../integ.bucket-deployment.expected.json | 12 +- .../test/integ.notifications.expected.json | 48 +------ .../integ.bucket-notifications.expected.json | 34 +---- .../test/notifications.test.ts | 2 +- .../aws-s3-notifications/test/queue.test.ts | 10 +- .../aws-s3-notifications/test/sns.test.ts | 4 +- ...teg.sns-bucket-notifications.expected.json | 42 +----- .../integ.bucket-notifications.expected.json | 86 ++---------- .../aws-ses/test/integ.receipt.expected.json | 48 +------ .../aws-ses/test/test.receipt-rule-action.ts | 24 +--- .../test/integ.sns-lambda.expected.json | 24 +--- .../aws-sns-subscriptions/test/subs.test.ts | 24 +--- .../test/integ.ec2-task.expected.json | 60 +------- .../test/integ.fargate-task.expected.json | 36 +---- .../test/integ.invoke-function.expected.json | 24 +--- .../test/integ.sagemaker.expected.json | 12 +- .../integ.aws-custom-resource.expected.json | 12 +- .../region-info/build-tools/aws-entities.ts | 5 +- .../build-tools/generate-static-data.ts | 1 + packages/@aws-cdk/region-info/lib/default.ts | 17 +-- .../__snapshots__/region-info.test.ts.snap | 73 ++++++---- .../@aws-cdk/region-info/test/default.test.ts | 10 +- .../test/__snapshots__/synth.test.js.snap | 120 ++-------------- 109 files changed, 357 insertions(+), 2425 deletions(-) diff --git a/packages/@aws-cdk/app-delivery/test/integ.cicd.expected.json b/packages/@aws-cdk/app-delivery/test/integ.cicd.expected.json index c95b3dce7018e..c545dada7753f 100644 --- a/packages/@aws-cdk/app-delivery/test/integ.cicd.expected.json +++ b/packages/@aws-cdk/app-delivery/test/integ.cicd.expected.json @@ -14,17 +14,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codepipeline.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codepipeline.amazonaws.com" } } ], @@ -426,17 +416,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "cloudformation.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "cloudformation.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-apigateway/test/integ.restapi.books.expected.json b/packages/@aws-cdk/aws-apigateway/test/integ.restapi.books.expected.json index 1d1d27302c39a..30a9f8c4a180c 100644 --- a/packages/@aws-cdk/aws-apigateway/test/integ.restapi.books.expected.json +++ b/packages/@aws-cdk/aws-apigateway/test/integ.restapi.books.expected.json @@ -9,17 +9,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], @@ -225,17 +215,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], @@ -441,17 +421,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], @@ -615,17 +585,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "apigateway.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "apigateway.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-apigateway/test/integ.restapi.defaults.expected.json b/packages/@aws-cdk/aws-apigateway/test/integ.restapi.defaults.expected.json index ba1a3b6829daf..7f54f90de14cb 100644 --- a/packages/@aws-cdk/aws-apigateway/test/integ.restapi.defaults.expected.json +++ b/packages/@aws-cdk/aws-apigateway/test/integ.restapi.defaults.expected.json @@ -39,17 +39,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "apigateway.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "apigateway.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-apigateway/test/integ.restapi.expected.json b/packages/@aws-cdk/aws-apigateway/test/integ.restapi.expected.json index 08f5409925828..d8781b60a8f8c 100644 --- a/packages/@aws-cdk/aws-apigateway/test/integ.restapi.expected.json +++ b/packages/@aws-cdk/aws-apigateway/test/integ.restapi.expected.json @@ -66,17 +66,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "apigateway.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "apigateway.amazonaws.com" } } ], @@ -399,17 +389,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-apigateway/test/integ.restapi.multiuse.expected.json b/packages/@aws-cdk/aws-apigateway/test/integ.restapi.multiuse.expected.json index 9c10556f4995f..74179f434ccde 100644 --- a/packages/@aws-cdk/aws-apigateway/test/integ.restapi.multiuse.expected.json +++ b/packages/@aws-cdk/aws-apigateway/test/integ.restapi.multiuse.expected.json @@ -9,17 +9,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], @@ -256,17 +246,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "apigateway.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "apigateway.amazonaws.com" } } ], @@ -397,17 +377,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "apigateway.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "apigateway.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-apigateway/test/test.restapi.ts b/packages/@aws-cdk/aws-apigateway/test/test.restapi.ts index d501a9dc5e9d9..95c31c3ba0c36 100644 --- a/packages/@aws-cdk/aws-apigateway/test/test.restapi.ts +++ b/packages/@aws-cdk/aws-apigateway/test/test.restapi.ts @@ -60,7 +60,7 @@ export = { { Action: "sts:AssumeRole", Effect: "Allow", - Principal: { Service: { "Fn::Join": ["", ["apigateway.", { Ref: "AWS::URLSuffix" }]] } } + Principal: { Service: "apigateway.amazonaws.com" } } ], Version: "2012-10-17" diff --git a/packages/@aws-cdk/aws-autoscaling/test/test.lifecyclehooks.ts b/packages/@aws-cdk/aws-autoscaling/test/test.lifecyclehooks.ts index 72c5dbcf06efc..b7c95e3179346 100644 --- a/packages/@aws-cdk/aws-autoscaling/test/test.lifecyclehooks.ts +++ b/packages/@aws-cdk/aws-autoscaling/test/test.lifecyclehooks.ts @@ -46,7 +46,9 @@ export = { { Action: "sts:AssumeRole", Effect: "Allow", - Principal: { Service: { "Fn::Join": ["", ["autoscaling.", { Ref: "AWS::URLSuffix" }]] } } + Principal: { + Service: "autoscaling.amazonaws.com" + } } ], } diff --git a/packages/@aws-cdk/aws-cloudformation/test/integ.trivial-lambda-resource.expected.json b/packages/@aws-cdk/aws-cloudformation/test/integ.trivial-lambda-resource.expected.json index 6a6a668af1a0d..a820be59e26c3 100644 --- a/packages/@aws-cdk/aws-cloudformation/test/integ.trivial-lambda-resource.expected.json +++ b/packages/@aws-cdk/aws-cloudformation/test/integ.trivial-lambda-resource.expected.json @@ -23,17 +23,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-cloudformation/test/test.resource.ts b/packages/@aws-cdk/aws-cloudformation/test/test.resource.ts index 968fc9c4cc180..aa13c6514947c 100644 --- a/packages/@aws-cdk/aws-cloudformation/test/test.resource.ts +++ b/packages/@aws-cdk/aws-cloudformation/test/test.resource.ts @@ -78,7 +78,7 @@ export = testCase({ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { "Fn::Join": ["", ["lambda.", { Ref: "AWS::URLSuffix" }]] } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-cloudfront/test/integ.cloudfront-lambda-association.expected.json b/packages/@aws-cdk/aws-cloudfront/test/integ.cloudfront-lambda-association.expected.json index 99705320a9eeb..85ee06b1c3abf 100644 --- a/packages/@aws-cdk/aws-cloudfront/test/integ.cloudfront-lambda-association.expected.json +++ b/packages/@aws-cdk/aws-cloudfront/test/integ.cloudfront-lambda-association.expected.json @@ -14,17 +14,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-cloudtrail/test/integ.cloudtrail.lit.expected.json b/packages/@aws-cdk/aws-cloudtrail/test/integ.cloudtrail.lit.expected.json index 627db27e26b93..8cb7e7df565dc 100644 --- a/packages/@aws-cdk/aws-cloudtrail/test/integ.cloudtrail.lit.expected.json +++ b/packages/@aws-cdk/aws-cloudtrail/test/integ.cloudtrail.lit.expected.json @@ -2,13 +2,13 @@ "Resources": { "Bucket83908E77": { "Type": "AWS::S3::Bucket", - "DeletionPolicy": "Delete", - "UpdateReplacePolicy": "Delete" + "UpdateReplacePolicy": "Delete", + "DeletionPolicy": "Delete" }, "TrailS30071F172": { "Type": "AWS::S3::Bucket", - "DeletionPolicy": "Retain", - "UpdateReplacePolicy": "Retain" + "UpdateReplacePolicy": "Retain", + "DeletionPolicy": "Retain" }, "TrailS3PolicyE42170FE": { "Type": "AWS::S3::BucketPolicy", @@ -22,17 +22,7 @@ "Action": "s3:GetBucketAcl", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "cloudtrail.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "cloudtrail.amazonaws.com" }, "Resource": { "Fn::GetAtt": [ @@ -50,17 +40,7 @@ }, "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "cloudtrail.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "cloudtrail.amazonaws.com" }, "Resource": { "Fn::Join": [ @@ -127,4 +107,4 @@ ] } } -} +} \ No newline at end of file diff --git a/packages/@aws-cdk/aws-cloudtrail/test/test.cloudtrail.ts b/packages/@aws-cdk/aws-cloudtrail/test/test.cloudtrail.ts index d71db485c9af8..803ddaf8e8c91 100644 --- a/packages/@aws-cdk/aws-cloudtrail/test/test.cloudtrail.ts +++ b/packages/@aws-cdk/aws-cloudtrail/test/test.cloudtrail.ts @@ -11,9 +11,7 @@ const ExpectedBucketPolicyProperties = { Action: "s3:GetBucketAcl", Effect: "Allow", Principal: { - Service: { - "Fn::Join": ["", ["cloudtrail.", { Ref: "AWS::URLSuffix" }]] - } + Service: "cloudtrail.amazonaws.com" }, Resource: { "Fn::GetAtt": [ @@ -31,9 +29,7 @@ const ExpectedBucketPolicyProperties = { }, Effect: "Allow", Principal: { - Service: { - "Fn::Join": ["", ["cloudtrail.", { Ref: "AWS::URLSuffix" }]] - } + Service: "cloudtrail.amazonaws.com" }, Resource: { "Fn::Join": [ diff --git a/packages/@aws-cdk/aws-codebuild/test/integ.caching.expected.json b/packages/@aws-cdk/aws-codebuild/test/integ.caching.expected.json index 3f37e6f1fc03e..f2c7bc3d0c7b6 100644 --- a/packages/@aws-cdk/aws-codebuild/test/integ.caching.expected.json +++ b/packages/@aws-cdk/aws-codebuild/test/integ.caching.expected.json @@ -14,17 +14,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codebuild.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codebuild.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-codebuild/test/integ.defaults.lit.expected.json b/packages/@aws-cdk/aws-codebuild/test/integ.defaults.lit.expected.json index 797c76b86f2fe..03af104a5737e 100644 --- a/packages/@aws-cdk/aws-codebuild/test/integ.defaults.lit.expected.json +++ b/packages/@aws-cdk/aws-codebuild/test/integ.defaults.lit.expected.json @@ -9,17 +9,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codebuild.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codebuild.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-codebuild/test/integ.docker-asset.lit.expected.json b/packages/@aws-cdk/aws-codebuild/test/integ.docker-asset.lit.expected.json index b44b47039e9a3..909d693e427b2 100644 --- a/packages/@aws-cdk/aws-codebuild/test/integ.docker-asset.lit.expected.json +++ b/packages/@aws-cdk/aws-codebuild/test/integ.docker-asset.lit.expected.json @@ -57,17 +57,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], @@ -213,17 +203,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codebuild.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codebuild.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-codebuild/test/integ.docker-registry.lit.expected.json b/packages/@aws-cdk/aws-codebuild/test/integ.docker-registry.lit.expected.json index b8cd00a66ffb2..9ece692d80671 100644 --- a/packages/@aws-cdk/aws-codebuild/test/integ.docker-registry.lit.expected.json +++ b/packages/@aws-cdk/aws-codebuild/test/integ.docker-registry.lit.expected.json @@ -9,17 +9,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codebuild.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codebuild.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-codebuild/test/integ.ecr.lit.expected.json b/packages/@aws-cdk/aws-codebuild/test/integ.ecr.lit.expected.json index bd8809fd97ad4..c92a8b6c2deba 100644 --- a/packages/@aws-cdk/aws-codebuild/test/integ.ecr.lit.expected.json +++ b/packages/@aws-cdk/aws-codebuild/test/integ.ecr.lit.expected.json @@ -14,17 +14,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codebuild.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codebuild.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-codebuild/test/integ.github.expected.json b/packages/@aws-cdk/aws-codebuild/test/integ.github.expected.json index 64a59518ad92d..2cdbc7430dbe4 100644 --- a/packages/@aws-cdk/aws-codebuild/test/integ.github.expected.json +++ b/packages/@aws-cdk/aws-codebuild/test/integ.github.expected.json @@ -9,17 +9,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codebuild.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codebuild.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-codebuild/test/integ.project-bucket.expected.json b/packages/@aws-cdk/aws-codebuild/test/integ.project-bucket.expected.json index e8edfde6b5ac9..7791f70be8b91 100644 --- a/packages/@aws-cdk/aws-codebuild/test/integ.project-bucket.expected.json +++ b/packages/@aws-cdk/aws-codebuild/test/integ.project-bucket.expected.json @@ -14,17 +14,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codebuild.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codebuild.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-codebuild/test/integ.project-secondary-sources-artifacts.expected.json b/packages/@aws-cdk/aws-codebuild/test/integ.project-secondary-sources-artifacts.expected.json index eff0a5deb9346..c57915ecb5ac1 100644 --- a/packages/@aws-cdk/aws-codebuild/test/integ.project-secondary-sources-artifacts.expected.json +++ b/packages/@aws-cdk/aws-codebuild/test/integ.project-secondary-sources-artifacts.expected.json @@ -14,17 +14,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codebuild.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codebuild.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-codebuild/test/integ.project-vpc.expected.json b/packages/@aws-cdk/aws-codebuild/test/integ.project-vpc.expected.json index e8427767496d6..dc862a4ac1167 100644 --- a/packages/@aws-cdk/aws-codebuild/test/integ.project-vpc.expected.json +++ b/packages/@aws-cdk/aws-codebuild/test/integ.project-vpc.expected.json @@ -217,17 +217,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codebuild.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codebuild.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-codebuild/test/test.codebuild.ts b/packages/@aws-cdk/aws-codebuild/test/test.codebuild.ts index 28526e756dcf0..7691cd089c2af 100644 --- a/packages/@aws-cdk/aws-codebuild/test/test.codebuild.ts +++ b/packages/@aws-cdk/aws-codebuild/test/test.codebuild.ts @@ -29,7 +29,7 @@ export = { "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { "Fn::Join": ["", ["codebuild.", { Ref: "AWS::URLSuffix" }]] } + "Service": "codebuild.amazonaws.com" } } ], @@ -169,7 +169,7 @@ export = { "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { "Fn::Join": ["", ["codebuild.", { Ref: "AWS::URLSuffix" }]] } + "Service": "codebuild.amazonaws.com" } } ], @@ -324,7 +324,7 @@ export = { "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { "Fn::Join": ["", ["codebuild.", { Ref: "AWS::URLSuffix" }]] } + "Service": "codebuild.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-codedeploy/test/lambda/integ.deployment-group.expected.json b/packages/@aws-cdk/aws-codedeploy/test/lambda/integ.deployment-group.expected.json index bf2574797575c..4d4a703e67e8b 100644 --- a/packages/@aws-cdk/aws-codedeploy/test/lambda/integ.deployment-group.expected.json +++ b/packages/@aws-cdk/aws-codedeploy/test/lambda/integ.deployment-group.expected.json @@ -9,17 +9,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], @@ -143,17 +133,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], @@ -286,17 +266,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-codepipeline-actions/test/integ.cfn-template-from-repo.lit.expected.json b/packages/@aws-cdk/aws-codepipeline-actions/test/integ.cfn-template-from-repo.lit.expected.json index 07144c768176d..7f80850c0a08a 100644 --- a/packages/@aws-cdk/aws-codepipeline-actions/test/integ.cfn-template-from-repo.lit.expected.json +++ b/packages/@aws-cdk/aws-codepipeline-actions/test/integ.cfn-template-from-repo.lit.expected.json @@ -141,17 +141,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codepipeline.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codepipeline.amazonaws.com" } } ], @@ -671,17 +661,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "cloudformation.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "cloudformation.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-codepipeline-actions/test/integ.lambda-deployed-through-codepipeline.lit.expected.json b/packages/@aws-cdk/aws-codepipeline-actions/test/integ.lambda-deployed-through-codepipeline.lit.expected.json index d33f61cd86cfe..6e1fb58de6a03 100644 --- a/packages/@aws-cdk/aws-codepipeline-actions/test/integ.lambda-deployed-through-codepipeline.lit.expected.json +++ b/packages/@aws-cdk/aws-codepipeline-actions/test/integ.lambda-deployed-through-codepipeline.lit.expected.json @@ -191,17 +191,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codepipeline.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codepipeline.amazonaws.com" } } ], @@ -770,17 +760,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "events.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "events.amazonaws.com" } } ], @@ -1097,17 +1077,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "cloudformation.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "cloudformation.amazonaws.com" } } ], @@ -1289,17 +1259,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codebuild.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codebuild.amazonaws.com" } } ], @@ -1462,17 +1422,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codebuild.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codebuild.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-codepipeline-actions/test/integ.lambda-pipeline.expected.json b/packages/@aws-cdk/aws-codepipeline-actions/test/integ.lambda-pipeline.expected.json index 47d6ffcc0c0ec..cb6b6308efa22 100644 --- a/packages/@aws-cdk/aws-codepipeline-actions/test/integ.lambda-pipeline.expected.json +++ b/packages/@aws-cdk/aws-codepipeline-actions/test/integ.lambda-pipeline.expected.json @@ -116,17 +116,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codepipeline.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codepipeline.amazonaws.com" } } ], @@ -445,17 +435,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "events.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "events.amazonaws.com" } } ], @@ -667,17 +647,7 @@ "Action": "s3:GetBucketAcl", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "cloudtrail.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "cloudtrail.amazonaws.com" }, "Resource": { "Fn::GetAtt": [ @@ -695,17 +665,7 @@ }, "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "cloudtrail.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "cloudtrail.amazonaws.com" }, "Resource": { "Fn::Join": [ @@ -782,17 +742,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-alexa-deploy.expected.json b/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-alexa-deploy.expected.json index cbcaaf428ddfb..947f3b0e6423f 100644 --- a/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-alexa-deploy.expected.json +++ b/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-alexa-deploy.expected.json @@ -126,17 +126,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codepipeline.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codepipeline.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-cfn-cross-region.expected.json b/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-cfn-cross-region.expected.json index 1156ffa809e83..6a31855686072 100644 --- a/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-cfn-cross-region.expected.json +++ b/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-cfn-cross-region.expected.json @@ -19,17 +19,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codepipeline.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codepipeline.amazonaws.com" } } ], @@ -439,17 +429,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "cloudformation.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "cloudformation.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-cfn-with-action-role.expected.json b/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-cfn-with-action-role.expected.json index 58e08cb069fda..42cd2979d26a5 100644 --- a/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-cfn-with-action-role.expected.json +++ b/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-cfn-with-action-role.expected.json @@ -144,17 +144,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codepipeline.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codepipeline.amazonaws.com" } } ], @@ -442,17 +432,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "cloudformation.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "cloudformation.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-cfn.expected.json b/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-cfn.expected.json index 81c45a0bcffc5..38819f83f07b7 100644 --- a/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-cfn.expected.json +++ b/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-cfn.expected.json @@ -149,17 +149,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codepipeline.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codepipeline.amazonaws.com" } } ], @@ -796,17 +786,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "cloudformation.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "cloudformation.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-code-build-multiple-inputs-outputs.expected.json b/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-code-build-multiple-inputs-outputs.expected.json index 9bb0b89566813..f4af6f16813fc 100644 --- a/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-code-build-multiple-inputs-outputs.expected.json +++ b/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-code-build-multiple-inputs-outputs.expected.json @@ -91,17 +91,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codepipeline.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codepipeline.amazonaws.com" } } ], @@ -433,17 +423,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "events.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "events.amazonaws.com" } } ], @@ -503,17 +483,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codebuild.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codebuild.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-code-commit-build.expected.json b/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-code-commit-build.expected.json index fd77c68dc48c0..4bcb4f777cc04 100644 --- a/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-code-commit-build.expected.json +++ b/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-code-commit-build.expected.json @@ -16,17 +16,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codebuild.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codebuild.amazonaws.com" } } ], @@ -375,17 +365,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codepipeline.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codepipeline.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-code-commit.expected.json b/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-code-commit.expected.json index 39b5aac8db3ff..41e6dc10eef4c 100644 --- a/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-code-commit.expected.json +++ b/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-code-commit.expected.json @@ -190,17 +190,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codepipeline.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codepipeline.amazonaws.com" } } ], @@ -507,17 +497,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "events.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "events.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-code-deploy.expected.json b/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-code-deploy.expected.json index 808221cf4f492..35842de4debdc 100644 --- a/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-code-deploy.expected.json +++ b/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-code-deploy.expected.json @@ -104,17 +104,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codepipeline.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codepipeline.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-ecr-source.expected.json b/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-ecr-source.expected.json index a4ca1b5fccbb0..c079c664a8b72 100644 --- a/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-ecr-source.expected.json +++ b/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-ecr-source.expected.json @@ -14,17 +14,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codepipeline.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codepipeline.amazonaws.com" } } ], @@ -276,17 +266,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "events.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "events.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-ecs-deploy.expected.json b/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-ecs-deploy.expected.json index 2b95abce1188d..fca265323d908 100644 --- a/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-ecs-deploy.expected.json +++ b/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-ecs-deploy.expected.json @@ -207,17 +207,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ecs-tasks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ecs-tasks.amazonaws.com" } } ], @@ -324,17 +314,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codebuild.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codebuild.amazonaws.com" } } ], @@ -569,17 +549,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codepipeline.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codepipeline.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-events.expected.json b/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-events.expected.json index e4b341ddc4b39..77854aa8ed204 100644 --- a/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-events.expected.json +++ b/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-events.expected.json @@ -137,17 +137,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codepipeline.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codepipeline.amazonaws.com" } } ], @@ -700,17 +690,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codebuild.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codebuild.amazonaws.com" } } ], @@ -875,17 +855,7 @@ "Action": "sns:Publish", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "events.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "events.amazonaws.com" }, "Resource": { "Ref": "MyTopic86869434" diff --git a/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-jenkins.expected.json b/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-jenkins.expected.json index e8e01bf50fa20..b4f184ad75e37 100644 --- a/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-jenkins.expected.json +++ b/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-jenkins.expected.json @@ -19,17 +19,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codepipeline.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codepipeline.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-manual-approval.expected.json b/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-manual-approval.expected.json index 43a4d844e95a7..9f2722503fdca 100644 --- a/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-manual-approval.expected.json +++ b/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-manual-approval.expected.json @@ -14,17 +14,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codepipeline.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codepipeline.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-s3-deploy.expected.json b/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-s3-deploy.expected.json index 3915562e381ad..9e6ceb0ad5a66 100644 --- a/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-s3-deploy.expected.json +++ b/packages/@aws-cdk/aws-codepipeline-actions/test/integ.pipeline-s3-deploy.expected.json @@ -147,17 +147,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codepipeline.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codepipeline.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-config/test/integ.rule.lit.expected.json b/packages/@aws-cdk/aws-config/test/integ.rule.lit.expected.json index 433de9a2406f5..f4d3bdb9fe17f 100644 --- a/packages/@aws-cdk/aws-config/test/integ.rule.lit.expected.json +++ b/packages/@aws-cdk/aws-config/test/integ.rule.lit.expected.json @@ -9,17 +9,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], @@ -150,17 +140,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "config.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "config.amazonaws.com" } } ], @@ -223,17 +203,7 @@ "Action": "sns:Publish", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "events.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "events.amazonaws.com" }, "Resource": { "Ref": "ComplianceTopic0229448B" diff --git a/packages/@aws-cdk/aws-config/test/test.managed-rules.ts b/packages/@aws-cdk/aws-config/test/test.managed-rules.ts index a589670c2f261..9bb3eed5bbbfb 100644 --- a/packages/@aws-cdk/aws-config/test/test.managed-rules.ts +++ b/packages/@aws-cdk/aws-config/test/test.managed-rules.ts @@ -58,17 +58,7 @@ export = { Action: 'sts:AssumeRole', Effect: 'Allow', Principal: { - Service: { - 'Fn::Join': [ - '', - [ - 'config.', - { - Ref: 'AWS::URLSuffix' - } - ] - ] - } + Service: "config.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-dynamodb-global/test/integ.dynamodb.global.expected.json b/packages/@aws-cdk/aws-dynamodb-global/test/integ.dynamodb.global.expected.json index 9e5abb9fc9bf1..aeef6408afa31 100644 --- a/packages/@aws-cdk/aws-dynamodb-global/test/integ.dynamodb.global.expected.json +++ b/packages/@aws-cdk/aws-dynamodb-global/test/integ.dynamodb.global.expected.json @@ -103,17 +103,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-ecr-assets/test/integ.assets-docker.expected.json b/packages/@aws-cdk/aws-ecr-assets/test/integ.assets-docker.expected.json index e37940ec0781d..64fba508faa44 100644 --- a/packages/@aws-cdk/aws-ecr-assets/test/integ.assets-docker.expected.json +++ b/packages/@aws-cdk/aws-ecr-assets/test/integ.assets-docker.expected.json @@ -57,17 +57,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-ecs-patterns/test/ec2/integ.scheduled-ecs-task.lit.expected.json b/packages/@aws-cdk/aws-ecs-patterns/test/ec2/integ.scheduled-ecs-task.lit.expected.json index adafa4088df52..be63f90387b2d 100644 --- a/packages/@aws-cdk/aws-ecs-patterns/test/ec2/integ.scheduled-ecs-task.lit.expected.json +++ b/packages/@aws-cdk/aws-ecs-patterns/test/ec2/integ.scheduled-ecs-task.lit.expected.json @@ -363,17 +363,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], @@ -562,17 +552,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "autoscaling.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "autoscaling.amazonaws.com" } } ], @@ -630,6 +610,37 @@ "EcsClusterDefaultAutoScalingGroupLifecycleHookDrainHookRoleA38EC83B" ] }, + "ScheduledEc2TaskScheduledEventRuleFE2376A2": { + "Type": "AWS::Events::Rule", + "Properties": { + "ScheduleExpression": "rate(1 minute)", + "State": "ENABLED", + "Targets": [ + { + "Arn": { + "Fn::GetAtt": [ + "EcsCluster97242B84", + "Arn" + ] + }, + "EcsParameters": { + "TaskCount": 2, + "TaskDefinitionArn": { + "Ref": "ScheduledEc2TaskScheduledTaskDef56328BA4" + } + }, + "Id": "Target0", + "Input": "{}", + "RoleArn": { + "Fn::GetAtt": [ + "ScheduledEc2TaskScheduledTaskDefEventsRole64113C5F", + "Arn" + ] + } + } + ] + } + }, "ScheduledEc2TaskScheduledTaskDefTaskRoleC3FA127C": { "Type": "AWS::IAM::Role", "Properties": { @@ -639,17 +650,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ecs-tasks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ecs-tasks.amazonaws.com" } } ], @@ -709,8 +710,8 @@ }, "ScheduledEc2TaskScheduledTaskDefScheduledContainerLogGroupA85E11E6": { "Type": "AWS::Logs::LogGroup", - "DeletionPolicy": "Retain", - "UpdateReplacePolicy": "Retain" + "UpdateReplacePolicy": "Retain", + "DeletionPolicy": "Retain" }, "ScheduledEc2TaskScheduledTaskDefExecutionRole65A8CC6F": { "Type": "AWS::IAM::Role", @@ -721,17 +722,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ecs-tasks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ecs-tasks.amazonaws.com" } } ], @@ -777,17 +768,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "events.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "events.amazonaws.com" } } ], @@ -837,37 +818,6 @@ } ] } - }, - "ScheduledEc2TaskScheduledEventRuleFE2376A2": { - "Type": "AWS::Events::Rule", - "Properties": { - "ScheduleExpression": "rate(1 minute)", - "State": "ENABLED", - "Targets": [ - { - "Arn": { - "Fn::GetAtt": [ - "EcsCluster97242B84", - "Arn" - ] - }, - "EcsParameters": { - "TaskCount": 2, - "TaskDefinitionArn": { - "Ref": "ScheduledEc2TaskScheduledTaskDef56328BA4" - } - }, - "Id": "Target0", - "Input": "{}", - "RoleArn": { - "Fn::GetAtt": [ - "ScheduledEc2TaskScheduledTaskDefEventsRole64113C5F", - "Arn" - ] - } - } - ] - } } }, "Parameters": { @@ -876,4 +826,4 @@ "Default": "/aws/service/ecs/optimized-ami/amazon-linux-2/recommended/image_id" } } -} +} \ No newline at end of file diff --git a/packages/@aws-cdk/aws-ecs-patterns/test/fargate/integ.asset-image.expected.json b/packages/@aws-cdk/aws-ecs-patterns/test/fargate/integ.asset-image.expected.json index e8363a409563e..5f8ea8db91cd7 100644 --- a/packages/@aws-cdk/aws-ecs-patterns/test/fargate/integ.asset-image.expected.json +++ b/packages/@aws-cdk/aws-ecs-patterns/test/fargate/integ.asset-image.expected.json @@ -455,17 +455,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ecs-tasks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ecs-tasks.amazonaws.com" } } ], @@ -671,17 +661,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ecs-tasks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ecs-tasks.amazonaws.com" } } ], @@ -857,17 +837,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-ecs-patterns/test/fargate/integ.executionrole.expected.json b/packages/@aws-cdk/aws-ecs-patterns/test/fargate/integ.executionrole.expected.json index f152a3c201577..443a71ca88d8a 100644 --- a/packages/@aws-cdk/aws-ecs-patterns/test/fargate/integ.executionrole.expected.json +++ b/packages/@aws-cdk/aws-ecs-patterns/test/fargate/integ.executionrole.expected.json @@ -356,28 +356,8 @@ "Effect": "Allow", "Principal": { "Service": [ - { - "Fn::Join": [ - "", - [ - "ecs.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - }, - { - "Fn::Join": [ - "", - [ - "ecs-tasks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "ecs.amazonaws.com", + "ecs-tasks.amazonaws.com" ] } } @@ -524,17 +504,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ecs-tasks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ecs-tasks.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-ecs-patterns/test/fargate/integ.l3-autocreate.expected.json b/packages/@aws-cdk/aws-ecs-patterns/test/fargate/integ.l3-autocreate.expected.json index b8e8c59ed8337..f9dcafce80e1b 100644 --- a/packages/@aws-cdk/aws-ecs-patterns/test/fargate/integ.l3-autocreate.expected.json +++ b/packages/@aws-cdk/aws-ecs-patterns/test/fargate/integ.l3-autocreate.expected.json @@ -109,17 +109,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ecs-tasks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ecs-tasks.amazonaws.com" } } ], @@ -191,17 +181,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ecs-tasks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ecs-tasks.amazonaws.com" } } ], @@ -784,17 +764,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ecs-tasks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ecs-tasks.amazonaws.com" } } ], @@ -866,17 +836,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ecs-tasks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ecs-tasks.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-ecs-patterns/test/fargate/integ.l3-vpconly.expected.json b/packages/@aws-cdk/aws-ecs-patterns/test/fargate/integ.l3-vpconly.expected.json index e7f468acf6245..8803e34a6648d 100644 --- a/packages/@aws-cdk/aws-ecs-patterns/test/fargate/integ.l3-vpconly.expected.json +++ b/packages/@aws-cdk/aws-ecs-patterns/test/fargate/integ.l3-vpconly.expected.json @@ -452,17 +452,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ecs-tasks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ecs-tasks.amazonaws.com" } } ], @@ -534,17 +524,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ecs-tasks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ecs-tasks.amazonaws.com" } } ], @@ -1127,17 +1107,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ecs-tasks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ecs-tasks.amazonaws.com" } } ], @@ -1209,17 +1179,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ecs-tasks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ecs-tasks.amazonaws.com" } } ], @@ -1459,17 +1419,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ecs-tasks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ecs-tasks.amazonaws.com" } } ], @@ -1541,17 +1491,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ecs-tasks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ecs-tasks.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-ecs-patterns/test/fargate/integ.l3.expected.json b/packages/@aws-cdk/aws-ecs-patterns/test/fargate/integ.l3.expected.json index 310c9e0578b44..598cf27c98f59 100644 --- a/packages/@aws-cdk/aws-ecs-patterns/test/fargate/integ.l3.expected.json +++ b/packages/@aws-cdk/aws-ecs-patterns/test/fargate/integ.l3.expected.json @@ -455,17 +455,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ecs-tasks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ecs-tasks.amazonaws.com" } } ], @@ -532,17 +522,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ecs-tasks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ecs-tasks.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-ecs-patterns/test/fargate/integ.scheduled-fargate-task.lit.expected.json b/packages/@aws-cdk/aws-ecs-patterns/test/fargate/integ.scheduled-fargate-task.lit.expected.json index ae6840c20dec3..f1eac0a73c85c 100644 --- a/packages/@aws-cdk/aws-ecs-patterns/test/fargate/integ.scheduled-fargate-task.lit.expected.json +++ b/packages/@aws-cdk/aws-ecs-patterns/test/fargate/integ.scheduled-fargate-task.lit.expected.json @@ -233,17 +233,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ecs-tasks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ecs-tasks.amazonaws.com" } } ], @@ -449,17 +439,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ecs-tasks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ecs-tasks.amazonaws.com" } } ], @@ -561,17 +541,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "events.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "events.amazonaws.com" } } ], @@ -808,17 +778,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], @@ -964,17 +924,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-ecs/test/ec2/integ.lb-awsvpc-nw.expected.json b/packages/@aws-cdk/aws-ecs/test/ec2/integ.lb-awsvpc-nw.expected.json index 04234cd5ddbfd..e03454c9adbc1 100644 --- a/packages/@aws-cdk/aws-ecs/test/ec2/integ.lb-awsvpc-nw.expected.json +++ b/packages/@aws-cdk/aws-ecs/test/ec2/integ.lb-awsvpc-nw.expected.json @@ -519,17 +519,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], @@ -718,17 +708,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "autoscaling.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "autoscaling.amazonaws.com" } } ], @@ -795,17 +775,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ecs-tasks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ecs-tasks.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-ecs/test/ec2/integ.lb-bridge-nw.expected.json b/packages/@aws-cdk/aws-ecs/test/ec2/integ.lb-bridge-nw.expected.json index 533dc55691571..f4a9e19a888b6 100644 --- a/packages/@aws-cdk/aws-ecs/test/ec2/integ.lb-bridge-nw.expected.json +++ b/packages/@aws-cdk/aws-ecs/test/ec2/integ.lb-bridge-nw.expected.json @@ -540,17 +540,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], @@ -739,17 +729,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "autoscaling.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "autoscaling.amazonaws.com" } } ], @@ -816,17 +796,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ecs-tasks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ecs-tasks.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-ecs/test/ec2/integ.sd-awsvpc-nw.expected.json b/packages/@aws-cdk/aws-ecs/test/ec2/integ.sd-awsvpc-nw.expected.json index 252f04c6e85ff..45fc4db86e218 100644 --- a/packages/@aws-cdk/aws-ecs/test/ec2/integ.sd-awsvpc-nw.expected.json +++ b/packages/@aws-cdk/aws-ecs/test/ec2/integ.sd-awsvpc-nw.expected.json @@ -519,17 +519,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], @@ -718,17 +708,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "autoscaling.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "autoscaling.amazonaws.com" } } ], @@ -804,17 +784,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ecs-tasks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ecs-tasks.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-ecs/test/ec2/integ.sd-bridge-nw.expected.json b/packages/@aws-cdk/aws-ecs/test/ec2/integ.sd-bridge-nw.expected.json index 3405d3006ead3..467572c76a607 100644 --- a/packages/@aws-cdk/aws-ecs/test/ec2/integ.sd-bridge-nw.expected.json +++ b/packages/@aws-cdk/aws-ecs/test/ec2/integ.sd-bridge-nw.expected.json @@ -519,17 +519,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], @@ -718,17 +708,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "autoscaling.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "autoscaling.amazonaws.com" } } ], @@ -804,17 +784,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ecs-tasks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ecs-tasks.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-ecs/test/fargate/integ.lb-awsvpc-nw.expected.json b/packages/@aws-cdk/aws-ecs/test/fargate/integ.lb-awsvpc-nw.expected.json index 9b6d06f47c9eb..a3084f55bac04 100644 --- a/packages/@aws-cdk/aws-ecs/test/fargate/integ.lb-awsvpc-nw.expected.json +++ b/packages/@aws-cdk/aws-ecs/test/fargate/integ.lb-awsvpc-nw.expected.json @@ -355,17 +355,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ecs-tasks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ecs-tasks.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-eks/test/integ.eks-cluster.defaults.expected.json b/packages/@aws-cdk/aws-eks/test/integ.eks-cluster.defaults.expected.json index f3c7d34a8e036..1a35f00a8133e 100644 --- a/packages/@aws-cdk/aws-eks/test/integ.eks-cluster.defaults.expected.json +++ b/packages/@aws-cdk/aws-eks/test/integ.eks-cluster.defaults.expected.json @@ -530,17 +530,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "eks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "eks.amazonaws.com" } } ], @@ -621,17 +611,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-eks/test/integ.eks-cluster.kubectl-disabled.expected.json b/packages/@aws-cdk/aws-eks/test/integ.eks-cluster.kubectl-disabled.expected.json index 49df9abfb7b16..26e721325c34c 100644 --- a/packages/@aws-cdk/aws-eks/test/integ.eks-cluster.kubectl-disabled.expected.json +++ b/packages/@aws-cdk/aws-eks/test/integ.eks-cluster.kubectl-disabled.expected.json @@ -529,17 +529,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "eks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "eks.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-eks/test/integ.eks-cluster.lit.expected.json b/packages/@aws-cdk/aws-eks/test/integ.eks-cluster.lit.expected.json index 54dd085fde746..fa34edfc46a59 100644 --- a/packages/@aws-cdk/aws-eks/test/integ.eks-cluster.lit.expected.json +++ b/packages/@aws-cdk/aws-eks/test/integ.eks-cluster.lit.expected.json @@ -530,17 +530,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "eks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "eks.amazonaws.com" } } ], @@ -621,17 +611,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-eks/test/integ.eks-kubectl.lit.expected.json b/packages/@aws-cdk/aws-eks/test/integ.eks-kubectl.lit.expected.json index 91782b6b4bbc5..7c43f8ba75cce 100644 --- a/packages/@aws-cdk/aws-eks/test/integ.eks-kubectl.lit.expected.json +++ b/packages/@aws-cdk/aws-eks/test/integ.eks-kubectl.lit.expected.json @@ -416,17 +416,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "eks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "eks.amazonaws.com" } } ], @@ -507,17 +497,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-events-targets/test/codebuild/codebuild.test.ts b/packages/@aws-cdk/aws-events-targets/test/codebuild/codebuild.test.ts index fd9eecc4beff9..136b245cc8ad1 100644 --- a/packages/@aws-cdk/aws-events-targets/test/codebuild/codebuild.test.ts +++ b/packages/@aws-cdk/aws-events-targets/test/codebuild/codebuild.test.ts @@ -42,7 +42,7 @@ test('use codebuild project as an eventrule target', () => { { Action: "sts:AssumeRole", Effect: "Allow", - Principal: { Service: { "Fn::Join": [ "", [ "events.", { Ref: "AWS::URLSuffix" } ] ] } } + Principal: { Service: "events.amazonaws.com" } } ], Version: "2012-10-17" diff --git a/packages/@aws-cdk/aws-events-targets/test/codebuild/integ.project-events.expected.json b/packages/@aws-cdk/aws-events-targets/test/codebuild/integ.project-events.expected.json index 3943db5cdaf0d..c008bfa268b8a 100644 --- a/packages/@aws-cdk/aws-events-targets/test/codebuild/integ.project-events.expected.json +++ b/packages/@aws-cdk/aws-events-targets/test/codebuild/integ.project-events.expected.json @@ -77,17 +77,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codebuild.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codebuild.amazonaws.com" } } ], @@ -280,17 +270,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "events.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "events.amazonaws.com" } } ], @@ -389,17 +369,7 @@ "Action": "sns:Publish", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "events.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "events.amazonaws.com" }, "Resource": { "Ref": "MyTopic86869434" diff --git a/packages/@aws-cdk/aws-events-targets/test/codepipeline/integ.pipeline-event-target.expected.json b/packages/@aws-cdk/aws-events-targets/test/codepipeline/integ.pipeline-event-target.expected.json index 0d49cfe45247c..c0c39b10c7923 100644 --- a/packages/@aws-cdk/aws-events-targets/test/codepipeline/integ.pipeline-event-target.expected.json +++ b/packages/@aws-cdk/aws-events-targets/test/codepipeline/integ.pipeline-event-target.expected.json @@ -106,17 +106,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "codepipeline.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "codepipeline.amazonaws.com" } } ], @@ -373,17 +363,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "events.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "events.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-events-targets/test/ecs/integ.event-ec2-task.lit.expected.json b/packages/@aws-cdk/aws-events-targets/test/ecs/integ.event-ec2-task.lit.expected.json index bd446ad581462..7e6f9d531044c 100644 --- a/packages/@aws-cdk/aws-events-targets/test/ecs/integ.event-ec2-task.lit.expected.json +++ b/packages/@aws-cdk/aws-events-targets/test/ecs/integ.event-ec2-task.lit.expected.json @@ -363,17 +363,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], @@ -562,17 +552,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "autoscaling.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "autoscaling.amazonaws.com" } } ], @@ -639,17 +619,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ecs-tasks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ecs-tasks.amazonaws.com" } } ], @@ -848,17 +818,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ecs-tasks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ecs-tasks.amazonaws.com" } } ], @@ -943,17 +903,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "events.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "events.amazonaws.com" } } ], @@ -1013,17 +963,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-events-targets/test/ecs/integ.event-fargate-task.expected.json b/packages/@aws-cdk/aws-events-targets/test/ecs/integ.event-fargate-task.expected.json index 305b0394cdc5c..8ff9da4e62423 100644 --- a/packages/@aws-cdk/aws-events-targets/test/ecs/integ.event-fargate-task.expected.json +++ b/packages/@aws-cdk/aws-events-targets/test/ecs/integ.event-fargate-task.expected.json @@ -202,17 +202,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ecs-tasks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ecs-tasks.amazonaws.com" } } ], @@ -412,17 +402,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ecs-tasks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ecs-tasks.amazonaws.com" } } ], @@ -524,17 +504,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "events.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "events.amazonaws.com" } } ], @@ -771,17 +741,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], @@ -958,17 +918,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-events-targets/test/lambda/integ.events.expected.json b/packages/@aws-cdk/aws-events-targets/test/lambda/integ.events.expected.json index e2b00b5ad3537..70c7b51c894e2 100644 --- a/packages/@aws-cdk/aws-events-targets/test/lambda/integ.events.expected.json +++ b/packages/@aws-cdk/aws-events-targets/test/lambda/integ.events.expected.json @@ -9,17 +9,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-events-targets/test/sns/integ.sns-event-rule-target.expected.json b/packages/@aws-cdk/aws-events-targets/test/sns/integ.sns-event-rule-target.expected.json index f1c2724a24a6f..acefc346d52bf 100644 --- a/packages/@aws-cdk/aws-events-targets/test/sns/integ.sns-event-rule-target.expected.json +++ b/packages/@aws-cdk/aws-events-targets/test/sns/integ.sns-event-rule-target.expected.json @@ -12,17 +12,7 @@ "Action": "sns:Publish", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "events.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "events.amazonaws.com" }, "Resource": { "Ref": "MyTopic86869434" diff --git a/packages/@aws-cdk/aws-events-targets/test/sns/sns.test.ts b/packages/@aws-cdk/aws-events-targets/test/sns/sns.test.ts index 4f6fbc20ceb14..201a8248d124b 100644 --- a/packages/@aws-cdk/aws-events-targets/test/sns/sns.test.ts +++ b/packages/@aws-cdk/aws-events-targets/test/sns/sns.test.ts @@ -23,7 +23,7 @@ test('sns topic as an event rule target', () => { Sid: "0", Action: "sns:Publish", Effect: "Allow", - Principal: { Service: { "Fn::Join": ["", ["events.", { Ref: "AWS::URLSuffix" }]] } }, + Principal: { Service: "events.amazonaws.com" }, Resource: { Ref: "MyTopic86869434" } } ], @@ -64,7 +64,7 @@ test('multiple uses of a topic as a target results in a single policy statement' { Action: "sns:Publish", Effect: "Allow", - Principal: { Service: { "Fn::Join": [ "", [ "events.", { Ref: "AWS::URLSuffix" } ] ] } }, + Principal: { Service: "events.amazonaws.com" }, Resource: { Ref: "MyTopic86869434" }, Sid: "0" } diff --git a/packages/@aws-cdk/aws-events-targets/test/sqs/integ.sqs-event-rule-target.expected.json b/packages/@aws-cdk/aws-events-targets/test/sqs/integ.sqs-event-rule-target.expected.json index 4fd7303901d20..3a6083aec5968 100644 --- a/packages/@aws-cdk/aws-events-targets/test/sqs/integ.sqs-event-rule-target.expected.json +++ b/packages/@aws-cdk/aws-events-targets/test/sqs/integ.sqs-event-rule-target.expected.json @@ -44,17 +44,7 @@ }, "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "events.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "events.amazonaws.com" }, "Resource": { "Fn::GetAtt": [ diff --git a/packages/@aws-cdk/aws-events-targets/test/sqs/sqs.test.ts b/packages/@aws-cdk/aws-events-targets/test/sqs/sqs.test.ts index eb12e2f471b66..c1a8a54909a76 100644 --- a/packages/@aws-cdk/aws-events-targets/test/sqs/sqs.test.ts +++ b/packages/@aws-cdk/aws-events-targets/test/sqs/sqs.test.ts @@ -36,7 +36,7 @@ test('sns topic as an event rule target', () => { } }, Effect: "Allow", - Principal: { Service: { "Fn::Join": ["", ["events.", { Ref: "AWS::URLSuffix" }]] } }, + Principal: { Service: "events.amazonaws.com" }, Resource: { "Fn::GetAtt": [ "MyQueueE6CA6235", @@ -101,7 +101,7 @@ test('multiple uses of a queue as a target results in multi policy statement bec } }, Effect: "Allow", - Principal: { Service: { "Fn::Join": ["", ["events.", { Ref: "AWS::URLSuffix" }]] } }, + Principal: { Service: "events.amazonaws.com" }, Resource: { "Fn::GetAtt": [ "MyQueueE6CA6235", @@ -126,7 +126,7 @@ test('multiple uses of a queue as a target results in multi policy statement bec } }, Effect: "Allow", - Principal: { Service: { "Fn::Join": ["", ["events.", { Ref: "AWS::URLSuffix" }]] } }, + Principal: { Service: "events.amazonaws.com" }, Resource: { "Fn::GetAtt": [ "MyQueueE6CA6235", diff --git a/packages/@aws-cdk/aws-lambda-event-sources/test/integ.dynamodb.expected.json b/packages/@aws-cdk/aws-lambda-event-sources/test/integ.dynamodb.expected.json index 51e799cdf0691..286d5d2c7fe45 100644 --- a/packages/@aws-cdk/aws-lambda-event-sources/test/integ.dynamodb.expected.json +++ b/packages/@aws-cdk/aws-lambda-event-sources/test/integ.dynamodb.expected.json @@ -9,17 +9,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-lambda-event-sources/test/integ.kinesis.expected.json b/packages/@aws-cdk/aws-lambda-event-sources/test/integ.kinesis.expected.json index d9e448f80376a..d811834a7f0b1 100644 --- a/packages/@aws-cdk/aws-lambda-event-sources/test/integ.kinesis.expected.json +++ b/packages/@aws-cdk/aws-lambda-event-sources/test/integ.kinesis.expected.json @@ -9,17 +9,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-lambda-event-sources/test/integ.s3.expected.json b/packages/@aws-cdk/aws-lambda-event-sources/test/integ.s3.expected.json index 9fa4ec5ff6f07..c69002cac094c 100644 --- a/packages/@aws-cdk/aws-lambda-event-sources/test/integ.s3.expected.json +++ b/packages/@aws-cdk/aws-lambda-event-sources/test/integ.s3.expected.json @@ -9,17 +9,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], @@ -138,17 +128,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-lambda-event-sources/test/integ.sns.expected.json b/packages/@aws-cdk/aws-lambda-event-sources/test/integ.sns.expected.json index 405bc0a38f133..c2bacb9caac2d 100644 --- a/packages/@aws-cdk/aws-lambda-event-sources/test/integ.sns.expected.json +++ b/packages/@aws-cdk/aws-lambda-event-sources/test/integ.sns.expected.json @@ -9,17 +9,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-lambda-event-sources/test/integ.sqs.expected.json b/packages/@aws-cdk/aws-lambda-event-sources/test/integ.sqs.expected.json index 3870ec4882b60..035a78c7e57b8 100644 --- a/packages/@aws-cdk/aws-lambda-event-sources/test/integ.sqs.expected.json +++ b/packages/@aws-cdk/aws-lambda-event-sources/test/integ.sqs.expected.json @@ -9,17 +9,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-lambda/test/integ.assets.file.expected.json b/packages/@aws-cdk/aws-lambda/test/integ.assets.file.expected.json index 8feb8949c3bd0..a29705f32d7d7 100644 --- a/packages/@aws-cdk/aws-lambda/test/integ.assets.file.expected.json +++ b/packages/@aws-cdk/aws-lambda/test/integ.assets.file.expected.json @@ -9,17 +9,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-lambda/test/integ.assets.lit.expected.json b/packages/@aws-cdk/aws-lambda/test/integ.assets.lit.expected.json index f3801a2eabf33..471b6c52a3932 100644 --- a/packages/@aws-cdk/aws-lambda/test/integ.assets.lit.expected.json +++ b/packages/@aws-cdk/aws-lambda/test/integ.assets.lit.expected.json @@ -9,17 +9,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-lambda/test/integ.lambda.expected.json b/packages/@aws-cdk/aws-lambda/test/integ.lambda.expected.json index 2e397aba640bc..bfac9da40ab69 100644 --- a/packages/@aws-cdk/aws-lambda/test/integ.lambda.expected.json +++ b/packages/@aws-cdk/aws-lambda/test/integ.lambda.expected.json @@ -9,17 +9,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-lambda/test/integ.layer-version.lit.expected.json b/packages/@aws-cdk/aws-lambda/test/integ.layer-version.lit.expected.json index 6021ea98d0d22..c660e83fac680 100644 --- a/packages/@aws-cdk/aws-lambda/test/integ.layer-version.lit.expected.json +++ b/packages/@aws-cdk/aws-lambda/test/integ.layer-version.lit.expected.json @@ -83,17 +83,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-lambda/test/integ.log-retention.expected.json b/packages/@aws-cdk/aws-lambda/test/integ.log-retention.expected.json index 0cdb053275989..65f846b0e0a50 100644 --- a/packages/@aws-cdk/aws-lambda/test/integ.log-retention.expected.json +++ b/packages/@aws-cdk/aws-lambda/test/integ.log-retention.expected.json @@ -9,17 +9,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], @@ -92,17 +82,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], @@ -212,17 +192,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], @@ -295,17 +265,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-lambda/test/integ.vpc-lambda.expected.json b/packages/@aws-cdk/aws-lambda/test/integ.vpc-lambda.expected.json index 29ed9ff030b3a..f432ae88789d3 100644 --- a/packages/@aws-cdk/aws-lambda/test/integ.vpc-lambda.expected.json +++ b/packages/@aws-cdk/aws-lambda/test/integ.vpc-lambda.expected.json @@ -352,17 +352,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-lambda/test/test.lambda.ts b/packages/@aws-cdk/aws-lambda/test/test.lambda.ts index d6b36ab1f2a11..e2d6966d886b7 100644 --- a/packages/@aws-cdk/aws-lambda/test/test.lambda.ts +++ b/packages/@aws-cdk/aws-lambda/test/test.lambda.ts @@ -27,7 +27,7 @@ export = { { Statement: [ { Action: 'sts:AssumeRole', Effect: 'Allow', - Principal: { Service: { "Fn::Join": ["", ['lambda.', { Ref: "AWS::URLSuffix" }]] } } } ], + Principal: { Service: "lambda.amazonaws.com" } } ], Version: '2012-10-17' }, ManagedPolicyArns: // arn:aws:iam::aws:policy/service-role/AWSLambdaBasicExecutionRole @@ -61,7 +61,7 @@ export = { { Statement: [ { Action: 'sts:AssumeRole', Effect: 'Allow', - Principal: { Service: { "Fn::Join": ["", ['lambda.', { Ref: "AWS::URLSuffix" }]] } } } ], + Principal: { Service: "lambda.amazonaws.com" } } ], Version: '2012-10-17' }, ManagedPolicyArns: // tslint:disable-next-line:max-line-length @@ -133,7 +133,7 @@ export = { "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { "Fn::Join": ["", ["lambda.", { Ref: "AWS::URLSuffix" }]] } + "Service": "lambda.amazonaws.com" } } ], @@ -311,7 +311,7 @@ export = { "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { "Fn::Join": ["", ["lambda.", { Ref: "AWS::URLSuffix" }]] } + "Service": "lambda.amazonaws.com" } } ], @@ -422,7 +422,7 @@ export = { "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { "Fn::Join": ["", ["lambda.", { Ref: "AWS::URLSuffix" }]] } + "Service": "lambda.amazonaws.com" } } ], @@ -532,7 +532,7 @@ export = { "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { "Fn::Join": ["", ["lambda.", { Ref: "AWS::URLSuffix" }]] } + "Service": "lambda.amazonaws.com" } } ], @@ -606,7 +606,7 @@ export = { "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { "Fn::Join": ["", ["lambda.", { Ref: "AWS::URLSuffix" }]] } + "Service": "lambda.amazonaws.com" } } ], @@ -716,7 +716,7 @@ export = { "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { "Fn::Join": ["", ["lambda.", { Ref: "AWS::URLSuffix" }]] } + "Service": "lambda.amazonaws.com" } } ], @@ -1165,7 +1165,7 @@ export = { { Statement: [ { Action: 'sts:AssumeRole', Effect: 'Allow', - Principal: { Service: { "Fn::Join": ["", ['lambda.', { Ref: "AWS::URLSuffix" }]] } } } ], + Principal: { Service: "lambda.amazonaws.com" } } ], Version: '2012-10-17' }, ManagedPolicyArns: // arn:aws:iam::aws:policy/service-role/AWSLambdaBasicExecutionRole @@ -1287,7 +1287,7 @@ export = { { Statement: [ { Action: 'sts:AssumeRole', Effect: 'Allow', - Principal: { Service: { "Fn::Join": ["", ['lambda.', { Ref: "AWS::URLSuffix" }]] } } } ], + Principal: { Service: "lambda.amazonaws.com" } } ], Version: '2012-10-17' }, ManagedPolicyArns: // arn:aws:iam::aws:policy/service-role/AWSLambdaBasicExecutionRole diff --git a/packages/@aws-cdk/aws-lambda/test/test.singleton-lambda.ts b/packages/@aws-cdk/aws-lambda/test/test.singleton-lambda.ts index 54c27131f10d6..da2bb652ae88d 100644 --- a/packages/@aws-cdk/aws-lambda/test/test.singleton-lambda.ts +++ b/packages/@aws-cdk/aws-lambda/test/test.singleton-lambda.ts @@ -30,7 +30,7 @@ export = { { Action: "sts:AssumeRole", Effect: "Allow", - Principal: { Service: { "Fn::Join": ["", ["lambda.", { Ref: "AWS::URLSuffix" }]] } } + Principal: { Service: "lambda.amazonaws.com" } } ], Version: "2012-10-17" diff --git a/packages/@aws-cdk/aws-rds/test/integ.instance.lit.expected.json b/packages/@aws-cdk/aws-rds/test/integ.instance.lit.expected.json index 204b222421d16..206a46862d4b3 100644 --- a/packages/@aws-cdk/aws-rds/test/integ.instance.lit.expected.json +++ b/packages/@aws-cdk/aws-rds/test/integ.instance.lit.expected.json @@ -898,17 +898,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], @@ -1038,17 +1028,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-route53-targets/test/integ.api-gateway-domain-name.expected.json b/packages/@aws-cdk/aws-route53-targets/test/integ.api-gateway-domain-name.expected.json index cc1516a41cb4e..c0b7ef3d6df98 100644 --- a/packages/@aws-cdk/aws-route53-targets/test/integ.api-gateway-domain-name.expected.json +++ b/packages/@aws-cdk/aws-route53-targets/test/integ.api-gateway-domain-name.expected.json @@ -9,17 +9,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], @@ -257,17 +247,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "apigateway.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "apigateway.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-s3-deployment/test/integ.bucket-deployment-cloudfront.expected.json b/packages/@aws-cdk/aws-s3-deployment/test/integ.bucket-deployment-cloudfront.expected.json index a9100107b7b87..a7f56d357e16f 100644 --- a/packages/@aws-cdk/aws-s3-deployment/test/integ.bucket-deployment-cloudfront.expected.json +++ b/packages/@aws-cdk/aws-s3-deployment/test/integ.bucket-deployment-cloudfront.expected.json @@ -9,17 +9,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-s3-deployment/test/integ.bucket-deployment.expected.json b/packages/@aws-cdk/aws-s3-deployment/test/integ.bucket-deployment.expected.json index 47756b1a2d639..5d50fa925670c 100644 --- a/packages/@aws-cdk/aws-s3-deployment/test/integ.bucket-deployment.expected.json +++ b/packages/@aws-cdk/aws-s3-deployment/test/integ.bucket-deployment.expected.json @@ -104,18 +104,8 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] + "Service": "lambda.amazonaws.com" } - } } ], "Version": "2012-10-17" diff --git a/packages/@aws-cdk/aws-s3-notifications/test/integ.notifications.expected.json b/packages/@aws-cdk/aws-s3-notifications/test/integ.notifications.expected.json index 865e840316c65..ed7e37726e8ef 100644 --- a/packages/@aws-cdk/aws-s3-notifications/test/integ.notifications.expected.json +++ b/packages/@aws-cdk/aws-s3-notifications/test/integ.notifications.expected.json @@ -77,17 +77,7 @@ }, "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "s3.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "s3.amazonaws.com" }, "Resource": { "Ref": "TopicBFC7AF6E" @@ -126,17 +116,7 @@ }, "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "s3.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "s3.amazonaws.com" }, "Resource": { "Ref": "Topic3DEAE47A7" @@ -157,17 +137,7 @@ }, "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "s3.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "s3.amazonaws.com" }, "Resource": { "Ref": "Topic3DEAE47A7" @@ -193,17 +163,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-s3-notifications/test/lambda/integ.bucket-notifications.expected.json b/packages/@aws-cdk/aws-s3-notifications/test/lambda/integ.bucket-notifications.expected.json index e04c417c1b76e..05a6f78c87c24 100644 --- a/packages/@aws-cdk/aws-s3-notifications/test/lambda/integ.bucket-notifications.expected.json +++ b/packages/@aws-cdk/aws-s3-notifications/test/lambda/integ.bucket-notifications.expected.json @@ -1,9 +1,9 @@ { "Resources": { "MyBucketF68F3FF0": { - "DeletionPolicy": "Delete", + "Type": "AWS::S3::Bucket", "UpdateReplacePolicy": "Delete", - "Type": "AWS::S3::Bucket" + "DeletionPolicy": "Delete" }, "MyBucketNotifications46AC0CD2": { "Type": "Custom::S3BucketNotifications", @@ -56,17 +56,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], @@ -152,9 +142,9 @@ } }, "YourBucketC6A57364": { - "DeletionPolicy": "Delete", + "Type": "AWS::S3::Bucket", "UpdateReplacePolicy": "Delete", - "Type": "AWS::S3::Bucket" + "DeletionPolicy": "Delete" }, "YourBucketNotifications8D39901A": { "Type": "Custom::S3BucketNotifications", @@ -197,17 +187,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], @@ -269,4 +249,4 @@ } } } -} +} \ No newline at end of file diff --git a/packages/@aws-cdk/aws-s3-notifications/test/notifications.test.ts b/packages/@aws-cdk/aws-s3-notifications/test/notifications.test.ts index 953d1d45939f9..68b08a0f2c9c6 100644 --- a/packages/@aws-cdk/aws-s3-notifications/test/notifications.test.ts +++ b/packages/@aws-cdk/aws-s3-notifications/test/notifications.test.ts @@ -88,7 +88,7 @@ test('bucketNotificationTarget is not called during synthesis', () => { }, "Effect": "Allow", "Principal": { - "Service": { "Fn::Join": ["", ["s3.", { Ref: "AWS::URLSuffix" }]] } + "Service": "s3.amazonaws.com" }, "Resource": { "Ref": "TopicBFC7AF6E" diff --git a/packages/@aws-cdk/aws-s3-notifications/test/queue.test.ts b/packages/@aws-cdk/aws-s3-notifications/test/queue.test.ts index 482859513a219..f097f13ff19a5 100644 --- a/packages/@aws-cdk/aws-s3-notifications/test/queue.test.ts +++ b/packages/@aws-cdk/aws-s3-notifications/test/queue.test.ts @@ -29,9 +29,7 @@ test('queues can be used as destinations', () => { }, Effect: "Allow", Principal: { - Service: { - "Fn::Join": ["", ["s3.", { Ref: "AWS::URLSuffix" }]] - } + Service: "s3.amazonaws.com" }, Resource: { "Fn::GetAtt": [ "Queue4A7E3555", "Arn" ] } @@ -117,7 +115,7 @@ test('if the queue is encrypted with a custom kms key, the key resource policy i }, Effect: "Allow", Principal: { - Service: { "Fn::Join": [ "", [ "s3.", { Ref: "AWS::URLSuffix" } ] ] } + Service: "s3.amazonaws.com" }, Resource: "*" }, @@ -128,9 +126,7 @@ test('if the queue is encrypted with a custom kms key, the key resource policy i ], Effect: "Allow", Principal: { - Service: { - "Fn::Join": ["", ["s3.", { Ref: "AWS::URLSuffix" }]] - } + Service: "s3.amazonaws.com" }, Resource: "*" } diff --git a/packages/@aws-cdk/aws-s3-notifications/test/sns.test.ts b/packages/@aws-cdk/aws-s3-notifications/test/sns.test.ts index fb04b981b1929..e46f07bebdb80 100644 --- a/packages/@aws-cdk/aws-s3-notifications/test/sns.test.ts +++ b/packages/@aws-cdk/aws-s3-notifications/test/sns.test.ts @@ -45,7 +45,7 @@ test('asBucketNotificationDestination adds bucket permissions only once for each }, Effect: "Allow", Principal: { - Service: { "Fn::Join": ["", ["s3.", { Ref: "AWS::URLSuffix" }]] } + Service: "s3.amazonaws.com" }, Resource: { Ref: "MyTopic86869434" @@ -61,7 +61,7 @@ test('asBucketNotificationDestination adds bucket permissions only once for each }, Effect: "Allow", Principal: { - Service: { "Fn::Join": ["", ["s3.", { Ref: "AWS::URLSuffix" }]] } + Service: "s3.amazonaws.com" }, Resource: { Ref: "MyTopic86869434" diff --git a/packages/@aws-cdk/aws-s3-notifications/test/sns/integ.sns-bucket-notifications.expected.json b/packages/@aws-cdk/aws-s3-notifications/test/sns/integ.sns-bucket-notifications.expected.json index e94ea8729a5f2..8fa798bc98625 100644 --- a/packages/@aws-cdk/aws-s3-notifications/test/sns/integ.sns-bucket-notifications.expected.json +++ b/packages/@aws-cdk/aws-s3-notifications/test/sns/integ.sns-bucket-notifications.expected.json @@ -22,17 +22,7 @@ }, "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "s3.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "s3.amazonaws.com" }, "Resource": { "Ref": "ObjectCreatedTopic92F47E19" @@ -71,17 +61,7 @@ }, "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "s3.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "s3.amazonaws.com" }, "Resource": { "Ref": "ObjectDeletedTopic2A914EC0" @@ -99,9 +79,9 @@ } }, "MyBucketF68F3FF0": { - "DeletionPolicy": "Delete", + "Type": "AWS::S3::Bucket", "UpdateReplacePolicy": "Delete", - "Type": "AWS::S3::Bucket" + "DeletionPolicy": "Delete" }, "MyBucketNotifications46AC0CD2": { "Type": "Custom::S3BucketNotifications", @@ -166,17 +146,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], @@ -238,4 +208,4 @@ } } } -} +} \ No newline at end of file diff --git a/packages/@aws-cdk/aws-s3-notifications/test/sqs/integ.bucket-notifications.expected.json b/packages/@aws-cdk/aws-s3-notifications/test/sqs/integ.bucket-notifications.expected.json index 0066ccc8545bb..03ed06e7199e4 100644 --- a/packages/@aws-cdk/aws-s3-notifications/test/sqs/integ.bucket-notifications.expected.json +++ b/packages/@aws-cdk/aws-s3-notifications/test/sqs/integ.bucket-notifications.expected.json @@ -1,9 +1,9 @@ { "Resources": { "Bucket12520700A": { - "DeletionPolicy": "Delete", + "Type": "AWS::S3::Bucket", "UpdateReplacePolicy": "Delete", - "Type": "AWS::S3::Bucket" + "DeletionPolicy": "Delete" }, "Bucket1NotificationsBC5D9A45": { "Type": "Custom::S3BucketNotifications", @@ -78,17 +78,7 @@ }, "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "s3.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "s3.amazonaws.com" }, "Resource": { "Fn::GetAtt": [ @@ -115,17 +105,7 @@ }, "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "s3.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "s3.amazonaws.com" }, "Resource": { "Fn::GetAtt": [ @@ -153,17 +133,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], @@ -225,9 +195,9 @@ } }, "Bucket25524B414": { - "DeletionPolicy": "Delete", + "Type": "AWS::S3::Bucket", "UpdateReplacePolicy": "Delete", - "Type": "AWS::S3::Bucket" + "DeletionPolicy": "Delete" }, "Bucket2NotificationsD9BA2A77": { "Type": "Custom::S3BucketNotifications", @@ -332,17 +302,7 @@ }, "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "s3.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "s3.amazonaws.com" }, "Resource": "*" }, @@ -353,17 +313,7 @@ ], "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "s3.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "s3.amazonaws.com" }, "Resource": "*" } @@ -372,8 +322,8 @@ }, "Description": "Created by sqs-bucket-notifications/EncryptedQueue" }, - "DeletionPolicy": "Retain", - "UpdateReplacePolicy": "Retain" + "UpdateReplacePolicy": "Retain", + "DeletionPolicy": "Retain" }, "EncryptedQueue0428C61A": { "Type": "AWS::SQS::Queue", @@ -409,17 +359,7 @@ }, "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "s3.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "s3.amazonaws.com" }, "Resource": { "Fn::GetAtt": [ @@ -439,4 +379,4 @@ } } } -} +} \ No newline at end of file diff --git a/packages/@aws-cdk/aws-ses/test/integ.receipt.expected.json b/packages/@aws-cdk/aws-ses/test/integ.receipt.expected.json index 2ed1697558d8b..4e5b436f838b8 100644 --- a/packages/@aws-cdk/aws-ses/test/integ.receipt.expected.json +++ b/packages/@aws-cdk/aws-ses/test/integ.receipt.expected.json @@ -12,17 +12,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], @@ -103,17 +93,7 @@ }, "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ses.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ses.amazonaws.com" }, "Resource": { "Fn::Join": [ @@ -195,17 +175,7 @@ }, "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ses.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ses.amazonaws.com" }, "Resource": "*" } @@ -355,17 +325,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-ses/test/test.receipt-rule-action.ts b/packages/@aws-cdk/aws-ses/test/test.receipt-rule-action.ts index 3ba10f0ee929e..fdd1d1ad25214 100644 --- a/packages/@aws-cdk/aws-ses/test/test.receipt-rule-action.ts +++ b/packages/@aws-cdk/aws-ses/test/test.receipt-rule-action.ts @@ -262,17 +262,7 @@ export = { }, Effect: 'Allow', Principal: { - Service: { - 'Fn::Join': [ - '', - [ - 'ses.', - { - Ref: 'AWS::URLSuffix' - } - ] - ] - } + Service: "ses.amazonaws.com" }, Resource: { 'Fn::Join': [ @@ -352,17 +342,7 @@ export = { }, Effect: 'Allow', Principal: { - Service: { - 'Fn::Join': [ - '', - [ - 'ses.', - { - Ref: 'AWS::URLSuffix' - } - ] - ] - } + Service: "ses.amazonaws.com" }, Resource: '*' } diff --git a/packages/@aws-cdk/aws-sns-subscriptions/test/integ.sns-lambda.expected.json b/packages/@aws-cdk/aws-sns-subscriptions/test/integ.sns-lambda.expected.json index a49b19b111728..4fece8e7569b8 100644 --- a/packages/@aws-cdk/aws-sns-subscriptions/test/integ.sns-lambda.expected.json +++ b/packages/@aws-cdk/aws-sns-subscriptions/test/integ.sns-lambda.expected.json @@ -12,17 +12,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], @@ -103,17 +93,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-sns-subscriptions/test/subs.test.ts b/packages/@aws-cdk/aws-sns-subscriptions/test/subs.test.ts index 415f4bee62816..3b653775fccf0 100644 --- a/packages/@aws-cdk/aws-sns-subscriptions/test/subs.test.ts +++ b/packages/@aws-cdk/aws-sns-subscriptions/test/subs.test.ts @@ -227,17 +227,7 @@ test('lambda subscription', () => { "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], @@ -421,17 +411,7 @@ test('multiple subscriptions', () => { "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-stepfunctions-tasks/test/integ.ec2-task.expected.json b/packages/@aws-cdk/aws-stepfunctions-tasks/test/integ.ec2-task.expected.json index 9c8661f59b669..fd4ffee6faced 100644 --- a/packages/@aws-cdk/aws-stepfunctions-tasks/test/integ.ec2-task.expected.json +++ b/packages/@aws-cdk/aws-stepfunctions-tasks/test/integ.ec2-task.expected.json @@ -171,17 +171,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], @@ -362,17 +352,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "autoscaling.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "autoscaling.amazonaws.com" } } ], @@ -439,17 +419,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ecs-tasks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ecs-tasks.amazonaws.com" } } ], @@ -630,17 +600,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ecs-tasks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ecs-tasks.amazonaws.com" } } ], @@ -717,17 +677,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-stepfunctions-tasks/test/integ.fargate-task.expected.json b/packages/@aws-cdk/aws-stepfunctions-tasks/test/integ.fargate-task.expected.json index ccc9d1c6d21cc..ecf4166601c78 100644 --- a/packages/@aws-cdk/aws-stepfunctions-tasks/test/integ.fargate-task.expected.json +++ b/packages/@aws-cdk/aws-stepfunctions-tasks/test/integ.fargate-task.expected.json @@ -12,17 +12,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ecs-tasks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ecs-tasks.amazonaws.com" } } ], @@ -205,17 +195,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "ecs-tasks.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "ecs-tasks.amazonaws.com" } } ], @@ -292,17 +272,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-stepfunctions-tasks/test/integ.invoke-function.expected.json b/packages/@aws-cdk/aws-stepfunctions-tasks/test/integ.invoke-function.expected.json index 16f8c78de01ff..5442217cf60a3 100644 --- a/packages/@aws-cdk/aws-stepfunctions-tasks/test/integ.invoke-function.expected.json +++ b/packages/@aws-cdk/aws-stepfunctions-tasks/test/integ.invoke-function.expected.json @@ -9,17 +9,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], @@ -104,17 +94,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/aws-stepfunctions-tasks/test/integ.sagemaker.expected.json b/packages/@aws-cdk/aws-stepfunctions-tasks/test/integ.sagemaker.expected.json index 61cb9c61815de..a005b7ccd93ef 100644 --- a/packages/@aws-cdk/aws-stepfunctions-tasks/test/integ.sagemaker.expected.json +++ b/packages/@aws-cdk/aws-stepfunctions-tasks/test/integ.sagemaker.expected.json @@ -113,17 +113,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "sagemaker.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "sagemaker.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/custom-resources/test/integ.aws-custom-resource.expected.json b/packages/@aws-cdk/custom-resources/test/integ.aws-custom-resource.expected.json index 96cc6253f4dcf..4f1cfb576b21f 100644 --- a/packages/@aws-cdk/custom-resources/test/integ.aws-custom-resource.expected.json +++ b/packages/@aws-cdk/custom-resources/test/integ.aws-custom-resource.expected.json @@ -51,17 +51,7 @@ "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": { - "Service": { - "Fn::Join": [ - "", - [ - "lambda.", - { - "Ref": "AWS::URLSuffix" - } - ] - ] - } + "Service": "lambda.amazonaws.com" } } ], diff --git a/packages/@aws-cdk/region-info/build-tools/aws-entities.ts b/packages/@aws-cdk/region-info/build-tools/aws-entities.ts index b245c5f0657e6..8d68a59957974 100644 --- a/packages/@aws-cdk/region-info/build-tools/aws-entities.ts +++ b/packages/@aws-cdk/region-info/build-tools/aws-entities.ts @@ -8,8 +8,8 @@ export const AWS_REGIONS = [ 'us-east-1', 'us-west-1', 'us-west-2', + 'ap-east-1', 'ap-south-1', - 'ap-northeast-3', 'ap-northeast-2', 'ap-southeast-1', 'ap-southeast-2', @@ -22,13 +22,14 @@ export const AWS_REGIONS = [ 'eu-west-2', 'eu-west-3', 'eu-north-1', + 'me-south-1', 'sa-east-1', ].sort(); /** * Possibly non-exaustive list of all service names, used to locate service principals. * - * Not in the list ==> no built-in service principal mappings. + * Not in the list ==> default service principal mappings. */ export const AWS_SERVICES = [ 'application-autoscaling', diff --git a/packages/@aws-cdk/region-info/build-tools/generate-static-data.ts b/packages/@aws-cdk/region-info/build-tools/generate-static-data.ts index 51c107ac4db4b..f135c2beb43b7 100644 --- a/packages/@aws-cdk/region-info/build-tools/generate-static-data.ts +++ b/packages/@aws-cdk/region-info/build-tools/generate-static-data.ts @@ -52,6 +52,7 @@ async function main(): Promise { 'eu-west-2', 'eu-west-3', 'eu-north-1', + // 'me-south-1', 'sa-east-1', ]); diff --git a/packages/@aws-cdk/region-info/lib/default.ts b/packages/@aws-cdk/region-info/lib/default.ts index 67a6af3a4233f..80a4a3dd8c0a0 100644 --- a/packages/@aws-cdk/region-info/lib/default.ts +++ b/packages/@aws-cdk/region-info/lib/default.ts @@ -33,19 +33,14 @@ export class Default { case 'states': return `${service}.${region}.amazonaws.com`; - // Services with a universal principal across all regions/partitions - case 'sns': - case 'sqs': - return `${service}.amazonaws.com`; - - // Services with a partitional principal (the default case) - case 'application-autoscaling': - case 'autoscaling': + // Services with a partitional principal case 'ec2': - case 'events': - case 'lambda': - default: return `${service}.${urlSuffix}`; + + // Services with a universal principal across all regions/partitions (the default case) + default: + return `${service}.amazonaws.com`; + } } diff --git a/packages/@aws-cdk/region-info/test/__snapshots__/region-info.test.ts.snap b/packages/@aws-cdk/region-info/test/__snapshots__/region-info.test.ts.snap index 1e9035bb34355..97255f4daaef0 100644 --- a/packages/@aws-cdk/region-info/test/__snapshots__/region-info.test.ts.snap +++ b/packages/@aws-cdk/region-info/test/__snapshots__/region-info.test.ts.snap @@ -2,61 +2,61 @@ exports[`built-in data is correct 1`] = ` Object { - "ap-northeast-1": Object { - "cdkMetadataResourceAvailable": true, + "ap-east-1": Object { + "cdkMetadataResourceAvailable": false, "domainSuffix": "amazonaws.com", "partition": "aws", - "s3StaticWebsiteEndpoint": "s3-website-ap-northeast-1.amazonaws.com", + "s3StaticWebsiteEndpoint": "s3-website.ap-east-1.amazonaws.com", "servicePrincipals": Object { "application-autoscaling": "application-autoscaling.amazonaws.com", "autoscaling": "autoscaling.amazonaws.com", - "codedeploy": "codedeploy.ap-northeast-1.amazonaws.com", + "codedeploy": "codedeploy.ap-east-1.amazonaws.com", "ec2": "ec2.amazonaws.com", "events": "events.amazonaws.com", "lambda": "lambda.amazonaws.com", - "logs": "logs.ap-northeast-1.amazonaws.com", + "logs": "logs.ap-east-1.amazonaws.com", "s3": "s3.amazonaws.com", "sns": "sns.amazonaws.com", "sqs": "sqs.amazonaws.com", - "states": "states.ap-northeast-1.amazonaws.com", + "states": "states.ap-east-1.amazonaws.com", }, }, - "ap-northeast-2": Object { + "ap-northeast-1": Object { "cdkMetadataResourceAvailable": true, "domainSuffix": "amazonaws.com", "partition": "aws", - "s3StaticWebsiteEndpoint": "s3-website.ap-northeast-2.amazonaws.com", + "s3StaticWebsiteEndpoint": "s3-website-ap-northeast-1.amazonaws.com", "servicePrincipals": Object { "application-autoscaling": "application-autoscaling.amazonaws.com", "autoscaling": "autoscaling.amazonaws.com", - "codedeploy": "codedeploy.ap-northeast-2.amazonaws.com", + "codedeploy": "codedeploy.ap-northeast-1.amazonaws.com", "ec2": "ec2.amazonaws.com", "events": "events.amazonaws.com", "lambda": "lambda.amazonaws.com", - "logs": "logs.ap-northeast-2.amazonaws.com", + "logs": "logs.ap-northeast-1.amazonaws.com", "s3": "s3.amazonaws.com", "sns": "sns.amazonaws.com", "sqs": "sqs.amazonaws.com", - "states": "states.ap-northeast-2.amazonaws.com", + "states": "states.ap-northeast-1.amazonaws.com", }, }, - "ap-northeast-3": Object { - "cdkMetadataResourceAvailable": false, + "ap-northeast-2": Object { + "cdkMetadataResourceAvailable": true, "domainSuffix": "amazonaws.com", "partition": "aws", - "s3StaticWebsiteEndpoint": "s3-website.ap-northeast-3.amazonaws.com", + "s3StaticWebsiteEndpoint": "s3-website.ap-northeast-2.amazonaws.com", "servicePrincipals": Object { "application-autoscaling": "application-autoscaling.amazonaws.com", "autoscaling": "autoscaling.amazonaws.com", - "codedeploy": "codedeploy.ap-northeast-3.amazonaws.com", + "codedeploy": "codedeploy.ap-northeast-2.amazonaws.com", "ec2": "ec2.amazonaws.com", "events": "events.amazonaws.com", "lambda": "lambda.amazonaws.com", - "logs": "logs.ap-northeast-3.amazonaws.com", + "logs": "logs.ap-northeast-2.amazonaws.com", "s3": "s3.amazonaws.com", "sns": "sns.amazonaws.com", "sqs": "sqs.amazonaws.com", - "states": "states.ap-northeast-3.amazonaws.com", + "states": "states.ap-northeast-2.amazonaws.com", }, }, "ap-south-1": Object { @@ -141,14 +141,14 @@ Object { "partition": "aws-cn", "s3StaticWebsiteEndpoint": "s3-website.cn-north-1.amazonaws.com.cn", "servicePrincipals": Object { - "application-autoscaling": "application-autoscaling.amazonaws.com.cn", - "autoscaling": "autoscaling.amazonaws.com.cn", + "application-autoscaling": "application-autoscaling.amazonaws.com", + "autoscaling": "autoscaling.amazonaws.com", "codedeploy": "codedeploy.cn-north-1.amazonaws.com.cn", "ec2": "ec2.amazonaws.com.cn", - "events": "events.amazonaws.com.cn", - "lambda": "lambda.amazonaws.com.cn", + "events": "events.amazonaws.com", + "lambda": "lambda.amazonaws.com", "logs": "logs.cn-north-1.amazonaws.com.cn", - "s3": "s3.amazonaws.com.cn", + "s3": "s3.amazonaws.com", "sns": "sns.amazonaws.com", "sqs": "sqs.amazonaws.com", "states": "states.cn-north-1.amazonaws.com", @@ -160,14 +160,14 @@ Object { "partition": "aws-cn", "s3StaticWebsiteEndpoint": "s3-website.cn-northwest-1.amazonaws.com.cn", "servicePrincipals": Object { - "application-autoscaling": "application-autoscaling.amazonaws.com.cn", - "autoscaling": "autoscaling.amazonaws.com.cn", + "application-autoscaling": "application-autoscaling.amazonaws.com", + "autoscaling": "autoscaling.amazonaws.com", "codedeploy": "codedeploy.cn-northwest-1.amazonaws.com.cn", "ec2": "ec2.amazonaws.com.cn", - "events": "events.amazonaws.com.cn", - "lambda": "lambda.amazonaws.com.cn", + "events": "events.amazonaws.com", + "lambda": "lambda.amazonaws.com", "logs": "logs.cn-northwest-1.amazonaws.com.cn", - "s3": "s3.amazonaws.com.cn", + "s3": "s3.amazonaws.com", "sns": "sns.amazonaws.com", "sqs": "sqs.amazonaws.com", "states": "states.cn-northwest-1.amazonaws.com", @@ -268,6 +268,25 @@ Object { "states": "states.eu-west-3.amazonaws.com", }, }, + "me-south-1": Object { + "cdkMetadataResourceAvailable": false, + "domainSuffix": "amazonaws.com", + "partition": "aws", + "s3StaticWebsiteEndpoint": "s3-website.me-south-1.amazonaws.com", + "servicePrincipals": Object { + "application-autoscaling": "application-autoscaling.amazonaws.com", + "autoscaling": "autoscaling.amazonaws.com", + "codedeploy": "codedeploy.me-south-1.amazonaws.com", + "ec2": "ec2.amazonaws.com", + "events": "events.amazonaws.com", + "lambda": "lambda.amazonaws.com", + "logs": "logs.me-south-1.amazonaws.com", + "s3": "s3.amazonaws.com", + "sns": "sns.amazonaws.com", + "sqs": "sqs.amazonaws.com", + "states": "states.me-south-1.amazonaws.com", + }, + }, "sa-east-1": Object { "cdkMetadataResourceAvailable": true, "domainSuffix": "amazonaws.com", diff --git a/packages/@aws-cdk/region-info/test/default.test.ts b/packages/@aws-cdk/region-info/test/default.test.ts index 623620d7a41b6..e1582a1ddbbe6 100644 --- a/packages/@aws-cdk/region-info/test/default.test.ts +++ b/packages/@aws-cdk/region-info/test/default.test.ts @@ -15,17 +15,19 @@ describe('servicePrincipal', () => { expect(Default.servicePrincipal(`${service}${suffix}`, region, urlSuffix)).toBe(`${service}.${region}.${urlSuffix}`); }); } - for (const service of ['sns', 'sqs']) { + + for (const service of ['ec2']) { test(`${service}${suffix}`, () => { - expect(Default.servicePrincipal(`${service}${suffix}`, region, urlSuffix)).toBe(`${service}.amazonaws.com`); + expect(Default.servicePrincipal(`${service}${suffix}`, region, urlSuffix)).toBe(`${service}.${urlSuffix}`); }); } - for (const service of ['application-autoscaling', 'autoscaling', 'ec2', 'events', 'lambda', 'foo-service']) { + for (const service of ['autoscaling', 'lambda', 'events', 'sns', 'sqs', 'foo-service']) { test(`${service}${suffix}`, () => { - expect(Default.servicePrincipal(`${service}${suffix}`, region, urlSuffix)).toBe(`${service}.${urlSuffix}`); + expect(Default.servicePrincipal(`${service}${suffix}`, region, urlSuffix)).toBe(`${service}.amazonaws.com`); }); } + } test('with an "exotic" DNS suffix (.local)', () => { diff --git a/packages/decdk/test/__snapshots__/synth.test.js.snap b/packages/decdk/test/__snapshots__/synth.test.js.snap index dcc38a3a891f6..b4cc48aa5fbe5 100644 --- a/packages/decdk/test/__snapshots__/synth.test.js.snap +++ b/packages/decdk/test/__snapshots__/synth.test.js.snap @@ -384,17 +384,7 @@ Object { "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": Object { - "Service": Object { - "Fn::Join": Array [ - "", - Array [ - "lambda.", - Object { - "Ref": "AWS::URLSuffix", - }, - ], - ], - }, + "Service": "lambda.amazonaws.com", }, }, ], @@ -488,17 +478,7 @@ Object { "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": Object { - "Service": Object { - "Fn::Join": Array [ - "", - Array [ - "apigateway.", - Object { - "Ref": "AWS::URLSuffix", - }, - ], - ], - }, + "Service": "apigateway.amazonaws.com", }, }, ], @@ -648,17 +628,7 @@ Object { "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": Object { - "Service": Object { - "Fn::Join": Array [ - "", - Array [ - "ecs-tasks.", - Object { - "Ref": "AWS::URLSuffix", - }, - ], - ], - }, + "Service": "ecs-tasks.amazonaws.com", }, }, ], @@ -1245,17 +1215,7 @@ Object { "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": Object { - "Service": Object { - "Fn::Join": Array [ - "", - Array [ - "lambda.", - Object { - "Ref": "AWS::URLSuffix", - }, - ], - ], - }, + "Service": "lambda.amazonaws.com", }, }, ], @@ -1370,17 +1330,7 @@ Object { "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": Object { - "Service": Object { - "Fn::Join": Array [ - "", - Array [ - "apigateway.", - Object { - "Ref": "AWS::URLSuffix", - }, - ], - ], - }, + "Service": "apigateway.amazonaws.com", }, }, ], @@ -1623,17 +1573,7 @@ Object { "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": Object { - "Service": Object { - "Fn::Join": Array [ - "", - Array [ - "lambda.", - Object { - "Ref": "AWS::URLSuffix", - }, - ], - ], - }, + "Service": "lambda.amazonaws.com", }, }, ], @@ -1718,17 +1658,7 @@ Object { "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": Object { - "Service": Object { - "Fn::Join": Array [ - "", - Array [ - "codebuild.", - Object { - "Ref": "AWS::URLSuffix", - }, - ], - ], - }, + "Service": "codebuild.amazonaws.com", }, }, ], @@ -2432,17 +2362,7 @@ Object { "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": Object { - "Service": Object { - "Fn::Join": Array [ - "", - Array [ - "cloudformation.", - Object { - "Ref": "AWS::URLSuffix", - }, - ], - ], - }, + "Service": "cloudformation.amazonaws.com", }, }, ], @@ -2480,17 +2400,7 @@ Object { "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": Object { - "Service": Object { - "Fn::Join": Array [ - "", - Array [ - "events.", - Object { - "Ref": "AWS::URLSuffix", - }, - ], - ], - }, + "Service": "events.amazonaws.com", }, }, ], @@ -2550,17 +2460,7 @@ Object { "Action": "sts:AssumeRole", "Effect": "Allow", "Principal": Object { - "Service": Object { - "Fn::Join": Array [ - "", - Array [ - "codepipeline.", - Object { - "Ref": "AWS::URLSuffix", - }, - ], - ], - }, + "Service": "codepipeline.amazonaws.com", }, }, ],