From 600702578496008cfa40a1ca63601b78fbba61ca Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ciar=C3=A1n=20Carragher?= Date: Wed, 20 Nov 2024 16:09:52 +0000 Subject: [PATCH 1/4] Test prometheus patch on sbox --- .../kustomization.yaml | 11 +++++++++++ .../kube-prometheus-stack-crds-patch/kustomize.yaml | 7 +++++++ .../kustomize.yaml | 0 apps/monitoring/kube-prometheus-stack/sbox/00.yaml | 9 +++++++++ 4 files changed, 27 insertions(+) create mode 100644 apps/monitoring/kube-prometheus-stack-crds-patch/kustomization.yaml create mode 100644 apps/monitoring/kube-prometheus-stack-crds-patch/kustomize.yaml delete mode 100644 apps/monitoring/kube-prometheus-stack-crds-upgrade-v56/kustomize.yaml diff --git a/apps/monitoring/kube-prometheus-stack-crds-patch/kustomization.yaml b/apps/monitoring/kube-prometheus-stack-crds-patch/kustomization.yaml new file mode 100644 index 00000000000..61631e8747a --- /dev/null +++ b/apps/monitoring/kube-prometheus-stack-crds-patch/kustomization.yaml @@ -0,0 +1,11 @@ +apiVersion: kustomize.config.k8s.io/v1beta1 +kind: Kustomization +resources: + - https://raw.githubusercontent.com/prometheus-community/helm-charts/kube-prometheus-stack-66.2.1/charts/kube-prometheus-stack/charts/crds/crds/crd-alertmanagerconfigs.yaml + - https://raw.githubusercontent.com/prometheus-community/helm-charts/kube-prometheus-stack-66.2.1/charts/kube-prometheus-stack/charts/crds/crds/crd-alertmanagers.yaml + - https://raw.githubusercontent.com/prometheus-community/helm-charts/kube-prometheus-stack-66.2.1/charts/kube-prometheus-stack/charts/crds/crds/crd-podmonitors.yaml + - https://raw.githubusercontent.com/prometheus-community/helm-charts/kube-prometheus-stack-66.2.1/charts/kube-prometheus-stack/charts/crds/crds/crd-probes.yaml + - https://raw.githubusercontent.com/prometheus-community/helm-charts/kube-prometheus-stack-66.2.1/charts/kube-prometheus-stack/charts/crds/crds/crd-prometheuses.yaml + - https://raw.githubusercontent.com/prometheus-community/helm-charts/kube-prometheus-stack-66.2.1/charts/kube-prometheus-stack/charts/crds/crds/crd-prometheusrules.yaml + - https://raw.githubusercontent.com/prometheus-community/helm-charts/kube-prometheus-stack-66.2.1/charts/kube-prometheus-stack/charts/crds/crds/crd-servicemonitors.yaml + - https://raw.githubusercontent.com/prometheus-community/helm-charts/kube-prometheus-stack-66.2.1/charts/kube-prometheus-stack/charts/crds/crds/crd-thanosrulers.yaml \ No newline at end of file diff --git a/apps/monitoring/kube-prometheus-stack-crds-patch/kustomize.yaml b/apps/monitoring/kube-prometheus-stack-crds-patch/kustomize.yaml new file mode 100644 index 00000000000..b5a99351cc4 --- /dev/null +++ b/apps/monitoring/kube-prometheus-stack-crds-patch/kustomize.yaml @@ -0,0 +1,7 @@ +apiVersion: kustomize.toolkit.fluxcd.io/v1 +kind: Kustomization +metadata: + name: prometheus-crd + namespace: flux-system +spec: + path: ./apps/monitoring/kube-prometheus-stack-crds-patch \ No newline at end of file diff --git a/apps/monitoring/kube-prometheus-stack-crds-upgrade-v56/kustomize.yaml b/apps/monitoring/kube-prometheus-stack-crds-upgrade-v56/kustomize.yaml deleted file mode 100644 index e69de29bb2d..00000000000 diff --git a/apps/monitoring/kube-prometheus-stack/sbox/00.yaml b/apps/monitoring/kube-prometheus-stack/sbox/00.yaml index a230831a060..7a9429ac7e1 100644 --- a/apps/monitoring/kube-prometheus-stack/sbox/00.yaml +++ b/apps/monitoring/kube-prometheus-stack/sbox/00.yaml @@ -5,6 +5,15 @@ metadata: name: kube-prometheus-stack namespace: monitoring spec: + chart: + spec: + chart: kube-prometheus-stack + # Update kube-prometheus-stack-crds/kustomization.yaml when updating this + version: 66.2.1 + sourceRef: + kind: HelmRepository + name: prometheus + namespace: monitoring values: kube-state-metrics: tolerations: From 2a10202a838473619b363f0d234327a81db4d04f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ciar=C3=A1n=20Carragher?= Date: Wed, 20 Nov 2024 16:15:48 +0000 Subject: [PATCH 2/4] fmt --- apps/monitoring/kube-prometheus-stack/sbox/00.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/monitoring/kube-prometheus-stack/sbox/00.yaml b/apps/monitoring/kube-prometheus-stack/sbox/00.yaml index 7a9429ac7e1..70d5eeb4c0c 100644 --- a/apps/monitoring/kube-prometheus-stack/sbox/00.yaml +++ b/apps/monitoring/kube-prometheus-stack/sbox/00.yaml @@ -8,7 +8,7 @@ spec: chart: spec: chart: kube-prometheus-stack - # Update kube-prometheus-stack-crds/kustomization.yaml when updating this + # update crds in kube-prometheus-stack-crds when changing this version version: 66.2.1 sourceRef: kind: HelmRepository From cae35f1cf4daa81812b2bbc3bc2c3f6e02602d90 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ciar=C3=A1n=20Carragher?= Date: Wed, 20 Nov 2024 16:20:05 +0000 Subject: [PATCH 3/4] Add CRD's to cluster --- clusters/sbox/00/kustomization.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/clusters/sbox/00/kustomization.yaml b/clusters/sbox/00/kustomization.yaml index 5b7eebf918e..b8339410cad 100644 --- a/clusters/sbox/00/kustomization.yaml +++ b/clusters/sbox/00/kustomization.yaml @@ -2,6 +2,7 @@ apiVersion: kustomize.config.k8s.io/v1beta1 kind: Kustomization resources: - ../base + - ../../../apps/monitoring/kube-prometheus-stack-crds-patch patches: - path: ../../../apps/flux-system/sbox/00/kustomize.yaml From 54f8f8edd8ea8b70c93f2e5307c538909dcee8e0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ciar=C3=A1n=20Carragher?= Date: Thu, 21 Nov 2024 10:32:33 +0000 Subject: [PATCH 4/4] Update to 66.2.1 --- .../kustomization.yaml | 11 ----------- .../kustomize.yaml | 7 ------- .../kustomization.yaml | 16 ++++++++-------- .../kube-prometheus-stack.yaml | 2 +- .../kube-prometheus-stack/sbox/00.yaml | 9 --------- clusters/sbox/00/kustomization.yaml | 1 - 6 files changed, 9 insertions(+), 37 deletions(-) delete mode 100644 apps/monitoring/kube-prometheus-stack-crds-patch/kustomization.yaml delete mode 100644 apps/monitoring/kube-prometheus-stack-crds-patch/kustomize.yaml diff --git a/apps/monitoring/kube-prometheus-stack-crds-patch/kustomization.yaml b/apps/monitoring/kube-prometheus-stack-crds-patch/kustomization.yaml deleted file mode 100644 index 61631e8747a..00000000000 --- a/apps/monitoring/kube-prometheus-stack-crds-patch/kustomization.yaml +++ /dev/null @@ -1,11 +0,0 @@ -apiVersion: kustomize.config.k8s.io/v1beta1 -kind: Kustomization -resources: - - https://raw.githubusercontent.com/prometheus-community/helm-charts/kube-prometheus-stack-66.2.1/charts/kube-prometheus-stack/charts/crds/crds/crd-alertmanagerconfigs.yaml - - https://raw.githubusercontent.com/prometheus-community/helm-charts/kube-prometheus-stack-66.2.1/charts/kube-prometheus-stack/charts/crds/crds/crd-alertmanagers.yaml - - https://raw.githubusercontent.com/prometheus-community/helm-charts/kube-prometheus-stack-66.2.1/charts/kube-prometheus-stack/charts/crds/crds/crd-podmonitors.yaml - - https://raw.githubusercontent.com/prometheus-community/helm-charts/kube-prometheus-stack-66.2.1/charts/kube-prometheus-stack/charts/crds/crds/crd-probes.yaml - - https://raw.githubusercontent.com/prometheus-community/helm-charts/kube-prometheus-stack-66.2.1/charts/kube-prometheus-stack/charts/crds/crds/crd-prometheuses.yaml - - https://raw.githubusercontent.com/prometheus-community/helm-charts/kube-prometheus-stack-66.2.1/charts/kube-prometheus-stack/charts/crds/crds/crd-prometheusrules.yaml - - https://raw.githubusercontent.com/prometheus-community/helm-charts/kube-prometheus-stack-66.2.1/charts/kube-prometheus-stack/charts/crds/crds/crd-servicemonitors.yaml - - https://raw.githubusercontent.com/prometheus-community/helm-charts/kube-prometheus-stack-66.2.1/charts/kube-prometheus-stack/charts/crds/crds/crd-thanosrulers.yaml \ No newline at end of file diff --git a/apps/monitoring/kube-prometheus-stack-crds-patch/kustomize.yaml b/apps/monitoring/kube-prometheus-stack-crds-patch/kustomize.yaml deleted file mode 100644 index b5a99351cc4..00000000000 --- a/apps/monitoring/kube-prometheus-stack-crds-patch/kustomize.yaml +++ /dev/null @@ -1,7 +0,0 @@ -apiVersion: kustomize.toolkit.fluxcd.io/v1 -kind: Kustomization -metadata: - name: prometheus-crd - namespace: flux-system -spec: - path: ./apps/monitoring/kube-prometheus-stack-crds-patch \ No newline at end of file diff --git a/apps/monitoring/kube-prometheus-stack-crds/kustomization.yaml b/apps/monitoring/kube-prometheus-stack-crds/kustomization.yaml index ea37b2be10f..90e8919e01a 100644 --- a/apps/monitoring/kube-prometheus-stack-crds/kustomization.yaml +++ b/apps/monitoring/kube-prometheus-stack-crds/kustomization.yaml @@ -1,11 +1,11 @@ apiVersion: kustomize.config.k8s.io/v1beta1 kind: Kustomization resources: - - https://raw.githubusercontent.com/prometheus-community/helm-charts/kube-prometheus-stack-61.9.0/charts/kube-prometheus-stack/charts/crds/crds/crd-alertmanagerconfigs.yaml - - https://raw.githubusercontent.com/prometheus-community/helm-charts/kube-prometheus-stack-61.9.0/charts/kube-prometheus-stack/charts/crds/crds/crd-alertmanagers.yaml - - https://raw.githubusercontent.com/prometheus-community/helm-charts/kube-prometheus-stack-61.9.0/charts/kube-prometheus-stack/charts/crds/crds/crd-podmonitors.yaml - - https://raw.githubusercontent.com/prometheus-community/helm-charts/kube-prometheus-stack-61.9.0/charts/kube-prometheus-stack/charts/crds/crds/crd-probes.yaml - - https://raw.githubusercontent.com/prometheus-community/helm-charts/kube-prometheus-stack-61.9.0/charts/kube-prometheus-stack/charts/crds/crds/crd-prometheuses.yaml - - https://raw.githubusercontent.com/prometheus-community/helm-charts/kube-prometheus-stack-61.9.0/charts/kube-prometheus-stack/charts/crds/crds/crd-prometheusrules.yaml - - https://raw.githubusercontent.com/prometheus-community/helm-charts/kube-prometheus-stack-61.9.0/charts/kube-prometheus-stack/charts/crds/crds/crd-servicemonitors.yaml - - https://raw.githubusercontent.com/prometheus-community/helm-charts/kube-prometheus-stack-61.9.0/charts/kube-prometheus-stack/charts/crds/crds/crd-thanosrulers.yaml + - https://raw.githubusercontent.com/prometheus-community/helm-charts/kube-prometheus-stack-66.2.1/charts/kube-prometheus-stack/charts/crds/crds/crd-alertmanagerconfigs.yaml + - https://raw.githubusercontent.com/prometheus-community/helm-charts/kube-prometheus-stack-66.2.1/charts/kube-prometheus-stack/charts/crds/crds/crd-alertmanagers.yaml + - https://raw.githubusercontent.com/prometheus-community/helm-charts/kube-prometheus-stack-66.2.1/charts/kube-prometheus-stack/charts/crds/crds/crd-podmonitors.yaml + - https://raw.githubusercontent.com/prometheus-community/helm-charts/kube-prometheus-stack-66.2.1/charts/kube-prometheus-stack/charts/crds/crds/crd-probes.yaml + - https://raw.githubusercontent.com/prometheus-community/helm-charts/kube-prometheus-stack-66.2.1/charts/kube-prometheus-stack/charts/crds/crds/crd-prometheuses.yaml + - https://raw.githubusercontent.com/prometheus-community/helm-charts/kube-prometheus-stack-66.2.1/charts/kube-prometheus-stack/charts/crds/crds/crd-prometheusrules.yaml + - https://raw.githubusercontent.com/prometheus-community/helm-charts/kube-prometheus-stack-66.2.1/charts/kube-prometheus-stack/charts/crds/crds/crd-servicemonitors.yaml + - https://raw.githubusercontent.com/prometheus-community/helm-charts/kube-prometheus-stack-66.2.1/charts/kube-prometheus-stack/charts/crds/crds/crd-thanosrulers.yaml diff --git a/apps/monitoring/kube-prometheus-stack/kube-prometheus-stack.yaml b/apps/monitoring/kube-prometheus-stack/kube-prometheus-stack.yaml index 03648cb6daa..ad441ef3f33 100644 --- a/apps/monitoring/kube-prometheus-stack/kube-prometheus-stack.yaml +++ b/apps/monitoring/kube-prometheus-stack/kube-prometheus-stack.yaml @@ -258,7 +258,7 @@ spec: spec: chart: kube-prometheus-stack # update crds in kube-prometheus-stack-crds when changing this version - version: 61.9.0 + version: 66.2.1 sourceRef: kind: HelmRepository name: prometheus diff --git a/apps/monitoring/kube-prometheus-stack/sbox/00.yaml b/apps/monitoring/kube-prometheus-stack/sbox/00.yaml index 70d5eeb4c0c..a230831a060 100644 --- a/apps/monitoring/kube-prometheus-stack/sbox/00.yaml +++ b/apps/monitoring/kube-prometheus-stack/sbox/00.yaml @@ -5,15 +5,6 @@ metadata: name: kube-prometheus-stack namespace: monitoring spec: - chart: - spec: - chart: kube-prometheus-stack - # update crds in kube-prometheus-stack-crds when changing this version - version: 66.2.1 - sourceRef: - kind: HelmRepository - name: prometheus - namespace: monitoring values: kube-state-metrics: tolerations: diff --git a/clusters/sbox/00/kustomization.yaml b/clusters/sbox/00/kustomization.yaml index b8339410cad..5b7eebf918e 100644 --- a/clusters/sbox/00/kustomization.yaml +++ b/clusters/sbox/00/kustomization.yaml @@ -2,7 +2,6 @@ apiVersion: kustomize.config.k8s.io/v1beta1 kind: Kustomization resources: - ../base - - ../../../apps/monitoring/kube-prometheus-stack-crds-patch patches: - path: ../../../apps/flux-system/sbox/00/kustomize.yaml