Skip to content

Commit 95a03bb

Browse files
committed
fix: issues with mindthegap deplotment (#660)
**What problem does this PR solve?**: This adds trust-manager to allow us to use self hosted helm charts in mindthegap. See: kubernetes-sigs/cluster-api-addon-provider-helm#104 We can think about this in a couple of different parts: 1. Installing trust-manager and CRDs. We need to install trust manager so that we can create a certificate bundle with our self signed cert to caaph-controller-manager. We pull the CRDs separately because we are unable to use them in our templates because they aren't available at that time. See the comment in the script for more details. 2. Modifying CAAPH to use the bundle. This is done through a job it has a corresponding Service Account/Role/Role Binding. 3. Various little fixes. ie changing repository url and versions to using `v` I tested this by creating a docker cluster. The helm chart proxies use this value ```yaml - apiVersion: addons.cluster.x-k8s.io/v1alpha1 kind: HelmChartProxy metadata: creationTimestamp: "2024-05-14T23:41:09Z" finalizers: - helmchartproxy.addons.cluster.x-k8s.io generation: 1 name: node-feature-discovery-docker-cluster-cilium-helm-addon namespace: default ownerReferences: - apiVersion: cluster.x-k8s.io/v1beta1 kind: Cluster name: docker-cluster-cilium-helm-addon uid: e0e943e4-6d63-4d85-8d37-f63160ff93e3 resourceVersion: "3282" uid: e04b6b62-5f39-4528-87f7-5928d2afd4dd spec: chartName: node-feature-discovery clusterSelector: matchLabels: cluster.x-k8s.io/cluster-name: docker-cluster-cilium-helm-addon namespace: node-feature-discovery options: enableClientCache: false install: createNamespace: true timeout: 10m0s upgrade: maxHistory: 10 releaseName: node-feature-discovery repoURL: oci://mindthegap.mindthegap.svc/charts ``` **Which issue(s) this PR fixes**: Fixes # **How Has This Been Tested?**: <!-- Please describe the tests that you ran to verify your changes. Provide output from the tests and any manual steps needed to replicate the tests. --> **Special notes for your reviewer**: <!-- Use this to provide any additional information to the reviewers. This may include: - Best way to review the PR. - Where the author wants the most review attention on. - etc. -->
1 parent 18b7681 commit 95a03bb

File tree

9 files changed

+408
-29
lines changed

9 files changed

+408
-29
lines changed

charts/cluster-api-runtime-extensions-nutanix/templates/helm-config.yaml

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -10,35 +10,35 @@ data:
1010
cilium: |
1111
ChartName: cilium
1212
ChartVersion: 1.15.0
13-
RepositoryURL: oci://mindthegap.{{ .Release.Namespace }}.svc
13+
RepositoryURL: oci://mindthegap.{{ .Release.Namespace }}.svc/charts
1414
cluster-autoscaler: |
1515
ChartName: cluster-autoscaler
1616
ChartVersion: 9.37.0
17-
RepositoryURL: oci://mindthegap.{{ .Release.Namespace }}.svc
17+
RepositoryURL: oci://mindthegap.{{ .Release.Namespace }}.svc/charts
1818
metallb: |
1919
ChartName: metallb
2020
ChartVersion: v0.14.5
21-
RepositoryURL: oci://mindthegap.{{ .Release.Namespace }}.svc
21+
RepositoryURL: oci://mindthegap.{{ .Release.Namespace }}.svc/charts
2222
nfd: |
2323
ChartName: node-feature-discovery
24-
ChartVersion: v0.15.2
25-
RepositoryURL: oci://mindthegap.{{ .Release.Namespace }}.svc
24+
ChartVersion: 0.15.2
25+
RepositoryURL: oci://mindthegap.{{ .Release.Namespace }}.svc/charts
2626
nutanix-ccm: |
2727
ChartName: nutanix-cloud-provider
2828
ChartVersion: 0.3.3
29-
RepositoryURL: oci://mindthegap.{{ .Release.Namespace }}.svc
29+
RepositoryURL: oci://mindthegap.{{ .Release.Namespace }}.svc/charts
3030
nutanix-snapshot-csi: |
3131
ChartName: nutanix-csi-snapshot
3232
ChartVersion: 6.3.2
33-
RepositoryURL: oci://mindthegap.{{ .Release.Namespace }}.svc
33+
RepositoryURL: oci://mindthegap.{{ .Release.Namespace }}.svc/charts
3434
nutanix-storage-csi: |
3535
ChartName: nutanix-csi-storage
36-
ChartVersion: v3.0.0-beta.1912
37-
RepositoryURL: oci://mindthegap.{{ .Release.Namespace }}.svc
36+
ChartVersion: 3.0.0-beta.1912
37+
RepositoryURL: oci://mindthegap.{{ .Release.Namespace }}.svc/charts
3838
tigera-operator: |
3939
ChartName: tigera-operator
4040
ChartVersion: v3.26.4
41-
RepositoryURL: oci://mindthegap.{{ .Release.Namespace }}.svc
41+
RepositoryURL: oci://mindthegap.{{ .Release.Namespace }}.svc/charts
4242
kind: ConfigMap
4343
metadata:
4444
creationTimestamp: null

charts/cluster-api-runtime-extensions-nutanix/templates/helm-chart-svc.yaml renamed to charts/cluster-api-runtime-extensions-nutanix/templates/mindthegap.yaml

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
1-
# Copyright 2023 D2iQ, Inc. All rights reserved.
1+
# Copyright 2024 Nutanix. All rights reserved.
22
# SPDX-License-Identifier: Apache-2.0
3-
3+
# This file contains the manifests to run a mindthegap deployment which contains helm charts for our addons.
4+
# The pod is built via goreleaser with configuration from hack/addons.
5+
#
46
apiVersion: cert-manager.io/v1
57
kind: Issuer
68
metadata:
@@ -12,12 +14,12 @@ spec:
1214
apiVersion: cert-manager.io/v1
1315
kind: Certificate
1416
metadata:
15-
name: mindthegap-example-tls
17+
name: mindthegap-tls
1618
namespace: {{ .Release.Namespace }}
1719
spec:
1820
dnsNames:
19-
- mindthegap.default.svc
20-
- mindthegap.default.svc.cluster.local
21+
- mindthegap.{{ .Release.Namespace }}.svc
22+
- mindthegap.{{ .Release.Namespace }}.svc.cluster.local
2123
issuerRef:
2224
name: mindthegap-selfsigned
2325
kind: Issuer

0 commit comments

Comments
 (0)