aws-cdk-lib
Version:
Version 2 of the AWS Cloud Development Kit library
1,008 lines • 166 kB
TypeScript
import * as cdk from "../../core/lib";
import * as constructs from "constructs";
import * as cfn_parse from "../../core/lib/helpers-internal";
import { aws_s3 as s3Refs, aws_ssm as ssmRefs } from "../../interfaces";
import { AssociationReference, DocumentReference, IAssociationRef, IDocumentRef, IMaintenanceWindowRef, IMaintenanceWindowTargetRef, IMaintenanceWindowTaskRef, IParameterRef, IPatchBaselineRef, IResourceDataSyncRef, IResourcePolicyRef, MaintenanceWindowReference, MaintenanceWindowTargetReference, MaintenanceWindowTaskReference, ParameterReference, PatchBaselineReference, ResourceDataSyncReference, ResourcePolicyReference } from "../../interfaces/generated/aws-ssm-interfaces.generated";
/**
* The `AWS::SSM::Association` resource creates a State Manager association for your managed instances.
*
* A State Manager association defines the state that you want to maintain on your instances. For example, an association can specify that anti-virus software must be installed and running on your instances, or that certain ports must be closed. For static targets, the association specifies a schedule for when the configuration is reapplied. For dynamic targets, such as an Resource Groups or an AWS Auto Scaling Group, State Manager applies the configuration when new instances are added to the group. The association also specifies actions to take when applying the configuration. For example, an association for anti-virus software might run once a day. If the software is not installed, then State Manager installs it. If the software is installed, but the service is not running, then the association might instruct State Manager to start the service.
*
* @cloudformationResource AWS::SSM::Association
* @stability external
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-association.html
*/
export declare class CfnAssociation extends cdk.CfnResource implements cdk.IInspectable, IAssociationRef {
/**
* The CloudFormation resource type name for this resource class.
*/
static readonly CFN_RESOURCE_TYPE_NAME: string;
/**
* Build a CfnAssociation from CloudFormation properties
*
* A factory method that creates a new instance of this class from an object
* containing the CloudFormation properties of this resource.
* Used in the @aws-cdk/cloudformation-include module.
*
* @internal
*/
static _fromCloudFormation(scope: constructs.Construct, id: string, resourceAttributes: any, options: cfn_parse.FromCloudFormationOptions): CfnAssociation;
/**
* Checks whether the given object is a CfnAssociation
*/
static isCfnAssociation(x: any): x is CfnAssociation;
/**
* Creates a new IAssociationRef from a associationId
*/
static fromAssociationId(scope: constructs.Construct, id: string, associationId: string): IAssociationRef;
static arnForAssociation(resource: IAssociationRef): string;
/**
* By default, when you create a new association, the system runs it immediately after it is created and then according to the schedule you specified.
*/
private _applyOnlyAtCronInterval?;
/**
* Specify a descriptive name for the association.
*/
private _associationName?;
/**
* Choose the parameter that will define how your automation will branch out.
*/
private _automationTargetParameterName?;
/**
* The names or Amazon Resource Names (ARNs) of the Change Calendar type documents your associations are gated under.
*/
private _calendarNames?;
/**
* The severity level that is assigned to the association.
*/
private _complianceSeverity?;
/**
* The version of the SSM document to associate with the target.
*/
private _documentVersion?;
/**
* > `InstanceId` has been deprecated.
*/
private _instanceId?;
/**
* The maximum number of targets allowed to run the association at the same time.
*/
private _maxConcurrency?;
/**
* The number of errors that are allowed before the system stops sending requests to run the association on additional targets.
*/
private _maxErrors?;
/**
* The name of the SSM document that contains the configuration information for the instance.
*/
private _name;
/**
* An Amazon Simple Storage Service (Amazon S3) bucket where you want to store the output details of the request.
*/
private _outputLocation?;
/**
* The parameters for the runtime configuration of the document.
*/
private _parameters?;
/**
* A cron expression that specifies a schedule when the association runs.
*/
private _scheduleExpression?;
/**
* Number of days to wait after the scheduled day to run an association.
*/
private _scheduleOffset?;
/**
* The mode for generating association compliance.
*/
private _syncCompliance?;
/**
* The targets for the association.
*/
private _targets?;
/**
* The number of seconds the service should wait for the association status to show "Success" before proceeding with the stack execution.
*/
private _waitForSuccessTimeoutSeconds?;
/**
* Create a new `AWS::SSM::Association`.
*
* @param scope Scope in which this resource is defined
* @param id Construct identifier for this resource (unique in its scope)
* @param props Resource properties
*/
constructor(scope: constructs.Construct, id: string, props: CfnAssociationProps);
get associationRef(): AssociationReference;
/**
* By default, when you create a new association, the system runs it immediately after it is created and then according to the schedule you specified.
*/
get applyOnlyAtCronInterval(): boolean | cdk.IResolvable | undefined;
/**
* By default, when you create a new association, the system runs it immediately after it is created and then according to the schedule you specified.
*/
set applyOnlyAtCronInterval(value: boolean | cdk.IResolvable | undefined);
/**
* Specify a descriptive name for the association.
*/
get associationName(): string | undefined;
/**
* Specify a descriptive name for the association.
*/
set associationName(value: string | undefined);
/**
* Choose the parameter that will define how your automation will branch out.
*/
get automationTargetParameterName(): string | undefined;
/**
* Choose the parameter that will define how your automation will branch out.
*/
set automationTargetParameterName(value: string | undefined);
/**
* The names or Amazon Resource Names (ARNs) of the Change Calendar type documents your associations are gated under.
*/
get calendarNames(): Array<string> | undefined;
/**
* The names or Amazon Resource Names (ARNs) of the Change Calendar type documents your associations are gated under.
*/
set calendarNames(value: Array<string> | undefined);
/**
* The severity level that is assigned to the association.
*/
get complianceSeverity(): string | undefined;
/**
* The severity level that is assigned to the association.
*/
set complianceSeverity(value: string | undefined);
/**
* The version of the SSM document to associate with the target.
*/
get documentVersion(): string | undefined;
/**
* The version of the SSM document to associate with the target.
*/
set documentVersion(value: string | undefined);
/**
* > `InstanceId` has been deprecated.
*/
get instanceId(): string | undefined;
/**
* > `InstanceId` has been deprecated.
*/
set instanceId(value: string | undefined);
/**
* The maximum number of targets allowed to run the association at the same time.
*/
get maxConcurrency(): string | undefined;
/**
* The maximum number of targets allowed to run the association at the same time.
*/
set maxConcurrency(value: string | undefined);
/**
* The number of errors that are allowed before the system stops sending requests to run the association on additional targets.
*/
get maxErrors(): string | undefined;
/**
* The number of errors that are allowed before the system stops sending requests to run the association on additional targets.
*/
set maxErrors(value: string | undefined);
/**
* The name of the SSM document that contains the configuration information for the instance.
*/
get name(): string;
/**
* The name of the SSM document that contains the configuration information for the instance.
*/
set name(value: string);
/**
* An Amazon Simple Storage Service (Amazon S3) bucket where you want to store the output details of the request.
*/
get outputLocation(): CfnAssociation.InstanceAssociationOutputLocationProperty | cdk.IResolvable | undefined;
/**
* An Amazon Simple Storage Service (Amazon S3) bucket where you want to store the output details of the request.
*/
set outputLocation(value: CfnAssociation.InstanceAssociationOutputLocationProperty | cdk.IResolvable | undefined);
/**
* The parameters for the runtime configuration of the document.
*/
get parameters(): any | cdk.IResolvable | undefined;
/**
* The parameters for the runtime configuration of the document.
*/
set parameters(value: any | cdk.IResolvable | undefined);
/**
* A cron expression that specifies a schedule when the association runs.
*/
get scheduleExpression(): string | undefined;
/**
* A cron expression that specifies a schedule when the association runs.
*/
set scheduleExpression(value: string | undefined);
/**
* Number of days to wait after the scheduled day to run an association.
*/
get scheduleOffset(): number | undefined;
/**
* Number of days to wait after the scheduled day to run an association.
*/
set scheduleOffset(value: number | undefined);
/**
* The mode for generating association compliance.
*/
get syncCompliance(): string | undefined;
/**
* The mode for generating association compliance.
*/
set syncCompliance(value: string | undefined);
/**
* The targets for the association.
*/
get targets(): Array<cdk.IResolvable | CfnAssociation.TargetProperty> | cdk.IResolvable | undefined;
/**
* The targets for the association.
*/
set targets(value: Array<cdk.IResolvable | CfnAssociation.TargetProperty> | cdk.IResolvable | undefined);
/**
* The number of seconds the service should wait for the association status to show "Success" before proceeding with the stack execution.
*/
get waitForSuccessTimeoutSeconds(): number | undefined;
/**
* The number of seconds the service should wait for the association status to show "Success" before proceeding with the stack execution.
*/
set waitForSuccessTimeoutSeconds(value: number | undefined);
/**
* The association ID.
*
* @cloudformationAttribute AssociationId
*/
get attrAssociationId(): string;
protected get cfnProperties(): Record<string, any>;
/**
* Examines the CloudFormation resource and discloses attributes
*
* @param inspector tree inspector to collect and process attributes
*/
inspect(inspector: cdk.TreeInspector): void;
protected renderProperties(props: Record<string, any>): Record<string, any>;
}
export declare namespace CfnAssociation {
/**
* `Target` is a property of the [AWS::SSM::Association](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-association.html) resource that specifies the targets for an SSM document in Systems Manager . You can target all instances in an AWS account by specifying the `InstanceIds` key with a value of `*` . To view a JSON and a YAML example that targets all instances, see the example "Create an association for all managed instances in an AWS account " later in this page.
*
* @struct
* @stability external
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ssm-association-target.html
*/
interface TargetProperty {
/**
* User-defined criteria for sending commands that target managed nodes that meet the criteria.
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ssm-association-target.html#cfn-ssm-association-target-key
*/
readonly key: string;
/**
* User-defined criteria that maps to `Key` .
*
* For example, if you specified `tag:ServerRole` , you could specify `value:WebServer` to run a command on instances that include EC2 tags of `ServerRole,WebServer` .
*
* Depending on the type of target, the maximum number of values for a key might be lower than the global maximum of 50.
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ssm-association-target.html#cfn-ssm-association-target-values
*/
readonly values: Array<string>;
}
/**
* `InstanceAssociationOutputLocation` is a property of the [AWS::SSM::Association](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-association.html) resource that specifies an Amazon S3 bucket where you want to store the results of this association request.
*
* For the minimal permissions required to enable Amazon S3 output for an association, see [Creating associations](https://docs.aws.amazon.com/systems-manager/latest/userguide/sysman-state-assoc.html) in the *Systems Manager User Guide* .
*
* @struct
* @stability external
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ssm-association-instanceassociationoutputlocation.html
*/
interface InstanceAssociationOutputLocationProperty {
/**
* `S3OutputLocation` is a property of the [InstanceAssociationOutputLocation](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ssm-association-instanceassociationoutputlocation.html) property that specifies an Amazon S3 bucket where you want to store the results of this request.
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ssm-association-instanceassociationoutputlocation.html#cfn-ssm-association-instanceassociationoutputlocation-s3location
*/
readonly s3Location?: cdk.IResolvable | CfnAssociation.S3OutputLocationProperty;
}
/**
* `S3OutputLocation` is a property of the [AWS::SSM::Association](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-association.html) resource that specifies an Amazon S3 bucket where you want to store the results of this association request.
*
* @struct
* @stability external
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ssm-association-s3outputlocation.html
*/
interface S3OutputLocationProperty {
/**
* The name of the S3 bucket.
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ssm-association-s3outputlocation.html#cfn-ssm-association-s3outputlocation-outputs3bucketname
*/
readonly outputS3BucketName?: string;
/**
* The S3 bucket subfolder.
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ssm-association-s3outputlocation.html#cfn-ssm-association-s3outputlocation-outputs3keyprefix
*/
readonly outputS3KeyPrefix?: string;
/**
* The AWS Region of the S3 bucket.
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ssm-association-s3outputlocation.html#cfn-ssm-association-s3outputlocation-outputs3region
*/
readonly outputS3Region?: string;
}
}
/**
* Properties for defining a `CfnAssociation`
*
* @struct
* @stability external
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-association.html
*/
export interface CfnAssociationProps {
/**
* By default, when you create a new association, the system runs it immediately after it is created and then according to the schedule you specified.
*
* Specify this option if you don't want an association to run immediately after you create it. This parameter is not supported for rate expressions.
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-association.html#cfn-ssm-association-applyonlyatcroninterval
*/
readonly applyOnlyAtCronInterval?: boolean | cdk.IResolvable;
/**
* Specify a descriptive name for the association.
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-association.html#cfn-ssm-association-associationname
*/
readonly associationName?: string;
/**
* Choose the parameter that will define how your automation will branch out.
*
* This target is required for associations that use an Automation runbook and target resources by using rate controls. Automation is a tool in AWS Systems Manager .
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-association.html#cfn-ssm-association-automationtargetparametername
*/
readonly automationTargetParameterName?: string;
/**
* The names or Amazon Resource Names (ARNs) of the Change Calendar type documents your associations are gated under.
*
* The associations only run when that Change Calendar is open. For more information, see [AWS Systems Manager Change Calendar](https://docs.aws.amazon.com/systems-manager/latest/userguide/systems-manager-change-calendar) in the *AWS Systems Manager User Guide* .
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-association.html#cfn-ssm-association-calendarnames
*/
readonly calendarNames?: Array<string>;
/**
* The severity level that is assigned to the association.
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-association.html#cfn-ssm-association-complianceseverity
*/
readonly complianceSeverity?: string;
/**
* The version of the SSM document to associate with the target.
*
* > Note the following important information.
* >
* > - State Manager doesn't support running associations that use a new version of a document if that document is shared from another account. State Manager always runs the `default` version of a document if shared from another account, even though the Systems Manager console shows that a new version was processed. If you want to run an association using a new version of a document shared form another account, you must set the document version to `default` .
* > - `DocumentVersion` is not valid for documents owned by AWS , such as `AWS-RunPatchBaseline` or `AWS-UpdateSSMAgent` . If you specify `DocumentVersion` for an AWS document, the system returns the following error: "Error occurred during operation 'CreateAssociation'." (RequestToken: <token>, HandlerErrorCode: GeneralServiceException).
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-association.html#cfn-ssm-association-documentversion
*/
readonly documentVersion?: string;
/**
* > `InstanceId` has been deprecated.
*
* To specify an instance ID for an association, use the `Targets` parameter. If you use the parameter `InstanceId` , you cannot use the parameters `AssociationName` , `DocumentVersion` , `MaxErrors` , `MaxConcurrency` , `OutputLocation` , or `ScheduleExpression` . To use these parameters, you must use the `Targets` parameter.
* >
* > Note that in some examples later in this page, `InstanceIds` is used as the tag-key name in a `Targets` filter. `InstanceId` is not used as a parameter.
*
* The ID of the instance that the SSM document is associated with. You must specify the `InstanceId` or `Targets` property.
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-association.html#cfn-ssm-association-instanceid
*/
readonly instanceId?: 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%. The default value is 100%, which means all targets run the association at the same time.
*
* If a new managed node starts and attempts to run an association while Systems Manager is running `MaxConcurrency` associations, the association is allowed to run. During the next association interval, the new managed node will process its association within the limit specified for `MaxConcurrency` .
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-association.html#cfn-ssm-association-maxconcurrency
*/
readonly maxConcurrency?: string;
/**
* The number of errors that are allowed before the system stops sending requests to run the association on additional targets.
*
* You can specify either an absolute number of errors, for example 10, or a percentage of the target set, for example 10%. If you specify 3, for example, the system stops sending requests when the fourth error is received. If you specify 0, then the system stops sending requests after the first error is returned. If you run an association on 50 managed nodes and set `MaxError` to 10%, then the system stops sending the request when the sixth error is received.
*
* Executions that are already running an association when `MaxErrors` is reached are allowed to complete, but some of these executions may fail as well. If you need to ensure that there won't be more than max-errors failed executions, set `MaxConcurrency` to 1 so that executions proceed one at a time.
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-association.html#cfn-ssm-association-maxerrors
*/
readonly maxErrors?: string;
/**
* The name of the SSM document that contains the configuration information for the instance.
*
* You can specify `Command` or `Automation` documents. The documents can be AWS -predefined documents, documents you created, or a document that is shared with you from another account. For SSM documents that are shared with you from other AWS accounts , you must specify the complete SSM document ARN, in the following format:
*
* `arn:partition:ssm:region:account-id:document/document-name`
*
* For example: `arn:aws:ssm:us-east-2:12345678912:document/My-Shared-Document`
*
* For AWS -predefined documents and SSM documents you created in your account, you only need to specify the document name. For example, `AWS -ApplyPatchBaseline` or `My-Document` .
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-association.html#cfn-ssm-association-name
*/
readonly name: ssmRefs.IDocumentRef | string;
/**
* An Amazon Simple Storage Service (Amazon S3) bucket where you want to store the output details of the request.
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-association.html#cfn-ssm-association-outputlocation
*/
readonly outputLocation?: CfnAssociation.InstanceAssociationOutputLocationProperty | cdk.IResolvable;
/**
* The parameters for the runtime configuration of the document.
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-association.html#cfn-ssm-association-parameters
*/
readonly parameters?: any | cdk.IResolvable;
/**
* A cron expression that specifies a schedule when the association runs.
*
* The schedule runs in Coordinated Universal Time (UTC).
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-association.html#cfn-ssm-association-scheduleexpression
*/
readonly scheduleExpression?: string;
/**
* Number of days to wait after the scheduled day to run an association.
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-association.html#cfn-ssm-association-scheduleoffset
*/
readonly scheduleOffset?: number;
/**
* The mode for generating association compliance.
*
* You can specify `AUTO` or `MANUAL` . In `AUTO` mode, the system uses the status of the association execution to determine the compliance status. If the association execution runs successfully, then the association is `COMPLIANT` . If the association execution doesn't run successfully, the association is `NON-COMPLIANT` .
*
* In `MANUAL` mode, you must specify the `AssociationId` as a parameter for the `PutComplianceItems` API action. In this case, compliance data is not managed by State Manager. It is managed by your direct call to the `PutComplianceItems` API action.
*
* By default, all associations use `AUTO` mode.
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-association.html#cfn-ssm-association-synccompliance
*/
readonly syncCompliance?: string;
/**
* The targets for the association.
*
* You must specify the `InstanceId` or `Targets` property. You can target all instances in an AWS account by specifying t he `InstanceIds` key with a value of `*` .
*
* Supported formats include the following.
*
* - `Key=InstanceIds,Values=<instance-id-1>,<instance-id-2>,<instance-id-3>`
* - `Key=tag-key,Values=<my-tag-key-1>,<my-tag-key-2>`
*
* To view a JSON and a YAML example that targets all instances, see "Create an association for all managed instances in an AWS account " on the Examples page.
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-association.html#cfn-ssm-association-targets
*/
readonly targets?: Array<cdk.IResolvable | CfnAssociation.TargetProperty> | cdk.IResolvable;
/**
* The number of seconds the service should wait for the association status to show "Success" before proceeding with the stack execution.
*
* If the association status doesn't show "Success" after the specified number of seconds, then stack creation fails.
*
* > When you specify a value for the `WaitForSuccessTimeoutSeconds` , [drift detection](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-stack-drift.html) for your CloudFormation stack’s configuration might yield inaccurate results. If drift detection is important in your scenario, we recommend that you don’t include `WaitForSuccessTimeoutSeconds` in your template.
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-association.html#cfn-ssm-association-waitforsuccesstimeoutseconds
*/
readonly waitForSuccessTimeoutSeconds?: number;
}
/**
* The `AWS::SSM::Document` resource creates a Systems Manager (SSM) document in AWS Systems Manager .
*
* This document defines the actions that Systems Manager performs on your AWS resources.
*
* > This resource does not support CloudFormation drift detection.
*
* @cloudformationResource AWS::SSM::Document
* @stability external
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-document.html
*/
export declare class CfnDocument extends cdk.CfnResource implements cdk.IInspectable, IDocumentRef, cdk.ITaggable {
/**
* The CloudFormation resource type name for this resource class.
*/
static readonly CFN_RESOURCE_TYPE_NAME: string;
/**
* Build a CfnDocument from CloudFormation properties
*
* A factory method that creates a new instance of this class from an object
* containing the CloudFormation properties of this resource.
* Used in the @aws-cdk/cloudformation-include module.
*
* @internal
*/
static _fromCloudFormation(scope: constructs.Construct, id: string, resourceAttributes: any, options: cfn_parse.FromCloudFormationOptions): CfnDocument;
/**
* Checks whether the given object is a CfnDocument
*/
static isCfnDocument(x: any): x is CfnDocument;
/**
* Creates a new IDocumentRef from a documentName
*/
static fromDocumentName(scope: constructs.Construct, id: string, documentName: string): IDocumentRef;
static arnForDocument(resource: IDocumentRef): string;
/**
* A list of key-value pairs that describe attachments to a version of a document.
*/
private _attachments?;
/**
* The content for the new SSM document in JSON or YAML.
*/
private _content;
/**
* Specify the document format for the request.
*/
private _documentFormat?;
/**
* The type of document to create.
*/
private _documentType?;
/**
* A name for the SSM document.
*/
private _name?;
/**
* A list of SSM documents required by a document.
*/
private _requires?;
/**
* Tag Manager which manages the tags for this resource
*/
readonly tags: cdk.TagManager;
/**
* AWS CloudFormation resource tags to apply to the document.
*/
private _tagsRaw?;
/**
* Specify a target type to define the kinds of resources the document can run on.
*/
private _targetType?;
/**
* If the document resource you specify in your template already exists, this parameter determines whether a new version of the existing document is created, or the existing document is replaced.
*/
private _updateMethod?;
/**
* An optional field specifying the version of the artifact you are creating with the document.
*/
private _versionName?;
/**
* Create a new `AWS::SSM::Document`.
*
* @param scope Scope in which this resource is defined
* @param id Construct identifier for this resource (unique in its scope)
* @param props Resource properties
*/
constructor(scope: constructs.Construct, id: string, props: CfnDocumentProps);
get documentRef(): DocumentReference;
/**
* A list of key-value pairs that describe attachments to a version of a document.
*/
get attachments(): Array<CfnDocument.AttachmentsSourceProperty | cdk.IResolvable> | cdk.IResolvable | undefined;
/**
* A list of key-value pairs that describe attachments to a version of a document.
*/
set attachments(value: Array<CfnDocument.AttachmentsSourceProperty | cdk.IResolvable> | cdk.IResolvable | undefined);
/**
* The content for the new SSM document in JSON or YAML.
*/
get content(): any | cdk.IResolvable;
/**
* The content for the new SSM document in JSON or YAML.
*/
set content(value: any | cdk.IResolvable);
/**
* Specify the document format for the request.
*/
get documentFormat(): string | undefined;
/**
* Specify the document format for the request.
*/
set documentFormat(value: string | undefined);
/**
* The type of document to create.
*/
get documentType(): string | undefined;
/**
* The type of document to create.
*/
set documentType(value: string | undefined);
/**
* A name for the SSM document.
*/
get name(): string | undefined;
/**
* A name for the SSM document.
*/
set name(value: string | undefined);
/**
* A list of SSM documents required by a document.
*/
get requires(): Array<CfnDocument.DocumentRequiresProperty | cdk.IResolvable> | cdk.IResolvable | undefined;
/**
* A list of SSM documents required by a document.
*/
set requires(value: Array<CfnDocument.DocumentRequiresProperty | cdk.IResolvable> | cdk.IResolvable | undefined);
/**
* AWS CloudFormation resource tags to apply to the document.
*/
get tagsRaw(): Array<cdk.CfnTag> | undefined;
/**
* AWS CloudFormation resource tags to apply to the document.
*/
set tagsRaw(value: Array<cdk.CfnTag> | undefined);
/**
* Specify a target type to define the kinds of resources the document can run on.
*/
get targetType(): string | undefined;
/**
* Specify a target type to define the kinds of resources the document can run on.
*/
set targetType(value: string | undefined);
/**
* If the document resource you specify in your template already exists, this parameter determines whether a new version of the existing document is created, or the existing document is replaced.
*/
get updateMethod(): string | undefined;
/**
* If the document resource you specify in your template already exists, this parameter determines whether a new version of the existing document is created, or the existing document is replaced.
*/
set updateMethod(value: string | undefined);
/**
* An optional field specifying the version of the artifact you are creating with the document.
*/
get versionName(): string | undefined;
/**
* An optional field specifying the version of the artifact you are creating with the document.
*/
set versionName(value: string | undefined);
protected get cfnProperties(): Record<string, any>;
/**
* Examines the CloudFormation resource and discloses attributes
*
* @param inspector tree inspector to collect and process attributes
*/
inspect(inspector: cdk.TreeInspector): void;
protected renderProperties(props: Record<string, any>): Record<string, any>;
}
export declare namespace CfnDocument {
/**
* An SSM document required by the current document.
*
* @struct
* @stability external
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ssm-document-documentrequires.html
*/
interface DocumentRequiresProperty {
/**
* The name of the required SSM document.
*
* The name can be an Amazon Resource Name (ARN).
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ssm-document-documentrequires.html#cfn-ssm-document-documentrequires-name
*/
readonly name?: string;
/**
* The document version required by the current document.
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ssm-document-documentrequires.html#cfn-ssm-document-documentrequires-version
*/
readonly version?: string;
}
/**
* Identifying information about a document attachment, including the file name and a key-value pair that identifies the location of an attachment to a document.
*
* @struct
* @stability external
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ssm-document-attachmentssource.html
*/
interface AttachmentsSourceProperty {
/**
* The key of a key-value pair that identifies the location of an attachment to a document.
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ssm-document-attachmentssource.html#cfn-ssm-document-attachmentssource-key
*/
readonly key?: string;
/**
* The name of the document attachment file.
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ssm-document-attachmentssource.html#cfn-ssm-document-attachmentssource-name
*/
readonly name?: string;
/**
* The value of a key-value pair that identifies the location of an attachment to a document.
*
* The format for *Value* depends on the type of key you specify.
*
* - For the key *SourceUrl* , the value is an S3 bucket location. For example:
*
* `"Values": [ "s3://amzn-s3-demo-bucket/my-prefix" ]`
* - For the key *S3FileUrl* , the value is a file in an S3 bucket. For example:
*
* `"Values": [ "s3://amzn-s3-demo-bucket/my-prefix/my-file.py" ]`
* - For the key *AttachmentReference* , the value is constructed from the name of another SSM document in your account, a version number of that document, and a file attached to that document version that you want to reuse. For example:
*
* `"Values": [ "MyOtherDocument/3/my-other-file.py" ]`
*
* However, if the SSM document is shared with you from another account, the full SSM document ARN must be specified instead of the document name only. For example:
*
* `"Values": [ "arn:aws:ssm:us-east-2:111122223333:document/OtherAccountDocument/3/their-file.py" ]`
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ssm-document-attachmentssource.html#cfn-ssm-document-attachmentssource-values
*/
readonly values?: Array<string>;
}
}
/**
* Properties for defining a `CfnDocument`
*
* @struct
* @stability external
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-document.html
*/
export interface CfnDocumentProps {
/**
* A list of key-value pairs that describe attachments to a version of a document.
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-document.html#cfn-ssm-document-attachments
*/
readonly attachments?: Array<CfnDocument.AttachmentsSourceProperty | cdk.IResolvable> | cdk.IResolvable;
/**
* The content for the new SSM document in JSON or YAML.
*
* For more information about the schemas for SSM document content, see [SSM document schema features and examples](https://docs.aws.amazon.com/systems-manager/latest/userguide/document-schemas-features.html) in the *AWS Systems Manager User Guide* .
*
* > This parameter also supports `String` data types.
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-document.html#cfn-ssm-document-content
*/
readonly content: any | cdk.IResolvable;
/**
* Specify the document format for the request.
*
* `JSON` is the default format.
*
* @default - "JSON"
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-document.html#cfn-ssm-document-documentformat
*/
readonly documentFormat?: string;
/**
* The type of document to create.
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-document.html#cfn-ssm-document-documenttype
*/
readonly documentType?: string;
/**
* A name for the SSM document.
*
* > You can't use the following strings as document name prefixes. These are reserved by AWS for use as document name prefixes:
* >
* > - `aws`
* > - `amazon`
* > - `amzn`
* > - `AWSEC2`
* > - `AWSConfigRemediation`
* > - `AWSSupport`
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-document.html#cfn-ssm-document-name
*/
readonly name?: string;
/**
* A list of SSM documents required by a document.
*
* This parameter is used exclusively by AWS AppConfig . When a user creates an AWS AppConfig configuration in an SSM document, the user must also specify a required document for validation purposes. In this case, an `ApplicationConfiguration` document requires an `ApplicationConfigurationSchema` document for validation purposes. For more information, see [What is AWS AppConfig ?](https://docs.aws.amazon.com/appconfig/latest/userguide/what-is-appconfig.html) in the *AWS AppConfig User Guide* .
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-document.html#cfn-ssm-document-requires
*/
readonly requires?: Array<CfnDocument.DocumentRequiresProperty | cdk.IResolvable> | cdk.IResolvable;
/**
* AWS CloudFormation resource tags to apply to the document.
*
* Use tags to help you identify and categorize resources.
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-document.html#cfn-ssm-document-tags
*/
readonly tags?: Array<cdk.CfnTag>;
/**
* Specify a target type to define the kinds of resources the document can run on.
*
* For example, to run a document on EC2 instances, specify the following value: `/AWS::EC2::Instance` . If you specify a value of '/' the document can run on all types of resources. If you don't specify a value, the document can't run on any resources. For a list of valid resource types, see [AWS resource and property types reference](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-template-resource-type-ref.html) in the *AWS CloudFormation User Guide* .
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-document.html#cfn-ssm-document-targettype
*/
readonly targetType?: string;
/**
* If the document resource you specify in your template already exists, this parameter determines whether a new version of the existing document is created, or the existing document is replaced.
*
* `Replace` is the default method. If you specify `NewVersion` for the `UpdateMethod` parameter, and the `Name` of the document does not match an existing resource, a new document is created. When you specify `NewVersion` , the default version of the document is changed to the newly created version.
*
* @default - "Replace"
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-document.html#cfn-ssm-document-updatemethod
*/
readonly updateMethod?: string;
/**
* An optional field specifying the version of the artifact you are creating with the document.
*
* For example, `Release12.1` . This value is unique across all versions of a document, and can't be changed.
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-document.html#cfn-ssm-document-versionname
*/
readonly versionName?: string;
}
/**
* The `AWS::SSM::MaintenanceWindow` resource represents general information about a maintenance window for AWS Systems Manager .
*
* Maintenance windows let you define a schedule for when to perform potentially disruptive actions on your instances, such as patching an operating system (OS), updating drivers, or installing software. Each maintenance window has a schedule, a duration, a set of registered targets, and a set of registered tasks.
*
* For more information, see [Systems Manager Maintenance Windows](https://docs.aws.amazon.com/systems-manager/latest/userguide/systems-manager-maintenance.html) in the *AWS Systems Manager User Guide* and [CreateMaintenanceWindow](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_CreateMaintenanceWindow.html) in the *AWS Systems Manager API Reference* .
*
* @cloudformationResource AWS::SSM::MaintenanceWindow
* @stability external
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-maintenancewindow.html
*/
export declare class CfnMaintenanceWindow extends cdk.CfnResource implements cdk.IInspectable, IMaintenanceWindowRef, cdk.ITaggable {
/**
* The CloudFormation resource type name for this resource class.
*/
static readonly CFN_RESOURCE_TYPE_NAME: string;
/**
* Build a CfnMaintenanceWindow from CloudFormation properties
*
* A factory method that creates a new instance of this class from an object
* containing the CloudFormation properties of this resource.
* Used in the @aws-cdk/cloudformation-include module.
*
* @internal
*/
static _fromCloudFormation(scope: constructs.Construct, id: string, resourceAttributes: any, options: cfn_parse.FromCloudFormationOptions): CfnMaintenanceWindow;
/**
* Checks whether the given object is a CfnMaintenanceWindow
*/
static isCfnMaintenanceWindow(x: any): x is CfnMaintenanceWindow;
/**
* Enables a maintenance window task to run on managed instances, even if you have not registered those instances as targets.
*/
private _allowUnassociatedTargets;
/**
* The number of hours before the end of the maintenance window that AWS Systems Manager stops scheduling new tasks for execution.
*/
private _cutoff;
/**
* A description of the maintenance window.
*/
private _description?;
/**
* The duration of the maintenance window in hours.
*/
private _duration;
/**
* The date and time, in ISO-8601 Extended format, for when the maintenance window is scheduled to become inactive.
*/
private _endDate?;
/**
* The name of the maintenance window.
*/
private _name;
/**
* The schedule of the maintenance window in the form of a cron or rate expression.
*/
private _schedule;
/**
* The number of days to wait to run a maintenance window after the scheduled cron expression date and time.
*/
private _scheduleOffset?;
/**
* The time zone that the scheduled maintenance window executions are based on, in Internet Assigned Numbers Authority (IANA) format.
*/
private _scheduleTimezone?;
/**
* The date and time, in ISO-8601 Extended format, for when the maintenance window is scheduled to become active.
*/
private _startDate?;
/**
* Tag Manager which manages the tags for this resource
*/
readonly tags: cdk.TagManager;
/**
* Optional metadata that you assign to a resource in the form of an arbitrary set of tags (key-value pairs).
*/
private _tagsRaw?;
/**
* Create a new `AWS::SSM::MaintenanceWindow`.
*
* @param scope Scope in which this resource is defined
* @param id Construct identifier for this resource (unique in its scope)
* @param props Resource properties
*/
constructor(scope: constructs.Construct, id: string, props: CfnMaintenanceWindowProps);
get maintenanceWindowRef(): MaintenanceWindowReference;
/**
* Enables a maintenance window task to run on managed instances, even if you have not registered those instances as targets.
*/
get allowUnassociatedTargets(): boolean | cdk.IResolvable;
/**
* Enables a maintenance window task to run on managed instances, even if you have not registered those instances as targets.
*/
set allowUnassociatedTargets(value: boolean | cdk.IResolvable);
/**
* The number of hours before the end of the maintenance window that AWS Systems Manager stops scheduling new tasks for execution.
*/
get cutoff(): number;
/**
* The number of hours before the end of the maintenance window that AWS Systems Manager stops scheduling new tasks for execution.
*/
set cutoff(value: number);
/**
* A description of the maintenance window.
*/
get description(): string | undefined;
/**
* A description of the maintenance window.
*/
set description(value: string | undefined);
/**
* The duration of the maintenance window in hours.
*/
get duration(): number;
/**
* The duration of the maintenance window in hours.
*/
set duration(value: number);
/**
* The date and time, in ISO-8601 Extended format, for when the maintenance window is scheduled to become inactive.
*/
get endDate(): string | undefined;
/**
* The date and time, in ISO-8601 Extended format, for when the maintenance window is scheduled to become inactive.
*/
set endDate(value: string | undefined);
/**
* The name of the maintenance window.
*/
get name(): string;
/**
* The name of the maintenance window.
*/
set name(value: string);
/**
* The schedule of the maintenance window in the form of a cron or rate expression.
*/
get schedule(): string;
/**
* The schedule of the maintenance window in the form of a cron or rate expression.
*/
set schedule(value: string);
/**
* The number of days to wait to run a maintenance window after the scheduled cron expression date and time.
*/
get scheduleOffset(): number | undefined;
/**
* The number of days to wait to run a maintenance window after the scheduled cron expression date and time.
*/
set scheduleOffset(value: number | undefined);
/**
* The time zone that the scheduled maintenance window executions are based on, in Internet Assigned Numbers Authority (IANA) format.
*/
get scheduleTimezone(): string | undefined;
/**
* The time zone that the scheduled maintenance window executions are based on, in Internet Assigned Numbers Authority (IANA) format.
*/
set scheduleTimezone(value: string | undefined);
/**
* The date and time, in ISO-8601 Extended format, for when the maintenance window is scheduled to become active.
*/
get startDate(): string | undefined;
/**
* The date and time, in ISO-8601 Extended format, for when the mai