forked from aws/aws-cdk
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(servicecatalogappregistry): allow disabling automatic CfnOutput (a…
…ws#24483) When an application is created using `Application` construct, an output is automatically created in the customer defined stack without customer's intention to show related Application Manager URL for the application created. This can increase customer's CFN output usage without customer acknowledge and control. This commit: - emits the CFN Output in the AppRegistry managed stack where the application is created to allow all the stacks deployed in the cdk project to be associated to the application. Customers can control whether to emit the URL as CFN output by setting `emitApplicationManagerUrlAsOutput`. - changes `applicationManagerUrl` to a string type. Customers can create further create CFN output from this property. Closes aws#23779 BREAKING CHANGE: This commit contains destructive changes to the RAM Share. Since the application RAM share name is calculated by the application construct, where one property is removed. Integration test detects a breaking change where RAM share will be created. Integration test snapshot is updated to cater this destructive change. ---- *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
- Loading branch information
1 parent
2a82fc9
commit 0d8608b
Showing
22 changed files
with
944 additions
and
56 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
20 changes: 20 additions & 0 deletions
20
...n-associator.disable-url.js.snapshot/ApplicationAssociator-d50dd3259875-Stack.assets.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,20 @@ | ||
{ | ||
"version": "30.1.0", | ||
"files": { | ||
"2669d20378c55153134983ffc6c70d7d39f75ab888356d2fbf04e21c11531590": { | ||
"source": { | ||
"path": "ApplicationAssociator-d50dd3259875-Stack.template.json", | ||
"packaging": "file" | ||
}, | ||
"destinations": { | ||
"828800149827-us-east-2": { | ||
"bucketName": "cdk-hnb659fds-assets-828800149827-us-east-2", | ||
"objectKey": "2669d20378c55153134983ffc6c70d7d39f75ab888356d2fbf04e21c11531590.json", | ||
"region": "us-east-2", | ||
"assumeRoleArn": "arn:${AWS::Partition}:iam::828800149827:role/cdk-hnb659fds-file-publishing-role-828800149827-us-east-2" | ||
} | ||
} | ||
} | ||
}, | ||
"dockerImages": {} | ||
} |
64 changes: 64 additions & 0 deletions
64
...associator.disable-url.js.snapshot/ApplicationAssociator-d50dd3259875-Stack.template.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,64 @@ | ||
{ | ||
"Description": "Stack to create AppRegistry application", | ||
"Resources": { | ||
"DefaultCdkApplication4573D5A3": { | ||
"Type": "AWS::ServiceCatalogAppRegistry::Application", | ||
"Properties": { | ||
"Name": "AppRegistryAssociatedApplication", | ||
"Description": "Application containing stacks deployed via CDK.", | ||
"Tags": { | ||
"managedBy": "CDK_Application_Associator" | ||
} | ||
} | ||
}, | ||
"AppRegistryAssociation": { | ||
"Type": "AWS::ServiceCatalogAppRegistry::ResourceAssociation", | ||
"Properties": { | ||
"Application": { | ||
"Fn::GetAtt": [ | ||
"DefaultCdkApplication4573D5A3", | ||
"Id" | ||
] | ||
}, | ||
"Resource": { | ||
"Ref": "AWS::StackId" | ||
}, | ||
"ResourceType": "CFN_STACK" | ||
} | ||
} | ||
}, | ||
"Parameters": { | ||
"BootstrapVersion": { | ||
"Type": "AWS::SSM::Parameter::Value<String>", | ||
"Default": "/cdk-bootstrap/hnb659fds/version", | ||
"Description": "Version of the CDK Bootstrap resources in this environment, automatically retrieved from SSM Parameter Store. [cdk:skip]" | ||
} | ||
}, | ||
"Rules": { | ||
"CheckBootstrapVersion": { | ||
"Assertions": [ | ||
{ | ||
"Assert": { | ||
"Fn::Not": [ | ||
{ | ||
"Fn::Contains": [ | ||
[ | ||
"1", | ||
"2", | ||
"3", | ||
"4", | ||
"5" | ||
], | ||
{ | ||
"Ref": "BootstrapVersion" | ||
} | ||
] | ||
} | ||
] | ||
}, | ||
"AssertDescription": "CDK bootstrap stack version 6 required. Please run 'cdk bootstrap' with a recent version of the CDK CLI." | ||
} | ||
] | ||
} | ||
} | ||
} |
19 changes: 19 additions & 0 deletions
19
...able-url.js.snapshot/ApplicationAssociatorTestDefaultTestDeployAssert2A5F2DB9.assets.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,19 @@ | ||
{ | ||
"version": "30.1.0", | ||
"files": { | ||
"19dd33f3c17e59cafd22b9459b0a8d9bedbd42252737fedb06b2bcdbcf7809cc": { | ||
"source": { | ||
"path": "ApplicationAssociatorTestDefaultTestDeployAssert2A5F2DB9.template.json", | ||
"packaging": "file" | ||
}, | ||
"destinations": { | ||
"current_account-current_region": { | ||
"bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", | ||
"objectKey": "19dd33f3c17e59cafd22b9459b0a8d9bedbd42252737fedb06b2bcdbcf7809cc.json", | ||
"assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" | ||
} | ||
} | ||
} | ||
}, | ||
"dockerImages": {} | ||
} |
48 changes: 48 additions & 0 deletions
48
...le-url.js.snapshot/ApplicationAssociatorTestDefaultTestDeployAssert2A5F2DB9.template.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,48 @@ | ||
{ | ||
"Resources": { | ||
"AppRegistryAssociation": { | ||
"Type": "AWS::ServiceCatalogAppRegistry::ResourceAssociation", | ||
"Properties": { | ||
"Application": "AppRegistryAssociatedApplication", | ||
"Resource": { | ||
"Ref": "AWS::StackId" | ||
}, | ||
"ResourceType": "CFN_STACK" | ||
} | ||
} | ||
}, | ||
"Parameters": { | ||
"BootstrapVersion": { | ||
"Type": "AWS::SSM::Parameter::Value<String>", | ||
"Default": "/cdk-bootstrap/hnb659fds/version", | ||
"Description": "Version of the CDK Bootstrap resources in this environment, automatically retrieved from SSM Parameter Store. [cdk:skip]" | ||
} | ||
}, | ||
"Rules": { | ||
"CheckBootstrapVersion": { | ||
"Assertions": [ | ||
{ | ||
"Assert": { | ||
"Fn::Not": [ | ||
{ | ||
"Fn::Contains": [ | ||
[ | ||
"1", | ||
"2", | ||
"3", | ||
"4", | ||
"5" | ||
], | ||
{ | ||
"Ref": "BootstrapVersion" | ||
} | ||
] | ||
} | ||
] | ||
}, | ||
"AssertDescription": "CDK bootstrap stack version 6 required. Please run 'cdk bootstrap' with a recent version of the CDK CLI." | ||
} | ||
] | ||
} | ||
} | ||
} |
1 change: 1 addition & 0 deletions
1
...rvicecatalogappregistry/test/integ.application-associator.disable-url.js.snapshot/cdk.out
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 @@ | ||
{"version":"30.1.0"} |
Oops, something went wrong.