Skip to content

Commit

Permalink
Add new field to make tests pass
Browse files Browse the repository at this point in the history
  • Loading branch information
andrewstucki committed Dec 20, 2024
1 parent 2572fd8 commit d96888f
Show file tree
Hide file tree
Showing 5 changed files with 52 additions and 49 deletions.
84 changes: 42 additions & 42 deletions charts/redpanda/templates/_values.go.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -122,9 +122,9 @@
{{- range $_ := (list 1) -}}
{{- $_is_returning := false -}}
{{- $conf := (get (fromJson (include "redpanda.Storage.GetTieredStorageConfig" (dict "a" (list $s) ))) "r") -}}
{{- $_412_b_ok := (get (fromJson (include "_shims.dicttest" (dict "a" (list $conf "cloud_storage_enabled" (coalesce nil)) ))) "r") -}}
{{- $b := (index $_412_b_ok 0) -}}
{{- $ok := (index $_412_b_ok 1) -}}
{{- $_405_b_ok := (get (fromJson (include "_shims.dicttest" (dict "a" (list $conf "cloud_storage_enabled" (coalesce nil)) ))) "r") -}}
{{- $b := (index $_405_b_ok 0) -}}
{{- $ok := (index $_405_b_ok 1) -}}
{{- $_is_returning = true -}}
{{- (dict "r" (and $ok (get (fromJson (include "_shims.typeassertion" (dict "a" (list "bool" $b) ))) "r"))) | toJson -}}
{{- break -}}
Expand Down Expand Up @@ -169,18 +169,18 @@
{{- range $_ := (list 1) -}}
{{- $_is_returning := false -}}
{{- $values := $dot.Values.AsMap -}}
{{- $_441_dir_2_ok_3 := (get (fromJson (include "_shims.typetest" (dict "a" (list "string" (index $values.config.node "cloud_storage_cache_directory") "") ))) "r") -}}
{{- $dir_2 := (index $_441_dir_2_ok_3 0) -}}
{{- $ok_3 := (index $_441_dir_2_ok_3 1) -}}
{{- $_434_dir_2_ok_3 := (get (fromJson (include "_shims.typetest" (dict "a" (list "string" (index $values.config.node "cloud_storage_cache_directory") "") ))) "r") -}}
{{- $dir_2 := (index $_434_dir_2_ok_3 0) -}}
{{- $ok_3 := (index $_434_dir_2_ok_3 1) -}}
{{- if $ok_3 -}}
{{- $_is_returning = true -}}
{{- (dict "r" $dir_2) | toJson -}}
{{- break -}}
{{- end -}}
{{- $tieredConfig := (get (fromJson (include "redpanda.Storage.GetTieredStorageConfig" (dict "a" (list $values.storage) ))) "r") -}}
{{- $_450_dir_4_ok_5 := (get (fromJson (include "_shims.typetest" (dict "a" (list "string" (index $tieredConfig "cloud_storage_cache_directory") "") ))) "r") -}}
{{- $dir_4 := (index $_450_dir_4_ok_5 0) -}}
{{- $ok_5 := (index $_450_dir_4_ok_5 1) -}}
{{- $_443_dir_4_ok_5 := (get (fromJson (include "_shims.typetest" (dict "a" (list "string" (index $tieredConfig "cloud_storage_cache_directory") "") ))) "r") -}}
{{- $dir_4 := (index $_443_dir_4_ok_5 0) -}}
{{- $ok_5 := (index $_443_dir_4_ok_5 1) -}}
{{- if $ok_5 -}}
{{- $_is_returning = true -}}
{{- (dict "r" $dir_4) | toJson -}}
Expand Down Expand Up @@ -280,9 +280,9 @@
{{- $result := (dict ) -}}
{{- $s := (toJson $t) -}}
{{- $tune := (fromJson $s) -}}
{{- $_676_m_ok := (get (fromJson (include "_shims.typetest" (dict "a" (list (printf "map[%s]%s" "string" "interface {}") $tune (coalesce nil)) ))) "r") -}}
{{- $m := (index $_676_m_ok 0) -}}
{{- $ok := (index $_676_m_ok 1) -}}
{{- $_669_m_ok := (get (fromJson (include "_shims.typetest" (dict "a" (list (printf "map[%s]%s" "string" "interface {}") $tune (coalesce nil)) ))) "r") -}}
{{- $m := (index $_669_m_ok 0) -}}
{{- $ok := (index $_669_m_ok 1) -}}
{{- if (not $ok) -}}
{{- $_is_returning = true -}}
{{- (dict "r" (dict )) | toJson -}}
Expand Down Expand Up @@ -418,9 +418,9 @@
{{- $seen := (dict ) -}}
{{- $deduped := (coalesce nil) -}}
{{- range $_, $item := $items -}}
{{- $_793___ok_6 := (get (fromJson (include "_shims.dicttest" (dict "a" (list $seen $item.key false) ))) "r") -}}
{{- $_ := (index $_793___ok_6 0) -}}
{{- $ok_6 := (index $_793___ok_6 1) -}}
{{- $_786___ok_6 := (get (fromJson (include "_shims.dicttest" (dict "a" (list $seen $item.key false) ))) "r") -}}
{{- $_ := (index $_786___ok_6 0) -}}
{{- $ok_6 := (index $_786___ok_6 1) -}}
{{- if $ok_6 -}}
{{- continue -}}
{{- end -}}
Expand Down Expand Up @@ -473,9 +473,9 @@
{{- $name := (index .a 1) -}}
{{- range $_ := (list 1) -}}
{{- $_is_returning := false -}}
{{- $_884_cert_ok := (get (fromJson (include "_shims.dicttest" (dict "a" (list $m $name (dict "enabled" (coalesce nil) "caEnabled" false "applyInternalDNSNames" (coalesce nil) "duration" "" "issuerRef" (coalesce nil) "secretRef" (coalesce nil) "clientSecretRef" (coalesce nil) )) ))) "r") -}}
{{- $cert := (index $_884_cert_ok 0) -}}
{{- $ok := (index $_884_cert_ok 1) -}}
{{- $_877_cert_ok := (get (fromJson (include "_shims.dicttest" (dict "a" (list $m $name (dict "enabled" (coalesce nil) "caEnabled" false "applyInternalDNSNames" (coalesce nil) "duration" "" "issuerRef" (coalesce nil) "secretRef" (coalesce nil) "clientSecretRef" (coalesce nil) )) ))) "r") -}}
{{- $cert := (index $_877_cert_ok 0) -}}
{{- $ok := (index $_877_cert_ok 1) -}}
{{- if (not $ok) -}}
{{- $_ := (fail (printf "Certificate %q referenced, but not found in the tls.certs map" $name)) -}}
{{- end -}}
Expand Down Expand Up @@ -1218,9 +1218,9 @@
{{- $result := (dict ) -}}
{{- range $k, $v := $c -}}
{{- if (not (empty $v)) -}}
{{- $_1718___ok_13 := (get (fromJson (include "_shims.asnumeric" (dict "a" (list $v) ))) "r") -}}
{{- $_ := ((index $_1718___ok_13 0) | float64) -}}
{{- $ok_13 := (index $_1718___ok_13 1) -}}
{{- $_1711___ok_13 := (get (fromJson (include "_shims.asnumeric" (dict "a" (list $v) ))) "r") -}}
{{- $_ := ((index $_1711___ok_13 0) | float64) -}}
{{- $ok_13 := (index $_1711___ok_13 1) -}}
{{- if $ok_13 -}}
{{- $_ := (set $result $k $v) -}}
{{- else -}}{{- if (kindIs "bool" $v) -}}
Expand All @@ -1246,9 +1246,9 @@
{{- $_is_returning := false -}}
{{- $result := (dict ) -}}
{{- range $k, $v := $c -}}
{{- $_1738_b_14_ok_15 := (get (fromJson (include "_shims.typetest" (dict "a" (list "bool" $v false) ))) "r") -}}
{{- $b_14 := (index $_1738_b_14_ok_15 0) -}}
{{- $ok_15 := (index $_1738_b_14_ok_15 1) -}}
{{- $_1731_b_14_ok_15 := (get (fromJson (include "_shims.typetest" (dict "a" (list "bool" $v false) ))) "r") -}}
{{- $b_14 := (index $_1731_b_14_ok_15 0) -}}
{{- $ok_15 := (index $_1731_b_14_ok_15 1) -}}
{{- if $ok_15 -}}
{{- $_ := (set $result $k $b_14) -}}
{{- continue -}}
Expand Down Expand Up @@ -1291,15 +1291,15 @@
{{- $config := (index .a 1) -}}
{{- range $_ := (list 1) -}}
{{- $_is_returning := false -}}
{{- $_1783___hasAccessKey := (get (fromJson (include "_shims.dicttest" (dict "a" (list $config "cloud_storage_access_key" (coalesce nil)) ))) "r") -}}
{{- $_ := (index $_1783___hasAccessKey 0) -}}
{{- $hasAccessKey := (index $_1783___hasAccessKey 1) -}}
{{- $_1784___hasSecretKey := (get (fromJson (include "_shims.dicttest" (dict "a" (list $config "cloud_storage_secret_key" (coalesce nil)) ))) "r") -}}
{{- $_ := (index $_1784___hasSecretKey 0) -}}
{{- $hasSecretKey := (index $_1784___hasSecretKey 1) -}}
{{- $_1785___hasSharedKey := (get (fromJson (include "_shims.dicttest" (dict "a" (list $config "cloud_storage_azure_shared_key" (coalesce nil)) ))) "r") -}}
{{- $_ := (index $_1785___hasSharedKey 0) -}}
{{- $hasSharedKey := (index $_1785___hasSharedKey 1) -}}
{{- $_1776___hasAccessKey := (get (fromJson (include "_shims.dicttest" (dict "a" (list $config "cloud_storage_access_key" (coalesce nil)) ))) "r") -}}
{{- $_ := (index $_1776___hasAccessKey 0) -}}
{{- $hasAccessKey := (index $_1776___hasAccessKey 1) -}}
{{- $_1777___hasSecretKey := (get (fromJson (include "_shims.dicttest" (dict "a" (list $config "cloud_storage_secret_key" (coalesce nil)) ))) "r") -}}
{{- $_ := (index $_1777___hasSecretKey 0) -}}
{{- $hasSecretKey := (index $_1777___hasSecretKey 1) -}}
{{- $_1778___hasSharedKey := (get (fromJson (include "_shims.dicttest" (dict "a" (list $config "cloud_storage_azure_shared_key" (coalesce nil)) ))) "r") -}}
{{- $_ := (index $_1778___hasSharedKey 0) -}}
{{- $hasSharedKey := (index $_1778___hasSharedKey 1) -}}
{{- $envvars := (coalesce nil) -}}
{{- if (and (not $hasAccessKey) (get (fromJson (include "redpanda.SecretRef.IsValid" (dict "a" (list $tsc.accessKey) ))) "r")) -}}
{{- $envvars = (concat (default (list ) $envvars) (list (mustMergeOverwrite (dict "name" "" ) (dict "name" "REDPANDA_CLOUD_STORAGE_ACCESS_KEY" "valueFrom" (get (fromJson (include "redpanda.SecretRef.AsSource" (dict "a" (list $tsc.accessKey) ))) "r") )))) -}}
Expand All @@ -1322,12 +1322,12 @@
{{- $c := (index .a 0) -}}
{{- range $_ := (list 1) -}}
{{- $_is_returning := false -}}
{{- $_1821___containerExists := (get (fromJson (include "_shims.dicttest" (dict "a" (list $c "cloud_storage_azure_container" (coalesce nil)) ))) "r") -}}
{{- $_ := (index $_1821___containerExists 0) -}}
{{- $containerExists := (index $_1821___containerExists 1) -}}
{{- $_1822___accountExists := (get (fromJson (include "_shims.dicttest" (dict "a" (list $c "cloud_storage_azure_storage_account" (coalesce nil)) ))) "r") -}}
{{- $_ := (index $_1822___accountExists 0) -}}
{{- $accountExists := (index $_1822___accountExists 1) -}}
{{- $_1814___containerExists := (get (fromJson (include "_shims.dicttest" (dict "a" (list $c "cloud_storage_azure_container" (coalesce nil)) ))) "r") -}}
{{- $_ := (index $_1814___containerExists 0) -}}
{{- $containerExists := (index $_1814___containerExists 1) -}}
{{- $_1815___accountExists := (get (fromJson (include "_shims.dicttest" (dict "a" (list $c "cloud_storage_azure_storage_account" (coalesce nil)) ))) "r") -}}
{{- $_ := (index $_1815___accountExists 0) -}}
{{- $accountExists := (index $_1815___accountExists 1) -}}
{{- $_is_returning = true -}}
{{- (dict "r" (and $containerExists $accountExists)) | toJson -}}
{{- break -}}
Expand All @@ -1338,9 +1338,9 @@
{{- $c := (index .a 0) -}}
{{- range $_ := (list 1) -}}
{{- $_is_returning := false -}}
{{- $_1827_value_ok := (get (fromJson (include "_shims.dicttest" (dict "a" (list $c `cloud_storage_cache_size` (coalesce nil)) ))) "r") -}}
{{- $value := (index $_1827_value_ok 0) -}}
{{- $ok := (index $_1827_value_ok 1) -}}
{{- $_1820_value_ok := (get (fromJson (include "_shims.dicttest" (dict "a" (list $c `cloud_storage_cache_size` (coalesce nil)) ))) "r") -}}
{{- $value := (index $_1820_value_ok 0) -}}
{{- $ok := (index $_1820_value_ok 1) -}}
{{- if (not $ok) -}}
{{- $_is_returning = true -}}
{{- (dict "r" (coalesce nil)) | toJson -}}
Expand Down
7 changes: 0 additions & 7 deletions charts/redpanda/values.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,6 @@
// the Business Source License, use of this software will be governed
// by the Apache License, Version 2.0

// Use of this software is governed by the Business Source License
// included in the file licenses/BSL.md
//
// As of the Change Date specified in that file, in accordance with
// the Business Source License, use of this software will be governed
// by the Apache License, Version 2.0

// +gotohelm:filename=_values.go.tpl
package redpanda

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -993,6 +993,7 @@ type RPControllers struct {
Image *RedpandaImage `json:"image,omitempty"`
HealthProbeAddress *string `json:"healthProbeAddress,omitempty"`
MetricsAddress *string `json:"metricsAddress,omitempty"`
PProfAddress *string `json:"pprofAddress,omitempty"`
Run []string `json:"run,omitempty"`
CreateRBAC *bool `json:"createRBAC,omitempty"`
}
Expand Down
5 changes: 5 additions & 0 deletions operator/api/redpanda/v1alpha2/zz_generated.deepcopy.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 4 additions & 0 deletions operator/config/crd/bases/cluster.redpanda.com_redpandas.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19024,6 +19024,8 @@ spec:
type: object
metricsAddress:
type: string
pprofAddress:
type: string
resources:
description: ResourceRequirements describes the compute
resource requirements.
Expand Down Expand Up @@ -39273,6 +39275,8 @@ spec:
type: object
metricsAddress:
type: string
pprofAddress:
type: string
resources:
description: ResourceRequirements describes the compute
resource requirements.
Expand Down

0 comments on commit d96888f

Please sign in to comment.