Class: AWSCDK::Codepipeline::RuleProps
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::Codepipeline::RuleProps
- Defined in:
- codepipeline/rule_props.rb
Overview
Properties for defining a CodePipeline Rule.
Instance Attribute Summary collapse
-
#commands ⇒ Array<String>?
readonly
The shell commands to run with your commands rule in CodePipeline.
-
#configuration ⇒ Hash?
readonly
The action configuration fields for the rule.
-
#input_artifacts ⇒ Array<String>?
readonly
The input artifacts fields for the rule, such as specifying an input file for the rule.
-
#name ⇒ String?
readonly
The name of the rule that is created for the condition.
-
#provider ⇒ String?
readonly
The rule provider that implements the rule's functionality.
-
#region ⇒ String?
readonly
The AWS Region for the condition associated with the rule.
-
#role ⇒ AWSCDK::IAM::Role?
readonly
The IAM role that the rule will use to execute its actions.
-
#version ⇒ String?
readonly
The version of the rule to use.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(commands: nil, configuration: nil, input_artifacts: nil, name: nil, provider: nil, region: nil, role: nil, version: nil) ⇒ RuleProps
constructor
A new instance of RuleProps.
- #to_jsii ⇒ Object
Constructor Details
#initialize(commands: nil, configuration: nil, input_artifacts: nil, name: nil, provider: nil, region: nil, role: nil, version: nil) ⇒ RuleProps
Returns a new instance of RuleProps.
15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 |
# File 'codepipeline/rule_props.rb', line 15 def initialize(commands: nil, configuration: nil, input_artifacts: nil, name: nil, provider: nil, region: nil, role: nil, version: nil) @commands = commands Jsii::Type.check_type(@commands, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "commands") unless @commands.nil? @configuration = configuration Jsii::Type.check_type(@configuration, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJqc29uIn0=")), "configuration") unless @configuration.nil? @input_artifacts = input_artifacts Jsii::Type.check_type(@input_artifacts, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "inputArtifacts") unless @input_artifacts.nil? @name = name Jsii::Type.check_type(@name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "name") unless @name.nil? @provider = provider Jsii::Type.check_type(@provider, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "provider") unless @provider.nil? @region = region Jsii::Type.check_type(@region, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "region") unless @region.nil? @role = role Jsii::Type.check_type(@role, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfaWFtLlJvbGUifQ==")), "role") unless @role.nil? @version = version Jsii::Type.check_type(@version, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "version") unless @version.nil? end |
Instance Attribute Details
#commands ⇒ Array<String>? (readonly)
Default: - No commands
The shell commands to run with your commands rule in CodePipeline.
All commands are supported except multi-line formats. While CodeBuild logs and permissions are used, you do not need to create any resources in CodeBuild.
41 42 43 |
# File 'codepipeline/rule_props.rb', line 41 def commands @commands end |
#configuration ⇒ Hash? (readonly)
Default: - No configuration
The action configuration fields for the rule.
This can include custom parameters specific to the rule type.
48 49 50 |
# File 'codepipeline/rule_props.rb', line 48 def configuration @configuration end |
#input_artifacts ⇒ Array<String>? (readonly)
Default: - No input artifacts
The input artifacts fields for the rule, such as specifying an input file for the rule.
Each string in the array represents an artifact name that this rule will use as input.
55 56 57 |
# File 'codepipeline/rule_props.rb', line 55 def input_artifacts @input_artifacts end |
#name ⇒ String? (readonly)
Default: - A unique name will be generated
The name of the rule that is created for the condition.
Must be unique within the pipeline.
64 65 66 |
# File 'codepipeline/rule_props.rb', line 64 def name @name end |
#provider ⇒ String? (readonly)
Default: - No provider, must be specified if rule is used
The rule provider that implements the rule's functionality.
72 73 74 |
# File 'codepipeline/rule_props.rb', line 72 def provider @provider end |
#region ⇒ String? (readonly)
Default: - Pipeline's region
The AWS Region for the condition associated with the rule.
If not specified, uses the pipeline's region.
79 80 81 |
# File 'codepipeline/rule_props.rb', line 79 def region @region end |
#role ⇒ AWSCDK::IAM::Role? (readonly)
Default: - A new role will be created
The IAM role that the rule will use to execute its actions.
The role must have sufficient permissions to perform the rule's tasks.
86 87 88 |
# File 'codepipeline/rule_props.rb', line 86 def role @role end |
#version ⇒ String? (readonly)
Default: '1'
The version of the rule to use.
Different versions may have different features or behaviors.
93 94 95 |
# File 'codepipeline/rule_props.rb', line 93 def version @version end |
Class Method Details
.jsii_properties ⇒ Object
95 96 97 98 99 100 101 102 103 104 105 106 |
# File 'codepipeline/rule_props.rb', line 95 def self.jsii_properties { :commands => "commands", :configuration => "configuration", :input_artifacts => "inputArtifacts", :name => "name", :provider => "provider", :region => "region", :role => "role", :version => "version", } end |
Instance Method Details
#to_jsii ⇒ Object
108 109 110 111 112 113 114 115 116 117 118 119 120 121 |
# File 'codepipeline/rule_props.rb', line 108 def to_jsii result = {} result.merge!({ "commands" => @commands, "configuration" => @configuration, "inputArtifacts" => @input_artifacts, "name" => @name, "provider" => @provider, "region" => @region, "role" => @role, "version" => @version, }) result.compact end |