!Rain::Include¶
!Rain::Include <path> reads a YAML or JSON file and inserts it into the template as an object. cfnrain also processes the directives in the included file. Paths in the included file are relative to that file.
Use it to share tags, policies, or whole resource definitions between templates.
Example¶
The template:
tags.yaml, in the same directory:
The packaged template:
Resources:
Bucket:
Type: AWS::S3::Bucket
Properties:
Tags:
- Key: Team
Value: platform
- Key: CostCenter
Value: "1234"
Related¶
!Rain::Embedinserts a file as a string.- Modules insert a group of resources, with parameters and outputs.