-
Notifications
You must be signed in to change notification settings - Fork 4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #7861 from aws/bump/1.38.0
chore(release): 1.38.0
- Loading branch information
Showing
217 changed files
with
7,779 additions
and
3,644 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,5 +10,5 @@ | |
"tools/*" | ||
], | ||
"rejectCycles": "true", | ||
"version": "1.37.0" | ||
"version": "1.38.0" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 10 additions & 0 deletions
10
packages/@aws-cdk/aws-cloudformation/test/core-custom-resource-provider-fixture/index.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
// tslint:disable: no-console | ||
|
||
export function handler(event: any) { | ||
console.log('I am a custom resource'); | ||
console.log(event); | ||
return { | ||
PhysicalResourceId: event.ResourceProperties.physicalResourceId, | ||
Data: event.ResourceProperties.attributes, | ||
}; | ||
} |
137 changes: 137 additions & 0 deletions
137
packages/@aws-cdk/aws-cloudformation/test/integ.core-custom-resources.expected.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,137 @@ | ||
{ | ||
"Resources": { | ||
"CustomReflectCustomResourceProviderRoleB4B29AEC": { | ||
"Type": "AWS::IAM::Role", | ||
"Properties": { | ||
"AssumeRolePolicyDocument": { | ||
"Version": "2012-10-17", | ||
"Statement": [ | ||
{ | ||
"Action": "sts:AssumeRole", | ||
"Effect": "Allow", | ||
"Principal": { | ||
"Service": "lambda.amazonaws.com" | ||
} | ||
} | ||
] | ||
}, | ||
"ManagedPolicyArns": [ | ||
{ | ||
"Fn::Sub": "arn:${AWS::Partition}:iam::aws:policy/service-role/AWSLambdaBasicExecutionRole" | ||
} | ||
] | ||
} | ||
}, | ||
"CustomReflectCustomResourceProviderHandler2E189D0B": { | ||
"Type": "AWS::Lambda::Function", | ||
"Properties": { | ||
"Code": { | ||
"S3Bucket": { | ||
"Ref": "AssetParametersd46d1ebe2c1958c6352664721f77acb9c78131013956eb82d3d36cf503098e7aS3Bucket1D703CB8" | ||
}, | ||
"S3Key": { | ||
"Fn::Join": [ | ||
"", | ||
[ | ||
{ | ||
"Fn::Select": [ | ||
0, | ||
{ | ||
"Fn::Split": [ | ||
"||", | ||
{ | ||
"Ref": "AssetParametersd46d1ebe2c1958c6352664721f77acb9c78131013956eb82d3d36cf503098e7aS3VersionKey01A97AE3" | ||
} | ||
] | ||
} | ||
] | ||
}, | ||
{ | ||
"Fn::Select": [ | ||
1, | ||
{ | ||
"Fn::Split": [ | ||
"||", | ||
{ | ||
"Ref": "AssetParametersd46d1ebe2c1958c6352664721f77acb9c78131013956eb82d3d36cf503098e7aS3VersionKey01A97AE3" | ||
} | ||
] | ||
} | ||
] | ||
} | ||
] | ||
] | ||
} | ||
}, | ||
"Timeout": 900, | ||
"MemorySize": 128, | ||
"Handler": "__entrypoint__.handler", | ||
"Role": { | ||
"Fn::GetAtt": [ | ||
"CustomReflectCustomResourceProviderRoleB4B29AEC", | ||
"Arn" | ||
] | ||
}, | ||
"Runtime": "nodejs12.x" | ||
}, | ||
"DependsOn": [ | ||
"CustomReflectCustomResourceProviderRoleB4B29AEC" | ||
] | ||
}, | ||
"MyResource": { | ||
"Type": "Custom::Reflect", | ||
"Properties": { | ||
"ServiceToken": { | ||
"Fn::GetAtt": [ | ||
"CustomReflectCustomResourceProviderHandler2E189D0B", | ||
"Arn" | ||
] | ||
}, | ||
"physicalResourceId": "MyPhysicalReflectBack", | ||
"attributes": { | ||
"Attribute1": "foo", | ||
"Attribute2": 1234 | ||
} | ||
}, | ||
"UpdateReplacePolicy": "Delete", | ||
"DeletionPolicy": "Delete" | ||
} | ||
}, | ||
"Parameters": { | ||
"AssetParametersd46d1ebe2c1958c6352664721f77acb9c78131013956eb82d3d36cf503098e7aS3Bucket1D703CB8": { | ||
"Type": "String", | ||
"Description": "S3 bucket for asset \"d46d1ebe2c1958c6352664721f77acb9c78131013956eb82d3d36cf503098e7a\"" | ||
}, | ||
"AssetParametersd46d1ebe2c1958c6352664721f77acb9c78131013956eb82d3d36cf503098e7aS3VersionKey01A97AE3": { | ||
"Type": "String", | ||
"Description": "S3 key for asset version \"d46d1ebe2c1958c6352664721f77acb9c78131013956eb82d3d36cf503098e7a\"" | ||
}, | ||
"AssetParametersd46d1ebe2c1958c6352664721f77acb9c78131013956eb82d3d36cf503098e7aArtifactHash16A571C9": { | ||
"Type": "String", | ||
"Description": "Artifact hash for asset \"d46d1ebe2c1958c6352664721f77acb9c78131013956eb82d3d36cf503098e7a\"" | ||
} | ||
}, | ||
"Outputs": { | ||
"Ref": { | ||
"Value": { | ||
"Ref": "MyResource" | ||
} | ||
}, | ||
"GetAttAttribute1": { | ||
"Value": { | ||
"Fn::GetAtt": [ | ||
"MyResource", | ||
"Attribute1" | ||
] | ||
} | ||
}, | ||
"GetAttAttribute2": { | ||
"Value": { | ||
"Fn::GetAtt": [ | ||
"MyResource", | ||
"Attribute2" | ||
] | ||
} | ||
} | ||
} | ||
} |
42 changes: 42 additions & 0 deletions
42
packages/@aws-cdk/aws-cloudformation/test/integ.core-custom-resources.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
/* | ||
* Stack verification steps: | ||
* - Deploy with `--no-clean` | ||
* - Verify that the CloudFormation stack outputs have the following values: | ||
* - Ref: "MyPhysicalReflectBack" | ||
* - GetAtt.Attribute1: "foo" | ||
* - GetAtt.Attribute2: 1234 | ||
*/ | ||
import { App, CfnOutput, Construct, CustomResource, CustomResourceProvider, CustomResourceProviderRuntime, Stack, Token } from '@aws-cdk/core'; | ||
|
||
class TestStack extends Stack { | ||
constructor(scope: Construct, id: string) { | ||
super(scope, id); | ||
|
||
const resourceType = 'Custom::Reflect'; | ||
|
||
const serviceToken = CustomResourceProvider.getOrCreate(this, resourceType, { | ||
codeDirectory: `${__dirname}/core-custom-resource-provider-fixture`, | ||
runtime: CustomResourceProviderRuntime.NODEJS_12, | ||
}); | ||
|
||
const cr = new CustomResource(this, 'MyResource', { | ||
resourceType, | ||
serviceToken, | ||
properties: { | ||
physicalResourceId: 'MyPhysicalReflectBack', | ||
attributes: { | ||
Attribute1: 'foo', | ||
Attribute2: 1234, | ||
}, | ||
}, | ||
}); | ||
|
||
new CfnOutput(this, 'Ref', { value: cr.ref }); | ||
new CfnOutput(this, 'GetAtt.Attribute1', { value: Token.asString(cr.getAtt('Attribute1')) }); | ||
new CfnOutput(this, 'GetAtt.Attribute2', { value: Token.asString(cr.getAtt('Attribute2')) }); | ||
} | ||
} | ||
|
||
const app = new App(); | ||
new TestStack(app, 'custom-resource-test'); | ||
app.synth(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.