Files
opentf/website/source/docs/providers/aws/d/cloudformation_stack.html.markdown
George Christou 61277c0dbd website/docs: Run terraform fmt on code examples (#12075)
* docs/vsphere: Fix code block

* docs: Convert `...` to `# ...` to allow `terraform fmt`ing

* docs: Trim trailing whitespace

* docs: First-pass run of `terraform fmt` on code examples
2017-02-19 00:48:50 +02:00

1.4 KiB

layout, page_title, sidebar_current, description
layout page_title sidebar_current description
aws AWS: aws_cloudformation_stack docs-aws-datasource-cloudformation-stack Provides metadata of a CloudFormation stack (e.g. outputs)

aws_cloudformation_stack

The CloudFormation Stack data source allows access to stack outputs and other useful data including the template body.

Example Usage

data "aws_cloudformation_stack" "network" {
  name = "my-network-stack"
}

resource "aws_instance" "web" {
  ami           = "ami-abb07bcb"
  instance_type = "t1.micro"
  subnet_id     = "${data.aws_cloudformation_stack.network.outputs["SubnetId"]}"

  tags {
    Name = "HelloWorld"
  }
}

Argument Reference

The following arguments are supported:

  • name - (Required) The name of the stack

Attributes Reference

The following attributes are exported:

  • capabilities - A list of capabilities
  • description - Description of the stack
  • disable_rollback - Whether the rollback of the stack is disabled when stack creation fails
  • notification_arns - A list of SNS topic ARNs to publish stack related events
  • outputs - A map of outputs from the stack.
  • parameters - A map of parameters that specify input parameters for the stack.
  • tags - A map of tags associated with this stack.
  • template_body - Structure containing the template body.
  • timeout_in_minutes - The amount of time that can pass before the stack status becomes CREATE_FAILED