Class: AWSCDK::Pipelines::StackSteps

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
pipelines/stack_steps.rb

Overview

Instructions for additional steps that are run at stack level.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(stack:, change_set: nil, post: nil, pre: nil) ⇒ StackSteps

Returns a new instance of StackSteps.

Parameters:

  • stack (AWSCDK::Stack)

    The stack you want the steps to run in.

  • change_set (Array<AWSCDK::Pipelines::Step>, nil) (defaults to: nil)

    Steps that execute after stack is prepared but before stack is deployed.

  • post (Array<AWSCDK::Pipelines::Step>, nil) (defaults to: nil)

    Steps that execute after stack is deployed.

  • pre (Array<AWSCDK::Pipelines::Step>, nil) (defaults to: nil)

    Steps that execute before stack is prepared.



11
12
13
14
15
16
17
18
19
20
# File 'pipelines/stack_steps.rb', line 11

def initialize(stack:, change_set: nil, post: nil, pre: nil)
  @stack = stack
  Jsii::Type.check_type(@stack, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5TdGFjayJ9")), "stack")
  @change_set = change_set
  Jsii::Type.check_type(@change_set, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7ImZxbiI6ImF3cy1jZGstbGliLnBpcGVsaW5lcy5TdGVwIn0sImtpbmQiOiJhcnJheSJ9fQ==")), "changeSet") unless @change_set.nil?
  @post = post
  Jsii::Type.check_type(@post, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7ImZxbiI6ImF3cy1jZGstbGliLnBpcGVsaW5lcy5TdGVwIn0sImtpbmQiOiJhcnJheSJ9fQ==")), "post") unless @post.nil?
  @pre = pre
  Jsii::Type.check_type(@pre, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7ImZxbiI6ImF3cy1jZGstbGliLnBpcGVsaW5lcy5TdGVwIn0sImtpbmQiOiJhcnJheSJ9fQ==")), "pre") unless @pre.nil?
end

Instance Attribute Details

#change_setArray<AWSCDK::Pipelines::Step>? (readonly)

Note:

Default: - no additional steps

Steps that execute after stack is prepared but before stack is deployed.

Returns:



30
31
32
# File 'pipelines/stack_steps.rb', line 30

def change_set
  @change_set
end

#postArray<AWSCDK::Pipelines::Step>? (readonly)

Note:

Default: - no additional steps

Steps that execute after stack is deployed.

Returns:



35
36
37
# File 'pipelines/stack_steps.rb', line 35

def post
  @post
end

#preArray<AWSCDK::Pipelines::Step>? (readonly)

Note:

Default: - no additional steps

Steps that execute before stack is prepared.

Returns:



40
41
42
# File 'pipelines/stack_steps.rb', line 40

def pre
  @pre
end

#stackAWSCDK::Stack (readonly)

The stack you want the steps to run in.

Returns:



25
26
27
# File 'pipelines/stack_steps.rb', line 25

def stack
  @stack
end

Class Method Details

.jsii_propertiesObject



42
43
44
45
46
47
48
49
# File 'pipelines/stack_steps.rb', line 42

def self.jsii_properties
  {
    :stack => "stack",
    :change_set => "changeSet",
    :post => "post",
    :pre => "pre",
  }
end

Instance Method Details

#to_jsiiObject



51
52
53
54
55
56
57
58
59
60
# File 'pipelines/stack_steps.rb', line 51

def to_jsii
  result = {}
  result.merge!({
    "stack" => @stack,
    "changeSet" => @change_set,
    "post" => @post,
    "pre" => @pre,
  })
  result.compact
end