mardi 26 octobre 2021

AWS cloudformation condition for creating a resource

How to use a condition for AWS Child resource type

  • I wanted to create an AWS backupplan with 2 backup rules with a condition (example, if I set create2backup rule as "true", it should create the second one, if the condition is false, it should ignore creating the second rule. I couldn't use the condition there, it thrown error.
    Type: AWS::Backup::BackupPlan
    Properties:
      BackupPlan: 
        BackupPlanName: backupplan
        BackupPlanRule:
          -  
            RuleName: !Ref RuleName   
          - <Some condition>
            RuleName: !Ref RuleName2
            

Aucun commentaire:

Enregistrer un commentaire