From e3cb3926b6467050e60b5a4828ce94615b23ab27 Mon Sep 17 00:00:00 2001 From: Iakov Gan Date: Fri, 18 Oct 2024 09:51:39 +0200 Subject: [PATCH] use definition in case of china or gov regions --- cfn-templates/cid-cfn.yml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/cfn-templates/cid-cfn.yml b/cfn-templates/cid-cfn.yml index d6543b27..742d2fab 100644 --- a/cfn-templates/cid-cfn.yml +++ b/cfn-templates/cid-cfn.yml @@ -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 @@ -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, '']