Stack

class Stack : KotlinCustomResource

Provides a CloudFormation Stack resource.

Example Usage

package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.cloudformation.Stack;
import com.pulumi.aws.cloudformation.StackArgs;
import static com.pulumi.codegen.internal.Serialization.*;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var network = new Stack("network", StackArgs.builder()
.parameters(Map.of("VPCCidr", "10.0.0.0/16"))
.templateBody(serializeJson(
jsonObject(
jsonProperty("Parameters", jsonObject(
jsonProperty("VPCCidr", jsonObject(
jsonProperty("Type", "String"),
jsonProperty("Default", "10.0.0.0/16"),
jsonProperty("Description", "Enter the CIDR block for the VPC. Default is 10.0.0.0/16.")
))
)),
jsonProperty("Resources", jsonObject(
jsonProperty("myVpc", jsonObject(
jsonProperty("Type", "AWS::EC2::VPC"),
jsonProperty("Properties", jsonObject(
jsonProperty("CidrBlock", jsonObject(
jsonProperty("Ref", "VPCCidr")
)),
jsonProperty("Tags", jsonArray(jsonObject(
jsonProperty("Key", "Name"),
jsonProperty("Value", "Primary_CF_VPC")
)))
))
))
))
)))
.build());
}
}

Import

Cloudformation Stacks can be imported using the name, e.g.,

$ pulumi import aws:cloudformation/stack:Stack stack networking-stack

Properties

Link copied to clipboard
val capabilities: Output<List<String>>?

A list of capabilities. Valid values: CAPABILITY_IAM, CAPABILITY_NAMED_IAM, or CAPABILITY_AUTO_EXPAND

Link copied to clipboard
val disableRollback: Output<Boolean>?

Set to true to disable rollback of the stack if stack creation failed. Conflicts with on_failure.

Link copied to clipboard
val iamRoleArn: Output<String>?

The ARN of an IAM role that AWS CloudFormation assumes to create the stack. If you don't specify a value, AWS CloudFormation uses the role that was previously associated with the stack. If no role is available, AWS CloudFormation uses a temporary session that is generated from your user credentials.

Link copied to clipboard
val id: Output<String>
Link copied to clipboard
val name: Output<String>

Stack name.

Link copied to clipboard

A list of SNS topic ARNs to publish stack related events.

Link copied to clipboard
val onFailure: Output<String>?

Action to be taken if stack creation fails. This must be one of: DO_NOTHING, ROLLBACK, or DELETE. Conflicts with disable_rollback.

Link copied to clipboard
val outputs: Output<Map<String, String>>

A map of outputs from the stack.

Link copied to clipboard
val parameters: Output<Map<String, String>>

A map of Parameter structures that specify input parameters for the stack.

Link copied to clipboard
val policyBody: Output<String>

Structure containing the stack policy body. Conflicts w/ policy_url.

Link copied to clipboard
val policyUrl: Output<String>?

Location of a file containing the stack policy. Conflicts w/ policy_body.

Link copied to clipboard
val pulumiChildResources: Set<KotlinResource>
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
val tags: Output<Map<String, String>>?

Map of resource tags to associate with this stack. .If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level.

Link copied to clipboard
val tagsAll: Output<Map<String, String>>

A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block.

Link copied to clipboard
val templateBody: Output<String>

Structure containing the template body (max size: 51,200 bytes).

Link copied to clipboard
val templateUrl: Output<String>?

Location of a file containing the template body (max size: 460,800 bytes).

Link copied to clipboard
val timeoutInMinutes: Output<Int>?

The amount of time that can pass before the stack status becomes CREATE_FAILED.

Link copied to clipboard
val urn: Output<String>