Skip to content

Commit

Permalink
use definition in case of china or gov regions
Browse files Browse the repository at this point in the history
  • Loading branch information
iakov-aws committed Oct 18, 2024
1 parent c826d1e commit e3cb392
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions cfn-templates/cid-cfn.yml
Original file line number Diff line number Diff line change
Expand Up @@ -283,6 +283,12 @@ Conditions:
- !Condition NeedQuickSightDataSourceRole
- !Condition NeedDataBucketsKms
NeedPermissionsBoundary: !Not [!Equals [ !Ref PermissionsBoundary, "" ]]
IsChinOrGovCloudRegion:
Fn::Or:
- !Equals [!Ref "AWS::Region", "cn-north-1"]
- !Equals [!Ref "AWS::Region", "cn-northwest-1"]
- !Equals [!Ref "AWS::Region", "us-gov-east-1"]
- !Equals [!Ref "AWS::Region", "us-gov-west-1"]

Resources:
SpiceRefreshExecutionRole: #Role needed to schedule spice ingestion for the datasets not used by default
Expand Down Expand Up @@ -1686,6 +1692,7 @@ Resources:
quicksight-user: !Ref QuickSightUser
account-map-source: 'dummy' #initial
share-with-account: !Ref ShareDashboard
resources: !If [IsChinOrGovCloudRegion, 'https://aws-managed-cost-intelligence-dashboards.s3.amazonaws.com/hub/cudos/CUDOS-v5.yaml', !Ref 'AWS::NoValue']
Tags: # Hacky way to manage conditional dependencies
- Key: IgnoreNeedCostIntelligenceDashboard
Value: !If [NeedCostIntelligenceDashboard, !Ref CostIntelligenceDashboard, '']
Expand Down

0 comments on commit e3cb392

Please sign in to comment.