AWS Classic

Pulumi Official
Package maintained by Pulumi
v5.4.0 published on Wednesday, May 4, 2022 by Pulumi

Association

Associates an SSM Document to an instance or EC2 tag.

Example Usage

Create an association for a specific instance

using Pulumi;
using Aws = Pulumi.Aws;

class MyStack : Stack
{
    public MyStack()
    {
        var example = new Aws.Ssm.Association("example", new Aws.Ssm.AssociationArgs
        {
            Targets = 
            {
                new Aws.Ssm.Inputs.AssociationTargetArgs
                {
                    Key = "InstanceIds",
                    Values = 
                    {
                        aws_instance.Example.Id,
                    },
                },
            },
        });
    }

}
package main

import (
	"github.com/pulumi/pulumi-aws/sdk/v5/go/aws/ssm"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := ssm.NewAssociation(ctx, "example", &ssm.AssociationArgs{
			Targets: ssm.AssociationTargetArray{
				&ssm.AssociationTargetArgs{
					Key: pulumi.String("InstanceIds"),
					Values: pulumi.StringArray{
						pulumi.Any(aws_instance.Example.Id),
					},
				},
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}
package generated_program;

import java.util.*;
import java.io.*;
import java.nio.*;
import com.pulumi.*;

public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }

    public static void stack(Context ctx) {
        var example = new Association("example", AssociationArgs.builder()        
            .targets(AssociationTarget.builder()
                .key("InstanceIds")
                .values(aws_instance.getExample().getId())
                .build())
            .build());

        }
}
import pulumi
import pulumi_aws as aws

example = aws.ssm.Association("example", targets=[aws.ssm.AssociationTargetArgs(
    key="InstanceIds",
    values=[aws_instance["example"]["id"]],
)])
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";

const example = new aws.ssm.Association("example", {targets: [{
    key: "InstanceIds",
    values: [aws_instance.example.id],
}]});
resources:
  example:
    type: aws:ssm:Association
    properties:
      targets:
        - key: InstanceIds
          values:
            - ${aws_instance.example.id}

Create an association for all managed instances in an AWS account

using Pulumi;
using Aws = Pulumi.Aws;

class MyStack : Stack
{
    public MyStack()
    {
        var example = new Aws.Ssm.Association("example", new Aws.Ssm.AssociationArgs
        {
            Targets = 
            {
                new Aws.Ssm.Inputs.AssociationTargetArgs
                {
                    Key = "InstanceIds",
                    Values = 
                    {
                        "*",
                    },
                },
            },
        });
    }

}
package main

import (
	"github.com/pulumi/pulumi-aws/sdk/v5/go/aws/ssm"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := ssm.NewAssociation(ctx, "example", &ssm.AssociationArgs{
			Targets: ssm.AssociationTargetArray{
				&ssm.AssociationTargetArgs{
					Key: pulumi.String("InstanceIds"),
					Values: pulumi.StringArray{
						pulumi.String("*"),
					},
				},
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}
package generated_program;

import java.util.*;
import java.io.*;
import java.nio.*;
import com.pulumi.*;

public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }

    public static void stack(Context ctx) {
        var example = new Association("example", AssociationArgs.builder()        
            .targets(AssociationTarget.builder()
                .key("InstanceIds")
                .values("*")
                .build())
            .build());

        }
}
import pulumi
import pulumi_aws as aws

example = aws.ssm.Association("example", targets=[aws.ssm.AssociationTargetArgs(
    key="InstanceIds",
    values=["*"],
)])
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";

const example = new aws.ssm.Association("example", {
    targets: [{
        key: "InstanceIds",
        values: ["*"],
    }],
});
resources:
  example:
    type: aws:ssm:Association
    properties:
      targets:
        - key: InstanceIds
          values:
            - '*'

Create an association for a specific tag

using Pulumi;
using Aws = Pulumi.Aws;

class MyStack : Stack
{
    public MyStack()
    {
        var example = new Aws.Ssm.Association("example", new Aws.Ssm.AssociationArgs
        {
            Targets = 
            {
                new Aws.Ssm.Inputs.AssociationTargetArgs
                {
                    Key = "tag:Environment",
                    Values = 
                    {
                        "Development",
                    },
                },
            },
        });
    }

}
package main

import (
	"github.com/pulumi/pulumi-aws/sdk/v5/go/aws/ssm"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := ssm.NewAssociation(ctx, "example", &ssm.AssociationArgs{
			Targets: ssm.AssociationTargetArray{
				&ssm.AssociationTargetArgs{
					Key: pulumi.String("tag:Environment"),
					Values: pulumi.StringArray{
						pulumi.String("Development"),
					},
				},
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}
package generated_program;

import java.util.*;
import java.io.*;
import java.nio.*;
import com.pulumi.*;

public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }

    public static void stack(Context ctx) {
        var example = new Association("example", AssociationArgs.builder()        
            .targets(AssociationTarget.builder()
                .key("tag:Environment")
                .values("Development")
                .build())
            .build());

        }
}
import pulumi
import pulumi_aws as aws

example = aws.ssm.Association("example", targets=[aws.ssm.AssociationTargetArgs(
    key="tag:Environment",
    values=["Development"],
)])
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";

const example = new aws.ssm.Association("example", {
    targets: [{
        key: "tag:Environment",
        values: ["Development"],
    }],
});
resources:
  example:
    type: aws:ssm:Association
    properties:
      targets:
        - key: tag:Environment
          values:
            - Development

Create a Association Resource

new Association(name: string, args?: AssociationArgs, opts?: CustomResourceOptions);
@overload
def Association(resource_name: str,
                opts: Optional[ResourceOptions] = None,
                apply_only_at_cron_interval: Optional[bool] = None,
                association_name: Optional[str] = None,
                automation_target_parameter_name: Optional[str] = None,
                compliance_severity: Optional[str] = None,
                document_version: Optional[str] = None,
                instance_id: Optional[str] = None,
                max_concurrency: Optional[str] = None,
                max_errors: Optional[str] = None,
                name: Optional[str] = None,
                output_location: Optional[AssociationOutputLocationArgs] = None,
                parameters: Optional[Mapping[str, str]] = None,
                schedule_expression: Optional[str] = None,
                targets: Optional[Sequence[AssociationTargetArgs]] = None,
                wait_for_success_timeout_seconds: Optional[int] = None)
@overload
def Association(resource_name: str,
                args: Optional[AssociationArgs] = None,
                opts: Optional[ResourceOptions] = None)
func NewAssociation(ctx *Context, name string, args *AssociationArgs, opts ...ResourceOption) (*Association, error)
public Association(string name, AssociationArgs? args = null, CustomResourceOptions? opts = null)
public Association(String name, AssociationArgs args)
public Association(String name, AssociationArgs args, CustomResourceOptions options)
type: aws:ssm:Association
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

name string
The unique name of the resource.
args AssociationArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name str
The unique name of the resource.
args AssociationArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name string
The unique name of the resource.
args AssociationArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name string
The unique name of the resource.
args AssociationArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name String
The unique name of the resource.
args AssociationArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

Association Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

Inputs

The Association resource accepts the following input properties:

ApplyOnlyAtCronInterval bool

By default, when you create a new or update associations, the system runs it immediately and then according to the schedule you specified. Enable this option if you do not want an association to run immediately after you create or update it. This parameter is not supported for rate expressions. Default: false.

AssociationName string

The descriptive name for the association.

AutomationTargetParameterName string

Specify the target for the association. This target is required for associations that use an Automation document and target resources by using rate controls. This should be set to the SSM document parameter that will define how your automation will branch out.

ComplianceSeverity string

The compliance severity for the association. Can be one of the following: UNSPECIFIED, LOW, MEDIUM, HIGH or CRITICAL

DocumentVersion string

The document version you want to associate with the target(s). Can be a specific version or the default version.

InstanceId string

The instance ID to apply an SSM document to. Use targets with key InstanceIds for document schema versions 2.0 and above.

Deprecated:

use 'targets' argument instead. https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_CreateAssociation.html#systemsmanager-CreateAssociation-request-InstanceId

MaxConcurrency string

The maximum number of targets allowed to run the association at the same time. You can specify a number, for example 10, or a percentage of the target set, for example 10%.

MaxErrors string

The number of errors that are allowed before the system stops sending requests to run the association on additional targets. You can specify a number, for example 10, or a percentage of the target set, for example 10%.

Name string

The name of the SSM document to apply.

OutputLocation Pulumi.Aws.Ssm.Inputs.AssociationOutputLocationArgs

An output location block. Output Location is documented below.

Parameters Dictionary<string, string>

A block of arbitrary string parameters to pass to the SSM document.

ScheduleExpression string

A cron expression when the association will be applied to the target(s).

Targets List<Pulumi.Aws.Ssm.Inputs.AssociationTargetArgs>

A block containing the targets of the SSM association. Targets are documented below. AWS currently supports a maximum of 5 targets.

WaitForSuccessTimeoutSeconds int

The number of seconds to wait for the association status to be Success. If Success status is not reached within the given time, create opration will fail.

ApplyOnlyAtCronInterval bool

By default, when you create a new or update associations, the system runs it immediately and then according to the schedule you specified. Enable this option if you do not want an association to run immediately after you create or update it. This parameter is not supported for rate expressions. Default: false.

AssociationName string

The descriptive name for the association.

AutomationTargetParameterName string

Specify the target for the association. This target is required for associations that use an Automation document and target resources by using rate controls. This should be set to the SSM document parameter that will define how your automation will branch out.

ComplianceSeverity string

The compliance severity for the association. Can be one of the following: UNSPECIFIED, LOW, MEDIUM, HIGH or CRITICAL

DocumentVersion string

The document version you want to associate with the target(s). Can be a specific version or the default version.

InstanceId string

The instance ID to apply an SSM document to. Use targets with key InstanceIds for document schema versions 2.0 and above.

Deprecated:

use 'targets' argument instead. https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_CreateAssociation.html#systemsmanager-CreateAssociation-request-InstanceId

MaxConcurrency string

The maximum number of targets allowed to run the association at the same time. You can specify a number, for example 10, or a percentage of the target set, for example 10%.

MaxErrors string

The number of errors that are allowed before the system stops sending requests to run the association on additional targets. You can specify a number, for example 10, or a percentage of the target set, for example 10%.

Name string

The name of the SSM document to apply.

OutputLocation AssociationOutputLocationArgs

An output location block. Output Location is documented below.

Parameters map[string]string

A block of arbitrary string parameters to pass to the SSM document.

ScheduleExpression string

A cron expression when the association will be applied to the target(s).

Targets []AssociationTargetArgs

A block containing the targets of the SSM association. Targets are documented below. AWS currently supports a maximum of 5 targets.

WaitForSuccessTimeoutSeconds int

The number of seconds to wait for the association status to be Success. If Success status is not reached within the given time, create opration will fail.

applyOnlyAtCronInterval Boolean

By default, when you create a new or update associations, the system runs it immediately and then according to the schedule you specified. Enable this option if you do not want an association to run immediately after you create or update it. This parameter is not supported for rate expressions. Default: false.

associationName String

The descriptive name for the association.

automationTargetParameterName String

Specify the target for the association. This target is required for associations that use an Automation document and target resources by using rate controls. This should be set to the SSM document parameter that will define how your automation will branch out.

complianceSeverity String

The compliance severity for the association. Can be one of the following: UNSPECIFIED, LOW, MEDIUM, HIGH or CRITICAL

documentVersion String

The document version you want to associate with the target(s). Can be a specific version or the default version.

instanceId String

The instance ID to apply an SSM document to. Use targets with key InstanceIds for document schema versions 2.0 and above.

Deprecated:

use 'targets' argument instead. https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_CreateAssociation.html#systemsmanager-CreateAssociation-request-InstanceId

maxConcurrency String

The maximum number of targets allowed to run the association at the same time. You can specify a number, for example 10, or a percentage of the target set, for example 10%.

maxErrors String

The number of errors that are allowed before the system stops sending requests to run the association on additional targets. You can specify a number, for example 10, or a percentage of the target set, for example 10%.

name String

The name of the SSM document to apply.

outputLocation AssociationOutputLocationArgs

An output location block. Output Location is documented below.

parameters Map

A block of arbitrary string parameters to pass to the SSM document.

scheduleExpression String

A cron expression when the association will be applied to the target(s).

targets ListTargetArgs>

A block containing the targets of the SSM association. Targets are documented below. AWS currently supports a maximum of 5 targets.

waitForSuccessTimeoutSeconds Integer

The number of seconds to wait for the association status to be Success. If Success status is not reached within the given time, create opration will fail.

applyOnlyAtCronInterval boolean

By default, when you create a new or update associations, the system runs it immediately and then according to the schedule you specified. Enable this option if you do not want an association to run immediately after you create or update it. This parameter is not supported for rate expressions. Default: false.

associationName string

The descriptive name for the association.

automationTargetParameterName string

Specify the target for the association. This target is required for associations that use an Automation document and target resources by using rate controls. This should be set to the SSM document parameter that will define how your automation will branch out.

complianceSeverity string

The compliance severity for the association. Can be one of the following: UNSPECIFIED, LOW, MEDIUM, HIGH or CRITICAL

documentVersion string

The document version you want to associate with the target(s). Can be a specific version or the default version.

instanceId string

The instance ID to apply an SSM document to. Use targets with key InstanceIds for document schema versions 2.0 and above.

Deprecated:

use 'targets' argument instead. https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_CreateAssociation.html#systemsmanager-CreateAssociation-request-InstanceId

maxConcurrency string

The maximum number of targets allowed to run the association at the same time. You can specify a number, for example 10, or a percentage of the target set, for example 10%.

maxErrors string

The number of errors that are allowed before the system stops sending requests to run the association on additional targets. You can specify a number, for example 10, or a percentage of the target set, for example 10%.

name string

The name of the SSM document to apply.

outputLocation AssociationOutputLocationArgs

An output location block. Output Location is documented below.

parameters {[key: string]: string}

A block of arbitrary string parameters to pass to the SSM document.

scheduleExpression string

A cron expression when the association will be applied to the target(s).

targets AssociationTargetArgs[]

A block containing the targets of the SSM association. Targets are documented below. AWS currently supports a maximum of 5 targets.

waitForSuccessTimeoutSeconds number

The number of seconds to wait for the association status to be Success. If Success status is not reached within the given time, create opration will fail.

apply_only_at_cron_interval bool

By default, when you create a new or update associations, the system runs it immediately and then according to the schedule you specified. Enable this option if you do not want an association to run immediately after you create or update it. This parameter is not supported for rate expressions. Default: false.

association_name str

The descriptive name for the association.

automation_target_parameter_name str

Specify the target for the association. This target is required for associations that use an Automation document and target resources by using rate controls. This should be set to the SSM document parameter that will define how your automation will branch out.

compliance_severity str

The compliance severity for the association. Can be one of the following: UNSPECIFIED, LOW, MEDIUM, HIGH or CRITICAL

document_version str

The document version you want to associate with the target(s). Can be a specific version or the default version.

instance_id str

The instance ID to apply an SSM document to. Use targets with key InstanceIds for document schema versions 2.0 and above.

Deprecated:

use 'targets' argument instead. https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_CreateAssociation.html#systemsmanager-CreateAssociation-request-InstanceId

max_concurrency str

The maximum number of targets allowed to run the association at the same time. You can specify a number, for example 10, or a percentage of the target set, for example 10%.

max_errors str

The number of errors that are allowed before the system stops sending requests to run the association on additional targets. You can specify a number, for example 10, or a percentage of the target set, for example 10%.

name str

The name of the SSM document to apply.

output_location AssociationOutputLocationArgs

An output location block. Output Location is documented below.

parameters Mapping[str, str]

A block of arbitrary string parameters to pass to the SSM document.

schedule_expression str

A cron expression when the association will be applied to the target(s).

targets Sequence[AssociationTargetArgs]

A block containing the targets of the SSM association. Targets are documented below. AWS currently supports a maximum of 5 targets.

wait_for_success_timeout_seconds int

The number of seconds to wait for the association status to be Success. If Success status is not reached within the given time, create opration will fail.

applyOnlyAtCronInterval Boolean

By default, when you create a new or update associations, the system runs it immediately and then according to the schedule you specified. Enable this option if you do not want an association to run immediately after you create or update it. This parameter is not supported for rate expressions. Default: false.

associationName String

The descriptive name for the association.

automationTargetParameterName String

Specify the target for the association. This target is required for associations that use an Automation document and target resources by using rate controls. This should be set to the SSM document parameter that will define how your automation will branch out.

complianceSeverity String

The compliance severity for the association. Can be one of the following: UNSPECIFIED, LOW, MEDIUM, HIGH or CRITICAL

documentVersion String

The document version you want to associate with the target(s). Can be a specific version or the default version.

instanceId String

The instance ID to apply an SSM document to. Use targets with key InstanceIds for document schema versions 2.0 and above.

Deprecated:

use 'targets' argument instead. https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_CreateAssociation.html#systemsmanager-CreateAssociation-request-InstanceId

maxConcurrency String

The maximum number of targets allowed to run the association at the same time. You can specify a number, for example 10, or a percentage of the target set, for example 10%.

maxErrors String

The number of errors that are allowed before the system stops sending requests to run the association on additional targets. You can specify a number, for example 10, or a percentage of the target set, for example 10%.

name String

The name of the SSM document to apply.

outputLocation Property Map

An output location block. Output Location is documented below.

parameters Map

A block of arbitrary string parameters to pass to the SSM document.

scheduleExpression String

A cron expression when the association will be applied to the target(s).

targets List

A block containing the targets of the SSM association. Targets are documented below. AWS currently supports a maximum of 5 targets.

waitForSuccessTimeoutSeconds Number

The number of seconds to wait for the association status to be Success. If Success status is not reached within the given time, create opration will fail.

Outputs

All input properties are implicitly available as output properties. Additionally, the Association resource produces the following output properties:

Arn string

The ARN of the SSM association

AssociationId string

The ID of the SSM association.

Id string

The provider-assigned unique ID for this managed resource.

Arn string

The ARN of the SSM association

AssociationId string

The ID of the SSM association.

Id string

The provider-assigned unique ID for this managed resource.

arn String

The ARN of the SSM association

associationId String

The ID of the SSM association.

id String

The provider-assigned unique ID for this managed resource.

arn string

The ARN of the SSM association

associationId string

The ID of the SSM association.

id string

The provider-assigned unique ID for this managed resource.

arn str

The ARN of the SSM association

association_id str

The ID of the SSM association.

id str

The provider-assigned unique ID for this managed resource.

arn String

The ARN of the SSM association

associationId String

The ID of the SSM association.

id String

The provider-assigned unique ID for this managed resource.

Look up an Existing Association Resource

Get an existing Association resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

public static get(name: string, id: Input<ID>, state?: AssociationState, opts?: CustomResourceOptions): Association
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        apply_only_at_cron_interval: Optional[bool] = None,
        arn: Optional[str] = None,
        association_id: Optional[str] = None,
        association_name: Optional[str] = None,
        automation_target_parameter_name: Optional[str] = None,
        compliance_severity: Optional[str] = None,
        document_version: Optional[str] = None,
        instance_id: Optional[str] = None,
        max_concurrency: Optional[str] = None,
        max_errors: Optional[str] = None,
        name: Optional[str] = None,
        output_location: Optional[AssociationOutputLocationArgs] = None,
        parameters: Optional[Mapping[str, str]] = None,
        schedule_expression: Optional[str] = None,
        targets: Optional[Sequence[AssociationTargetArgs]] = None,
        wait_for_success_timeout_seconds: Optional[int] = None) -> Association
func GetAssociation(ctx *Context, name string, id IDInput, state *AssociationState, opts ...ResourceOption) (*Association, error)
public static Association Get(string name, Input<string> id, AssociationState? state, CustomResourceOptions? opts = null)
public static Association get(String name, Output<String> id, AssociationState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
resource_name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
The following state arguments are supported:
ApplyOnlyAtCronInterval bool

By default, when you create a new or update associations, the system runs it immediately and then according to the schedule you specified. Enable this option if you do not want an association to run immediately after you create or update it. This parameter is not supported for rate expressions. Default: false.

Arn string

The ARN of the SSM association

AssociationId string

The ID of the SSM association.

AssociationName string

The descriptive name for the association.

AutomationTargetParameterName string

Specify the target for the association. This target is required for associations that use an Automation document and target resources by using rate controls. This should be set to the SSM document parameter that will define how your automation will branch out.

ComplianceSeverity string

The compliance severity for the association. Can be one of the following: UNSPECIFIED, LOW, MEDIUM, HIGH or CRITICAL

DocumentVersion string

The document version you want to associate with the target(s). Can be a specific version or the default version.

InstanceId string

The instance ID to apply an SSM document to. Use targets with key InstanceIds for document schema versions 2.0 and above.

Deprecated:

use 'targets' argument instead. https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_CreateAssociation.html#systemsmanager-CreateAssociation-request-InstanceId

MaxConcurrency string

The maximum number of targets allowed to run the association at the same time. You can specify a number, for example 10, or a percentage of the target set, for example 10%.

MaxErrors string

The number of errors that are allowed before the system stops sending requests to run the association on additional targets. You can specify a number, for example 10, or a percentage of the target set, for example 10%.

Name string

The name of the SSM document to apply.

OutputLocation Pulumi.Aws.Ssm.Inputs.AssociationOutputLocationArgs

An output location block. Output Location is documented below.

Parameters Dictionary<string, string>

A block of arbitrary string parameters to pass to the SSM document.

ScheduleExpression string

A cron expression when the association will be applied to the target(s).

Targets List<Pulumi.Aws.Ssm.Inputs.AssociationTargetArgs>

A block containing the targets of the SSM association. Targets are documented below. AWS currently supports a maximum of 5 targets.

WaitForSuccessTimeoutSeconds int

The number of seconds to wait for the association status to be Success. If Success status is not reached within the given time, create opration will fail.

ApplyOnlyAtCronInterval bool

By default, when you create a new or update associations, the system runs it immediately and then according to the schedule you specified. Enable this option if you do not want an association to run immediately after you create or update it. This parameter is not supported for rate expressions. Default: false.

Arn string

The ARN of the SSM association

AssociationId string

The ID of the SSM association.

AssociationName string

The descriptive name for the association.

AutomationTargetParameterName string

Specify the target for the association. This target is required for associations that use an Automation document and target resources by using rate controls. This should be set to the SSM document parameter that will define how your automation will branch out.

ComplianceSeverity string

The compliance severity for the association. Can be one of the following: UNSPECIFIED, LOW, MEDIUM, HIGH or CRITICAL

DocumentVersion string

The document version you want to associate with the target(s). Can be a specific version or the default version.

InstanceId string

The instance ID to apply an SSM document to. Use targets with key InstanceIds for document schema versions 2.0 and above.

Deprecated:

use 'targets' argument instead. https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_CreateAssociation.html#systemsmanager-CreateAssociation-request-InstanceId

MaxConcurrency string

The maximum number of targets allowed to run the association at the same time. You can specify a number, for example 10, or a percentage of the target set, for example 10%.

MaxErrors string

The number of errors that are allowed before the system stops sending requests to run the association on additional targets. You can specify a number, for example 10, or a percentage of the target set, for example 10%.

Name string

The name of the SSM document to apply.

OutputLocation AssociationOutputLocationArgs

An output location block. Output Location is documented below.

Parameters map[string]string

A block of arbitrary string parameters to pass to the SSM document.

ScheduleExpression string

A cron expression when the association will be applied to the target(s).

Targets []AssociationTargetArgs

A block containing the targets of the SSM association. Targets are documented below. AWS currently supports a maximum of 5 targets.

WaitForSuccessTimeoutSeconds int

The number of seconds to wait for the association status to be Success. If Success status is not reached within the given time, create opration will fail.

applyOnlyAtCronInterval Boolean

By default, when you create a new or update associations, the system runs it immediately and then according to the schedule you specified. Enable this option if you do not want an association to run immediately after you create or update it. This parameter is not supported for rate expressions. Default: false.

arn String

The ARN of the SSM association

associationId String

The ID of the SSM association.

associationName String

The descriptive name for the association.

automationTargetParameterName String

Specify the target for the association. This target is required for associations that use an Automation document and target resources by using rate controls. This should be set to the SSM document parameter that will define how your automation will branch out.

complianceSeverity String

The compliance severity for the association. Can be one of the following: UNSPECIFIED, LOW, MEDIUM, HIGH or CRITICAL

documentVersion String

The document version you want to associate with the target(s). Can be a specific version or the default version.

instanceId String

The instance ID to apply an SSM document to. Use targets with key InstanceIds for document schema versions 2.0 and above.

Deprecated:

use 'targets' argument instead. https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_CreateAssociation.html#systemsmanager-CreateAssociation-request-InstanceId

maxConcurrency String

The maximum number of targets allowed to run the association at the same time. You can specify a number, for example 10, or a percentage of the target set, for example 10%.

maxErrors String

The number of errors that are allowed before the system stops sending requests to run the association on additional targets. You can specify a number, for example 10, or a percentage of the target set, for example 10%.

name String

The name of the SSM document to apply.

outputLocation AssociationOutputLocationArgs

An output location block. Output Location is documented below.

parameters Map

A block of arbitrary string parameters to pass to the SSM document.

scheduleExpression String

A cron expression when the association will be applied to the target(s).

targets ListTargetArgs>

A block containing the targets of the SSM association. Targets are documented below. AWS currently supports a maximum of 5 targets.

waitForSuccessTimeoutSeconds Integer

The number of seconds to wait for the association status to be Success. If Success status is not reached within the given time, create opration will fail.

applyOnlyAtCronInterval boolean

By default, when you create a new or update associations, the system runs it immediately and then according to the schedule you specified. Enable this option if you do not want an association to run immediately after you create or update it. This parameter is not supported for rate expressions. Default: false.

arn string

The ARN of the SSM association

associationId string

The ID of the SSM association.

associationName string

The descriptive name for the association.

automationTargetParameterName string

Specify the target for the association. This target is required for associations that use an Automation document and target resources by using rate controls. This should be set to the SSM document parameter that will define how your automation will branch out.

complianceSeverity string

The compliance severity for the association. Can be one of the following: UNSPECIFIED, LOW, MEDIUM, HIGH or CRITICAL

documentVersion string

The document version you want to associate with the target(s). Can be a specific version or the default version.

instanceId string

The instance ID to apply an SSM document to. Use targets with key InstanceIds for document schema versions 2.0 and above.

Deprecated:

use 'targets' argument instead. https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_CreateAssociation.html#systemsmanager-CreateAssociation-request-InstanceId

maxConcurrency string

The maximum number of targets allowed to run the association at the same time. You can specify a number, for example 10, or a percentage of the target set, for example 10%.

maxErrors string

The number of errors that are allowed before the system stops sending requests to run the association on additional targets. You can specify a number, for example 10, or a percentage of the target set, for example 10%.

name string

The name of the SSM document to apply.

outputLocation AssociationOutputLocationArgs

An output location block. Output Location is documented below.

parameters {[key: string]: string}

A block of arbitrary string parameters to pass to the SSM document.

scheduleExpression string

A cron expression when the association will be applied to the target(s).

targets AssociationTargetArgs[]

A block containing the targets of the SSM association. Targets are documented below. AWS currently supports a maximum of 5 targets.

waitForSuccessTimeoutSeconds number

The number of seconds to wait for the association status to be Success. If Success status is not reached within the given time, create opration will fail.

apply_only_at_cron_interval bool

By default, when you create a new or update associations, the system runs it immediately and then according to the schedule you specified. Enable this option if you do not want an association to run immediately after you create or update it. This parameter is not supported for rate expressions. Default: false.

arn str

The ARN of the SSM association

association_id str

The ID of the SSM association.

association_name str

The descriptive name for the association.

automation_target_parameter_name str

Specify the target for the association. This target is required for associations that use an Automation document and target resources by using rate controls. This should be set to the SSM document parameter that will define how your automation will branch out.

compliance_severity str

The compliance severity for the association. Can be one of the following: UNSPECIFIED, LOW, MEDIUM, HIGH or CRITICAL

document_version str

The document version you want to associate with the target(s). Can be a specific version or the default version.

instance_id str

The instance ID to apply an SSM document to. Use targets with key InstanceIds for document schema versions 2.0 and above.

Deprecated:

use 'targets' argument instead. https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_CreateAssociation.html#systemsmanager-CreateAssociation-request-InstanceId

max_concurrency str

The maximum number of targets allowed to run the association at the same time. You can specify a number, for example 10, or a percentage of the target set, for example 10%.

max_errors str

The number of errors that are allowed before the system stops sending requests to run the association on additional targets. You can specify a number, for example 10, or a percentage of the target set, for example 10%.

name str

The name of the SSM document to apply.

output_location AssociationOutputLocationArgs

An output location block. Output Location is documented below.

parameters Mapping[str, str]

A block of arbitrary string parameters to pass to the SSM document.

schedule_expression str

A cron expression when the association will be applied to the target(s).

targets Sequence[AssociationTargetArgs]

A block containing the targets of the SSM association. Targets are documented below. AWS currently supports a maximum of 5 targets.

wait_for_success_timeout_seconds int

The number of seconds to wait for the association status to be Success. If Success status is not reached within the given time, create opration will fail.

applyOnlyAtCronInterval Boolean

By default, when you create a new or update associations, the system runs it immediately and then according to the schedule you specified. Enable this option if you do not want an association to run immediately after you create or update it. This parameter is not supported for rate expressions. Default: false.

arn String

The ARN of the SSM association

associationId String

The ID of the SSM association.

associationName String

The descriptive name for the association.

automationTargetParameterName String

Specify the target for the association. This target is required for associations that use an Automation document and target resources by using rate controls. This should be set to the SSM document parameter that will define how your automation will branch out.

complianceSeverity String

The compliance severity for the association. Can be one of the following: UNSPECIFIED, LOW, MEDIUM, HIGH or CRITICAL

documentVersion String

The document version you want to associate with the target(s). Can be a specific version or the default version.

instanceId String

The instance ID to apply an SSM document to. Use targets with key InstanceIds for document schema versions 2.0 and above.

Deprecated:

use 'targets' argument instead. https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_CreateAssociation.html#systemsmanager-CreateAssociation-request-InstanceId

maxConcurrency String

The maximum number of targets allowed to run the association at the same time. You can specify a number, for example 10, or a percentage of the target set, for example 10%.

maxErrors String

The number of errors that are allowed before the system stops sending requests to run the association on additional targets. You can specify a number, for example 10, or a percentage of the target set, for example 10%.

name String

The name of the SSM document to apply.

outputLocation Property Map

An output location block. Output Location is documented below.

parameters Map

A block of arbitrary string parameters to pass to the SSM document.

scheduleExpression String

A cron expression when the association will be applied to the target(s).

targets List

A block containing the targets of the SSM association. Targets are documented below. AWS currently supports a maximum of 5 targets.

waitForSuccessTimeoutSeconds Number

The number of seconds to wait for the association status to be Success. If Success status is not reached within the given time, create opration will fail.

Supporting Types

AssociationOutputLocation

S3BucketName string

The S3 bucket name.

S3KeyPrefix string

The S3 bucket prefix. Results stored in the root if not configured.

S3Region string

The S3 bucket region.

S3BucketName string

The S3 bucket name.

S3KeyPrefix string

The S3 bucket prefix. Results stored in the root if not configured.

S3Region string

The S3 bucket region.

s3BucketName String

The S3 bucket name.

s3KeyPrefix String

The S3 bucket prefix. Results stored in the root if not configured.

s3Region String

The S3 bucket region.

s3BucketName string

The S3 bucket name.

s3KeyPrefix string

The S3 bucket prefix. Results stored in the root if not configured.

s3Region string

The S3 bucket region.

s3_bucket_name str

The S3 bucket name.

s3_key_prefix str

The S3 bucket prefix. Results stored in the root if not configured.

s3_region str

The S3 bucket region.

s3BucketName String

The S3 bucket name.

s3KeyPrefix String

The S3 bucket prefix. Results stored in the root if not configured.

s3Region String

The S3 bucket region.

AssociationTarget

Key string

Either InstanceIds or tag:Tag Name to specify an EC2 tag.

Values List<string>

A list of instance IDs or tag values. AWS currently limits this list size to one value.

Key string

Either InstanceIds or tag:Tag Name to specify an EC2 tag.

Values []string

A list of instance IDs or tag values. AWS currently limits this list size to one value.

key String

Either InstanceIds or tag:Tag Name to specify an EC2 tag.

values List

A list of instance IDs or tag values. AWS currently limits this list size to one value.

key string

Either InstanceIds or tag:Tag Name to specify an EC2 tag.

values string[]

A list of instance IDs or tag values. AWS currently limits this list size to one value.

key str

Either InstanceIds or tag:Tag Name to specify an EC2 tag.

values Sequence[str]

A list of instance IDs or tag values. AWS currently limits this list size to one value.

key String

Either InstanceIds or tag:Tag Name to specify an EC2 tag.

values List

A list of instance IDs or tag values. AWS currently limits this list size to one value.

Import

SSM associations can be imported using the association_id, e.g.,

 $ pulumi import aws:ssm/association:Association test-association 10abcdef-0abc-1234-5678-90abcdef123456

Package Details

Repository
https://github.com/pulumi/pulumi-aws
License
Apache-2.0
Notes

This Pulumi package is based on the aws Terraform Provider.