Ref

The ref method is the CloudFormation Ref equivalent.

Example Snippet

resource(:my_eip, "AWS::EC2::EIP",
  instance_id: ref(:my_ec2_instance)
)

Example Output

Resources:
  MyEip:
    Type: AWS::EC2::EIP
    Properties:
      InstanceId:
        Ref: MyEc2Instance

Back to Intrinsic Functions List.

Pro tip: Use the <- and -> arrow keys to move back and forward.

Edit this page

See a typo or an error? You can improve this page. This website is available on GitHub and contributions are encouraged and welcomed. We love pull requests from you!