Class: AWSCDK::CodeDeploy::CfnDeploymentGroup::AutoRollbackConfigurationProperty

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
code_deploy/cfn_deployment_group.rb

Overview

The AutoRollbackConfiguration property type configures automatic rollback for an AWS CodeDeploy deployment group when a deployment is not completed successfully.

For more information, see Automatic Rollbacks in the AWS CodeDeploy User Guide .

AutoRollbackConfiguration is a property of the DeploymentGroup resource.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(enabled: nil, events: nil) ⇒ AutoRollbackConfigurationProperty

Returns a new instance of AutoRollbackConfigurationProperty.

Parameters:

  • enabled (Boolean, AWSCDK::IResolvable, nil) (defaults to: nil)

    Indicates whether a defined automatic rollback configuration is currently enabled.

  • events (Array<String>, nil) (defaults to: nil)

    The event type or types that trigger a rollback.



865
866
867
868
869
870
# File 'code_deploy/cfn_deployment_group.rb', line 865

def initialize(enabled: nil, events: nil)
  @enabled = enabled
  Jsii::Type.check_type(@enabled, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3sicHJpbWl0aXZlIjoiYm9vbGVhbiJ9LHsiZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifV19fQ==")), "enabled") unless @enabled.nil?
  @events = events
  Jsii::Type.check_type(@events, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "events") unless @events.nil?
end

Instance Attribute Details

#enabledBoolean, ... (readonly)

Indicates whether a defined automatic rollback configuration is currently enabled.



876
877
878
# File 'code_deploy/cfn_deployment_group.rb', line 876

def enabled
  @enabled
end

#eventsArray<String>? (readonly)

The event type or types that trigger a rollback.

Valid values are DEPLOYMENT_FAILURE , DEPLOYMENT_STOP_ON_ALARM , or DEPLOYMENT_STOP_ON_REQUEST .



883
884
885
# File 'code_deploy/cfn_deployment_group.rb', line 883

def events
  @events
end

Class Method Details

.jsii_propertiesObject



885
886
887
888
889
890
# File 'code_deploy/cfn_deployment_group.rb', line 885

def self.jsii_properties
  {
    :enabled => "enabled",
    :events => "events",
  }
end

Instance Method Details

#to_jsiiObject



892
893
894
895
896
897
898
899
# File 'code_deploy/cfn_deployment_group.rb', line 892

def to_jsii
  result = {}
  result.merge!({
    "enabled" => @enabled,
    "events" => @events,
  })
  result.compact
end