Skip to content

Commit

Permalink
Add kube_version variable to ensure helm renders manifests correctly
Browse files Browse the repository at this point in the history
We need to set the kube_version helm parameter in order to ensure that
commodore will render the manifests for the correct kubernetes version

Signed-off-by: Nicolas Bigler <[email protected]>
  • Loading branch information
TheBigLee committed Sep 3, 2024
1 parent b597b3a commit 7e18cf9
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 0 deletions.
1 change: 1 addition & 0 deletions class/cert-manager.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ parameters:
helm_params:
name: cert-manager
namespace: ${cert_manager:namespace}
kube_version: ${cert_manager:kubernetes_version}
- output_path: cert-manager/
input_type: jsonnet
output_type: yaml
Expand Down
4 changes: 4 additions & 0 deletions class/defaults.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
parameters:
cert_manager:
namespace: syn-cert-manager

# Used when rendering the Helm chart
kubernetes_version: "1.27"

dns01-recursive-nameservers: "1.1.1.1:53"
charts:
cert-manager: v1.13.5
Expand Down
11 changes: 11 additions & 0 deletions docs/modules/ROOT/pages/references/parameters.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,17 @@ The namespace in which to install cert-manager.
The component always adds label `openshift.io/cluster-monitoring=true` to the namespace.
Additionally, if component `prometheus` is installed on the cluster, the component registers the namespace to be monitored through the default Prometheus stack managed by that component.

== `kubernetes_version`

[horizontal]
type:: string
default:: https://github.com/projectsyn/component-cert-manager/blob/master/class/defaults.yml[See `class/defaults.yml`]

The Kubernetes version to provide to `helm template` when rendering the Helm chart.
This parameter has no effect when `install_method` is set to `olm`.

TIP: Set this parameter to `${dynamic_facts:kubernetesVersion:major}.${dynamic_facts:kubernetesVersion.minor}` to use the cluster's reported Kubernetes version when rendering the Helm chart.

== `charts:cert-manager`

[horizontal]
Expand Down

0 comments on commit 7e18cf9

Please sign in to comment.