Class: AWSCDK::SSM::CfnDocumentProps
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::SSM::CfnDocumentProps
- Defined in:
- ssm/cfn_document_props.rb
Overview
Properties for defining a CfnDocument.
Instance Attribute Summary collapse
-
#attachments ⇒ AWSCDK::IResolvable, ...
readonly
A list of key-value pairs that describe attachments to a version of a document.
-
#content ⇒ Object
readonly
The content for the new SSM document in JSON or YAML.
-
#document_format ⇒ String?
readonly
Specify the document format for the request.
-
#document_type ⇒ String?
readonly
The type of document to create.
-
#name ⇒ String?
readonly
A name for the SSM document.
-
#requires ⇒ AWSCDK::IResolvable, ...
readonly
A list of SSM documents required by a document.
-
#tags ⇒ Array<AWSCDK::CfnTag>?
readonly
AWS CloudFormation resource tags to apply to the document.
-
#target_type ⇒ String?
readonly
Specify a target type to define the kinds of resources the document can run on.
-
#update_method ⇒ String?
readonly
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.
-
#version_name ⇒ String?
readonly
An optional field specifying the version of the artifact you are creating with the document.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(content:, attachments: nil, document_format: nil, document_type: nil, name: nil, requires: nil, tags: nil, target_type: nil, update_method: nil, version_name: nil) ⇒ CfnDocumentProps
constructor
A new instance of CfnDocumentProps.
- #to_jsii ⇒ Object
Constructor Details
#initialize(content:, attachments: nil, document_format: nil, document_type: nil, name: nil, requires: nil, tags: nil, target_type: nil, update_method: nil, version_name: nil) ⇒ CfnDocumentProps
Returns a new instance of CfnDocumentProps.
19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 |
# File 'ssm/cfn_document_props.rb', line 19 def initialize(content:, attachments: nil, document_format: nil, document_type: nil, name: nil, requires: nil, tags: nil, target_type: nil, update_method: nil, version_name: nil) @content = content Jsii::Type.check_type(@content, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJhbnkifQ==")), "content") @attachments = Jsii::Type.check_type(@attachments, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImNvbGxlY3Rpb24iOnsiZWxlbWVudHR5cGUiOnsidW5pb24iOnsidHlwZXMiOlt7ImZxbiI6ImF3cy1jZGstbGliLklSZXNvbHZhYmxlIn0seyJmcW4iOiJhd3MtY2RrLWxpYi5hd3Nfc3NtLkNmbkRvY3VtZW50LkF0dGFjaG1lbnRzU291cmNlUHJvcGVydHkifV19fSwia2luZCI6ImFycmF5In19XX19")), "attachments") unless @attachments.nil? @document_format = document_format Jsii::Type.check_type(@document_format, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "documentFormat") unless @document_format.nil? @document_type = document_type Jsii::Type.check_type(@document_type, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "documentType") unless @document_type.nil? @name = name Jsii::Type.check_type(@name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "name") unless @name.nil? @requires = requires Jsii::Type.check_type(@requires, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImNvbGxlY3Rpb24iOnsiZWxlbWVudHR5cGUiOnsidW5pb24iOnsidHlwZXMiOlt7ImZxbiI6ImF3cy1jZGstbGliLklSZXNvbHZhYmxlIn0seyJmcW4iOiJhd3MtY2RrLWxpYi5hd3Nfc3NtLkNmbkRvY3VtZW50LkRvY3VtZW50UmVxdWlyZXNQcm9wZXJ0eSJ9XX19LCJraW5kIjoiYXJyYXkifX1dfX0=")), "requires") unless @requires.nil? @tags = .is_a?(Array) ? .map { |jsii_v0| jsii_v0.is_a?(Hash) ? ::AWSCDK::CfnTag.new(**jsii_v0.transform_keys(&:to_sym)) : jsii_v0 } : Jsii::Type.check_type(@tags, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7ImZxbiI6ImF3cy1jZGstbGliLkNmblRhZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "tags") unless @tags.nil? @target_type = target_type Jsii::Type.check_type(@target_type, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "targetType") unless @target_type.nil? @update_method = update_method Jsii::Type.check_type(@update_method, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "updateMethod") unless @update_method.nil? @version_name = version_name Jsii::Type.check_type(@version_name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "versionName") unless @version_name.nil? end |
Instance Attribute Details
#attachments ⇒ AWSCDK::IResolvable, ... (readonly)
A list of key-value pairs that describe attachments to a version of a document.
55 56 57 |
# File 'ssm/cfn_document_props.rb', line 55 def @attachments end |
#content ⇒ Object (readonly)
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 in the AWS Systems Manager User Guide .
This parameter also supports
Stringdata types.
50 51 52 |
# File 'ssm/cfn_document_props.rb', line 50 def content @content end |
#document_format ⇒ String? (readonly)
Default: - "JSON"
Specify the document format for the request.
JSON is the default format.
63 64 65 |
# File 'ssm/cfn_document_props.rb', line 63 def document_format @document_format end |
#document_type ⇒ String? (readonly)
The type of document to create.
68 69 70 |
# File 'ssm/cfn_document_props.rb', line 68 def document_type @document_type end |
#name ⇒ String? (readonly)
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:
awsamazonamznAWSEC2AWSConfigRemediationAWSSupport
82 83 84 |
# File 'ssm/cfn_document_props.rb', line 82 def name @name end |
#requires ⇒ AWSCDK::IResolvable, ... (readonly)
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 ? in the AWS AppConfig User Guide .
89 90 91 |
# File 'ssm/cfn_document_props.rb', line 89 def requires @requires end |
#tags ⇒ Array<AWSCDK::CfnTag>? (readonly)
AWS CloudFormation resource tags to apply to the document.
Use tags to help you identify and categorize resources.
96 97 98 |
# File 'ssm/cfn_document_props.rb', line 96 def @tags end |
#target_type ⇒ String? (readonly)
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 in the AWS CloudFormation User Guide .
103 104 105 |
# File 'ssm/cfn_document_props.rb', line 103 def target_type @target_type end |
#update_method ⇒ String? (readonly)
Default: - "Replace"
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.
111 112 113 |
# File 'ssm/cfn_document_props.rb', line 111 def update_method @update_method end |
#version_name ⇒ String? (readonly)
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.
118 119 120 |
# File 'ssm/cfn_document_props.rb', line 118 def version_name @version_name end |
Class Method Details
.jsii_properties ⇒ Object
120 121 122 123 124 125 126 127 128 129 130 131 132 133 |
# File 'ssm/cfn_document_props.rb', line 120 def self.jsii_properties { :content => "content", :attachments => "attachments", :document_format => "documentFormat", :document_type => "documentType", :name => "name", :requires => "requires", :tags => "tags", :target_type => "targetType", :update_method => "updateMethod", :version_name => "versionName", } end |
Instance Method Details
#to_jsii ⇒ Object
135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 |
# File 'ssm/cfn_document_props.rb', line 135 def to_jsii result = {} result.merge!({ "content" => @content, "attachments" => @attachments, "documentFormat" => @document_format, "documentType" => @document_type, "name" => @name, "requires" => @requires, "tags" => @tags, "targetType" => @target_type, "updateMethod" => @update_method, "versionName" => @version_name, }) result.compact end |