Skip to content

Client

cloudformation R Documentation

AWS CloudFormation

Description

CloudFormation

CloudFormation allows you to create and manage Amazon Web Services infrastructure deployments predictably and repeatedly. You can use CloudFormation to leverage Amazon Web Services products, such as Amazon Elastic Compute Cloud, Amazon Elastic Block Store, Amazon Simple Notification Service, Elastic Load Balancing, and Auto Scaling to build highly reliable, highly scalable, cost-effective applications without creating or configuring the underlying Amazon Web Services infrastructure.

With CloudFormation, you declare all your resources and dependencies in a template file. The template defines a collection of resources as a single unit called a stack. CloudFormation creates and deletes all member resources of the stack together and manages all dependencies between the resources for you.

For more information about CloudFormation, see the CloudFormation product page.

CloudFormation makes use of other Amazon Web Services products. If you need additional technical information about a specific Amazon Web Services product, you can find the product's technical documentation at docs.aws.amazon.com.

Usage

cloudformation(
  config = list(),
  credentials = list(),
  endpoint = NULL,
  region = NULL
)

Arguments

config

Optional configuration of credentials, endpoint, and/or region.

  • credentials:

    • creds:

      • access_key_id: AWS access key ID

      • secret_access_key: AWS secret access key

      • session_token: AWS temporary session token

    • profile: The name of a profile to use. If not given, then the default profile is used.

    • anonymous: Set anonymous credentials.

  • endpoint: The complete URL to use for the constructed client.

  • region: The AWS Region used in instantiating the client.

  • close_connection: Immediately close all HTTP connections.

  • timeout: The time in seconds till a timeout exception is thrown when attempting to make a connection. The default is 60 seconds.

  • s3_force_path_style: Set this to true to force the request to use path-style addressing, i.e. ⁠http://s3.amazonaws.com/BUCKET/KEY⁠.

  • sts_regional_endpoint: Set sts regional endpoint resolver to regional or legacy https://docs.aws.amazon.com/sdkref/latest/guide/feature-sts-regionalized-endpoints.html

credentials

Optional credentials shorthand for the config parameter

  • creds:

    • access_key_id: AWS access key ID

    • secret_access_key: AWS secret access key

    • session_token: AWS temporary session token

  • profile: The name of a profile to use. If not given, then the default profile is used.

  • anonymous: Set anonymous credentials.

endpoint

Optional shorthand for complete URL to use for the constructed client.

region

Optional shorthand for AWS Region used in instantiating the client.

Value

A client for the service. You can call the service's operations using syntax like svc$operation(...), where svc is the name you've assigned to the client. The available operations are listed in the Operations section.

Service syntax

svc <- cloudformation(
  config = list(
    credentials = list(
      creds = list(
        access_key_id = "string",
        secret_access_key = "string",
        session_token = "string"
      ),
      profile = "string",
      anonymous = "logical"
    ),
    endpoint = "string",
    region = "string",
    close_connection = "logical",
    timeout = "numeric",
    s3_force_path_style = "logical",
    sts_regional_endpoint = "string"
  ),
  credentials = list(
    creds = list(
      access_key_id = "string",
      secret_access_key = "string",
      session_token = "string"
    ),
    profile = "string",
    anonymous = "logical"
  ),
  endpoint = "string",
  region = "string"
)

Operations

activate_organizations_access
Activate trusted access with Organizations
activate_type
Activates a public third-party extension, making it available for use in stack templates
batch_describe_type_configurations
Returns configuration data for the specified CloudFormation extensions, from the CloudFormation registry for the account and Region
cancel_update_stack
Cancels an update on the specified stack
continue_update_rollback
For a specified stack that's in the UPDATE_ROLLBACK_FAILED state, continues rolling it back to the UPDATE_ROLLBACK_COMPLETE state
create_change_set
Creates a list of changes that will be applied to a stack so that you can review the changes before executing them
create_generated_template
Creates a template from existing resources that are not already managed with CloudFormation
create_stack
Creates a stack as specified in the template
create_stack_instances
Creates stack instances for the specified accounts, within the specified Amazon Web Services Regions
create_stack_set
Creates a stack set
deactivate_organizations_access
Deactivates trusted access with Organizations
deactivate_type
Deactivates a public extension that was previously activated in this account and Region
delete_change_set
Deletes the specified change set
delete_generated_template
Deleted a generated template
delete_stack
Deletes a specified stack
delete_stack_instances
Deletes stack instances for the specified accounts, in the specified Amazon Web Services Regions
delete_stack_set
Deletes a stack set
deregister_type
Marks an extension or extension version as DEPRECATED in the CloudFormation registry, removing it from active use
describe_account_limits
Retrieves your account's CloudFormation limits, such as the maximum number of stacks that you can create in your account
describe_change_set
Returns the inputs for the change set and a list of changes that CloudFormation will make if you execute the change set
describe_change_set_hooks
Returns hook-related information for the change set and a list of changes that CloudFormation makes when you run the change set
describe_generated_template
Describes a generated template
describe_organizations_access
Retrieves information about the account's OrganizationAccess status
describe_publisher
Returns information about a CloudFormation extension publisher
describe_resource_scan
Describes details of a resource scan
describe_stack_drift_detection_status
Returns information about a stack drift detection operation
describe_stack_events
Returns all stack related events for a specified stack in reverse chronological order
describe_stack_instance
Returns the stack instance that's associated with the specified StackSet, Amazon Web Services account, and Amazon Web Services Region
describe_stack_resource
Returns a description of the specified resource in the specified stack
describe_stack_resource_drifts
Returns drift information for the resources that have been checked for drift in the specified stack
describe_stack_resources
Returns Amazon Web Services resource descriptions for running and deleted stacks
describe_stacks
Returns the description for the specified stack; if no stack name was specified, then it returns the description for all the stacks created
describe_stack_set
Returns the description of the specified StackSet
describe_stack_set_operation
Returns the description of the specified StackSet operation
describe_type
Returns detailed information about an extension that has been registered
describe_type_registration
Returns information about an extension's registration, including its current status and type and version identifiers
detect_stack_drift
Detects whether a stack's actual configuration differs, or has drifted, from its expected configuration, as defined in the stack template and any values specified as template parameters
detect_stack_resource_drift
Returns information about whether a resource's actual configuration differs, or has drifted, from its expected configuration, as defined in the stack template and any values specified as template parameters
detect_stack_set_drift
Detect drift on a stack set
estimate_template_cost
Returns the estimated monthly cost of a template
execute_change_set
Updates a stack using the input information that was provided when the specified change set was created
get_generated_template
Retrieves a generated template
get_stack_policy
Returns the stack policy for a specified stack
get_template
Returns the template body for a specified stack
get_template_summary
Returns information about a new or existing template
import_stacks_to_stack_set
Import existing stacks into a new stack sets
list_change_sets
Returns the ID and status of each active change set for a stack
list_exports
Lists all exported output values in the account and Region in which you call this action
list_generated_templates
Lists your generated templates in this Region
list_imports
Lists all stacks that are importing an exported output value
list_resource_scan_related_resources
Lists the related resources for a list of resources from a resource scan
list_resource_scan_resources
Lists the resources from a resource scan
list_resource_scans
List the resource scans from newest to oldest
list_stack_instance_resource_drifts
Returns drift information for resources in a stack instance
list_stack_instances
Returns summary information about stack instances that are associated with the specified stack set
list_stack_resources
Returns descriptions of all resources of the specified stack
list_stacks
Returns the summary information for stacks whose status matches the specified StackStatusFilter
list_stack_set_auto_deployment_targets
Returns summary information about deployment targets for a stack set
list_stack_set_operation_results
Returns summary information about the results of a stack set operation
list_stack_set_operations
Returns summary information about operations performed on a stack set
list_stack_sets
Returns summary information about stack sets that are associated with the user
list_type_registrations
Returns a list of registration tokens for the specified extension(s)
list_types
Returns summary information about extension that have been registered with CloudFormation
list_type_versions
Returns summary information about the versions of an extension
publish_type
Publishes the specified extension to the CloudFormation registry as a public extension in this Region
record_handler_progress
Reports progress of a resource handler to CloudFormation
register_publisher
Registers your account as a publisher of public extensions in the CloudFormation registry
register_type
Registers an extension with the CloudFormation service
rollback_stack
When specifying RollbackStack, you preserve the state of previously provisioned resources when an operation fails
set_stack_policy
Sets a stack policy for a specified stack
set_type_configuration
Specifies the configuration data for a registered CloudFormation extension, in the given account and Region
set_type_default_version
Specify the default version of an extension
signal_resource
Sends a signal to the specified resource with a success or failure status
start_resource_scan
Starts a scan of the resources in this account in this Region
stop_stack_set_operation
Stops an in-progress operation on a stack set and its associated stack instances
test_type
Tests a registered extension to make sure it meets all necessary requirements for being published in the CloudFormation registry
update_generated_template
Updates a generated template
update_stack
Updates a stack as specified in the template
update_stack_instances
Updates the parameter values for stack instances for the specified accounts, within the specified Amazon Web Services Regions
update_stack_set
Updates the stack set, and associated stack instances in the specified accounts and Amazon Web Services Regions
update_termination_protection
Updates termination protection for the specified stack
validate_template
Validates a specified template

Examples

## Not run: 
svc <- cloudformation()
# This example creates a generated template with a resources file.
svc$create_generated_template(
  GeneratedTemplateName = "JazzyTemplate",
  Resources = list(
    list(
      ResourceIdentifier = list(
        BucketName = "jazz-bucket"
      ),
      ResourceType = "AWS::S3::Bucket"
    ),
    list(
      ResourceIdentifier = list(
        DhcpOptionsId = "random-id123"
      ),
      ResourceType = "AWS::EC2::DHCPOptions"
    )
  )
)

## End(Not run)