Class: AWSCDK::CodePipelineActions::StackSetParameters

Inherits:
Jsii::Object
  • Object
show all
Defined in:
code_pipeline_actions/stack_set_parameters.rb

Overview

Base parameters for the StackSet.

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeStackSetParameters

Returns a new instance of StackSetParameters.



8
9
10
# File 'code_pipeline_actions/stack_set_parameters.rb', line 8

def initialize
  Jsii::Object.instance_method(:initialize).bind(self).call
end

Class Method Details

.from_artifact_path(artifact_path) ⇒ AWSCDK::CodePipelineActions::StackSetParameters

Read the parameters from a JSON file from one of the pipeline's artifacts.

The file needs to contain a list of { ParameterKey, ParameterValue, UsePreviousValue } objects, like this:

[
    {
        "ParameterKey": "BucketName",
        "ParameterValue": "my-bucket"
    },
    {
        "ParameterKey": "Asset1",
        "ParameterValue": "true"
    },
    {
        "ParameterKey": "Asset2",
        "UsePreviousValue": true
    }
]

You must specify all template parameters. Parameters you don't specify will revert to their Default values as specified in the template.

For of parameters you want to retain their existing values without specifying what those values are, set UsePreviousValue: true. Use of this feature is discouraged. CDK is for specifying desired-state infrastructure, and use of this feature makes the parameter values unmanaged.

Parameters:

Returns:

  • (AWSCDK::CodePipelineActions::StackSetParameters)


50
51
52
53
# File 'code_pipeline_actions/stack_set_parameters.rb', line 50

def self.from_artifact_path(artifact_path)
  Jsii::Type.check_type(artifact_path, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfY29kZXBpcGVsaW5lLkFydGlmYWN0UGF0aCJ9")), "artifactPath")
  Jsii::Kernel.instance.call_static("aws-cdk-lib.aws_codepipeline_actions.StackSetParameters", "fromArtifactPath", [artifact_path])
end

.from_literal(parameters, use_previous_values = nil) ⇒ AWSCDK::CodePipelineActions::StackSetParameters

A list of template parameters for your stack set.

You must specify all template parameters. Parameters you don't specify will revert to their Default values as specified in the template.

Specify the names of parameters you want to retain their existing values, without specifying what those values are, in an array in the second argument to this function. Use of this feature is discouraged. CDK is for specifying desired-state infrastructure, and use of this feature makes the parameter values unmanaged.

Examples:

parameters = AWSCDK::CodePipelineActions::StackSetParameters.from_literal({
    BucketName: "my-bucket",
    Asset1: "true",
})

Parameters:

  • parameters (Hash{String => String})
  • use_previous_values (Array<String>, nil) (defaults to: nil)

Returns:

  • (AWSCDK::CodePipelineActions::StackSetParameters)


74
75
76
77
78
# File 'code_pipeline_actions/stack_set_parameters.rb', line 74

def self.from_literal(parameters, use_previous_values = nil)
  Jsii::Type.check_type(parameters, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoibWFwIn19")), "parameters")
  Jsii::Type.check_type(use_previous_values, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "usePreviousValues") unless use_previous_values.nil?
  Jsii::Kernel.instance.call_static("aws-cdk-lib.aws_codepipeline_actions.StackSetParameters", "fromLiteral", [parameters, use_previous_values])
end

.jsii_overridable_methodsObject



12
13
14
15
# File 'code_pipeline_actions/stack_set_parameters.rb', line 12

def self.jsii_overridable_methods
  {
  }
end