Class: AWSCDK::EKSv2::HelmChartProps

Inherits:
HelmChartOptions
  • Object
show all
Defined in:
ek_sv2/helm_chart_props.rb

Overview

Helm Chart properties.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(atomic: nil, chart: nil, chart_asset: nil, create_namespace: nil, namespace: nil, release: nil, removal_policy: nil, repository: nil, skip_crds: nil, timeout: nil, values: nil, version: nil, wait: nil, cluster:) ⇒ HelmChartProps

Returns a new instance of HelmChartProps.

Parameters:

  • atomic (Boolean, nil) (defaults to: nil)

    Whether or not Helm should treat this operation as atomic;

  • chart (String, nil) (defaults to: nil)

    The name of the chart.

  • chart_asset (AWSCDK::S3Assets::Asset, nil) (defaults to: nil)

    The chart in the form of an asset.

  • create_namespace (Boolean, nil) (defaults to: nil)

    create namespace if not exist.

  • namespace (String, nil) (defaults to: nil)

    The Kubernetes namespace scope of the requests.

  • release (String, nil) (defaults to: nil)

    The name of the release.

  • removal_policy (AWSCDK::RemovalPolicy, nil) (defaults to: nil)

    The removal policy applied to the custom resource that manages the Helm chart.

  • repository (String, nil) (defaults to: nil)

    The repository which contains the chart.

  • skip_crds (Boolean, nil) (defaults to: nil)

    if set, no CRDs will be installed.

  • timeout (AWSCDK::Duration, nil) (defaults to: nil)

    Amount of time to wait for any individual Kubernetes operation.

  • values (Hash{String => Object}, nil) (defaults to: nil)

    The values to be used by the chart.

  • version (String, nil) (defaults to: nil)

    The chart version to install.

  • wait (Boolean, nil) (defaults to: nil)

    Whether or not Helm should wait until all Pods, PVCs, Services, and minimum number of Pods of a Deployment, StatefulSet, or ReplicaSet are in a ready state before marking the release as successful.

  • cluster (AWSCDK::EKSv2::ICluster)

    The EKS cluster to apply this configuration to.



21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
# File 'ek_sv2/helm_chart_props.rb', line 21

def initialize(atomic: nil, chart: nil, chart_asset: nil, create_namespace: nil, namespace: nil, release: nil, removal_policy: nil, repository: nil, skip_crds: nil, timeout: nil, values: nil, version: nil, wait: nil, cluster:)
  @atomic = atomic
  Jsii::Type.check_type(@atomic, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJib29sZWFuIn0=")), "atomic") unless @atomic.nil?
  @chart = chart
  Jsii::Type.check_type(@chart, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "chart") unless @chart.nil?
  @chart_asset = chart_asset
  Jsii::Type.check_type(@chart_asset, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfczNfYXNzZXRzLkFzc2V0In0=")), "chartAsset") unless @chart_asset.nil?
  @create_namespace = create_namespace
  Jsii::Type.check_type(@create_namespace, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJib29sZWFuIn0=")), "createNamespace") unless @create_namespace.nil?
  @namespace = namespace
  Jsii::Type.check_type(@namespace, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "namespace") unless @namespace.nil?
  @release = release
  Jsii::Type.check_type(@release, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "release") unless @release.nil?
  @removal_policy = removal_policy
  Jsii::Type.check_type(@removal_policy, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5SZW1vdmFsUG9saWN5In0=")), "removalPolicy") unless @removal_policy.nil?
  @repository = repository
  Jsii::Type.check_type(@repository, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "repository") unless @repository.nil?
  @skip_crds = skip_crds
  Jsii::Type.check_type(@skip_crds, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJib29sZWFuIn0=")), "skipCrds") unless @skip_crds.nil?
  @timeout = timeout
  Jsii::Type.check_type(@timeout, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5EdXJhdGlvbiJ9")), "timeout") unless @timeout.nil?
  @values = values
  Jsii::Type.check_type(@values, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6ImFueSJ9LCJraW5kIjoibWFwIn19")), "values") unless @values.nil?
  @version = version
  Jsii::Type.check_type(@version, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "version") unless @version.nil?
  @wait = wait
  Jsii::Type.check_type(@wait, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJib29sZWFuIn0=")), "wait") unless @wait.nil?
  @cluster = cluster
  Jsii::Type.check_type(@cluster, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfZWtzX3YyLklDbHVzdGVyIn0=")), "cluster")
end

Instance Attribute Details

#atomicBoolean? (readonly)

Note:

Default: false

Whether or not Helm should treat this operation as atomic;

if set, upgrade process rolls back changes made in case of failed upgrade. The --wait flag will be set automatically if --atomic is used.

Returns:

  • (Boolean, nil)


59
60
61
# File 'ek_sv2/helm_chart_props.rb', line 59

def atomic
  @atomic
end

#chartString? (readonly)

Note:

Default: - No chart name. Implies chartAsset is used.

The name of the chart.

Either this or chart_asset must be specified.

Returns:

  • (String, nil)


66
67
68
# File 'ek_sv2/helm_chart_props.rb', line 66

def chart
  @chart
end

#chart_assetAWSCDK::S3Assets::Asset? (readonly)

Note:

Default: - No chart asset. Implies chart is used.

The chart in the form of an asset.

Either this or chart must be specified.

Returns:



73
74
75
# File 'ek_sv2/helm_chart_props.rb', line 73

def chart_asset
  @chart_asset
end

#clusterAWSCDK::EKSv2::ICluster (readonly)

The EKS cluster to apply this configuration to.

[disable-awslint:ref-via-interface]



146
147
148
# File 'ek_sv2/helm_chart_props.rb', line 146

def cluster
  @cluster
end

#create_namespaceBoolean? (readonly)

Note:

Default: true

create namespace if not exist.

Returns:

  • (Boolean, nil)


78
79
80
# File 'ek_sv2/helm_chart_props.rb', line 78

def create_namespace
  @create_namespace
end

#namespaceString? (readonly)

Note:

Default: default

The Kubernetes namespace scope of the requests.

Returns:

  • (String, nil)


83
84
85
# File 'ek_sv2/helm_chart_props.rb', line 83

def namespace
  @namespace
end

#releaseString? (readonly)

Note:

Default: - If no release name is given, it will use the last 53 characters of the node's unique id.

The name of the release.

Returns:

  • (String, nil)


88
89
90
# File 'ek_sv2/helm_chart_props.rb', line 88

def release
  @release
end

#removal_policyAWSCDK::RemovalPolicy? (readonly)

Note:

Default: RemovalPolicy.DESTROY

The removal policy applied to the custom resource that manages the Helm chart.

The removal policy controls what happens to the resource if it stops being managed by CloudFormation. This can happen in one of three situations:

  • The resource is removed from the template, so CloudFormation stops managing it
  • A change to the resource is made that requires it to be replaced, so CloudFormation stops managing it
  • The stack is deleted, so CloudFormation stops managing all resources in it

Returns:



100
101
102
# File 'ek_sv2/helm_chart_props.rb', line 100

def removal_policy
  @removal_policy
end

#repositoryString? (readonly)

Note:

Default: - No repository will be used, which means that the chart needs to be an absolute URL.

The repository which contains the chart.

For example: https://charts.helm.sh/stable/

Returns:

  • (String, nil)


107
108
109
# File 'ek_sv2/helm_chart_props.rb', line 107

def repository
  @repository
end

#skip_crdsBoolean? (readonly)

Note:

Default: - CRDs are installed if not already present

if set, no CRDs will be installed.

Returns:

  • (Boolean, nil)


112
113
114
# File 'ek_sv2/helm_chart_props.rb', line 112

def skip_crds
  @skip_crds
end

#timeoutAWSCDK::Duration? (readonly)

Note:

Default: Duration.minutes(5)

Amount of time to wait for any individual Kubernetes operation.

Maximum 15 minutes.

Returns:



119
120
121
# File 'ek_sv2/helm_chart_props.rb', line 119

def timeout
  @timeout
end

#valuesHash{String => Object}? (readonly)

Note:

Default: - No values are provided to the chart.

The values to be used by the chart.

For nested values use a nested dictionary. For example: values: { installationCRDs: true, webhook: { port: 9443 } }

Returns:

  • (Hash{String => Object}, nil)


130
131
132
# File 'ek_sv2/helm_chart_props.rb', line 130

def values
  @values
end

#versionString? (readonly)

Note:

Default: - If this is not specified, the latest version is installed

The chart version to install.

Returns:

  • (String, nil)


135
136
137
# File 'ek_sv2/helm_chart_props.rb', line 135

def version
  @version
end

#waitBoolean? (readonly)

Note:

Default: - Helm will not wait before marking release as successful

Whether or not Helm should wait until all Pods, PVCs, Services, and minimum number of Pods of a Deployment, StatefulSet, or ReplicaSet are in a ready state before marking the release as successful.

Returns:

  • (Boolean, nil)


140
141
142
# File 'ek_sv2/helm_chart_props.rb', line 140

def wait
  @wait
end

Class Method Details

.jsii_propertiesObject



148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
# File 'ek_sv2/helm_chart_props.rb', line 148

def self.jsii_properties
  {
    :atomic => "atomic",
    :chart => "chart",
    :chart_asset => "chartAsset",
    :create_namespace => "createNamespace",
    :namespace => "namespace",
    :release => "release",
    :removal_policy => "removalPolicy",
    :repository => "repository",
    :skip_crds => "skipCrds",
    :timeout => "timeout",
    :values => "values",
    :version => "version",
    :wait => "wait",
    :cluster => "cluster",
  }
end

Instance Method Details

#to_jsiiObject



167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
# File 'ek_sv2/helm_chart_props.rb', line 167

def to_jsii
  result = {}
  result.merge!(super)
  result.merge!({
    "atomic" => @atomic,
    "chart" => @chart,
    "chartAsset" => @chart_asset,
    "createNamespace" => @create_namespace,
    "namespace" => @namespace,
    "release" => @release,
    "removalPolicy" => @removal_policy,
    "repository" => @repository,
    "skipCrds" => @skip_crds,
    "timeout" => @timeout,
    "values" => @values,
    "version" => @version,
    "wait" => @wait,
    "cluster" => @cluster,
  })
  result.compact
end