From c6f0b742de1d2d5e53d3d3341379b4584ebdc9c8 Mon Sep 17 00:00:00 2001 From: Victor Date: Sun, 22 May 2022 20:23:26 +0200 Subject: [PATCH] flux: added goldilocks + vpa --- flux/cluster/apps/kustomization.yaml | 1 + .../monitoring/goldilocks/helm-release.yaml | 22 +++++++++++++++++ .../monitoring/goldilocks/kustomization.yaml | 4 ++++ .../apps/monitoring/kustomization.yaml | 5 ++++ .../apps/monitoring/vpa/helm-release.yaml | 24 +++++++++++++++++++ .../apps/monitoring/vpa/kustomization.yaml | 4 ++++ .../charts/helm/fairwinds-charts.yaml | 9 +++++++ .../charts/helm/kustomization.yaml | 1 + flux/cluster/core/namespaces/monitoring.yaml | 5 ++++ 9 files changed, 75 insertions(+) create mode 100644 flux/cluster/apps/monitoring/goldilocks/helm-release.yaml create mode 100644 flux/cluster/apps/monitoring/goldilocks/kustomization.yaml create mode 100644 flux/cluster/apps/monitoring/kustomization.yaml create mode 100644 flux/cluster/apps/monitoring/vpa/helm-release.yaml create mode 100644 flux/cluster/apps/monitoring/vpa/kustomization.yaml create mode 100644 flux/cluster/base/flux-system/charts/helm/fairwinds-charts.yaml create mode 100644 flux/cluster/core/namespaces/monitoring.yaml diff --git a/flux/cluster/apps/kustomization.yaml b/flux/cluster/apps/kustomization.yaml index 3f6840a..a6b3f3f 100644 --- a/flux/cluster/apps/kustomization.yaml +++ b/flux/cluster/apps/kustomization.yaml @@ -5,3 +5,4 @@ resources: - presidential-paradise - authentik - gitops + - monitoring diff --git a/flux/cluster/apps/monitoring/goldilocks/helm-release.yaml b/flux/cluster/apps/monitoring/goldilocks/helm-release.yaml new file mode 100644 index 0000000..f1f94ff --- /dev/null +++ b/flux/cluster/apps/monitoring/goldilocks/helm-release.yaml @@ -0,0 +1,22 @@ +apiVersion: helm.toolkit.fluxcd.io/v2beta1 +kind: HelmRelease +metadata: + name: goldilocks + namespace: monitoring +spec: + interval: 5m + chart: + spec: + chart: goldilocks + version: 6.1.2 + sourceRef: + kind: HelmRepository + name: fairwinds-charts + namespace: flux-system + interval: 5m + timeout: 20m + values: + dashboard: + replicaCount: 1 + ingress: + enabled: false diff --git a/flux/cluster/apps/monitoring/goldilocks/kustomization.yaml b/flux/cluster/apps/monitoring/goldilocks/kustomization.yaml new file mode 100644 index 0000000..34a8531 --- /dev/null +++ b/flux/cluster/apps/monitoring/goldilocks/kustomization.yaml @@ -0,0 +1,4 @@ +apiVersion: kustomize.config.k8s.io/v1beta1 +kind: Kustomization +resources: + - helm-release.yaml diff --git a/flux/cluster/apps/monitoring/kustomization.yaml b/flux/cluster/apps/monitoring/kustomization.yaml new file mode 100644 index 0000000..c5206e7 --- /dev/null +++ b/flux/cluster/apps/monitoring/kustomization.yaml @@ -0,0 +1,5 @@ +apiVersion: kustomize.config.k8s.io/v1beta1 +kind: Kustomization +resources: + - vpa + - goldilocks diff --git a/flux/cluster/apps/monitoring/vpa/helm-release.yaml b/flux/cluster/apps/monitoring/vpa/helm-release.yaml new file mode 100644 index 0000000..79a0614 --- /dev/null +++ b/flux/cluster/apps/monitoring/vpa/helm-release.yaml @@ -0,0 +1,24 @@ +apiVersion: helm.toolkit.fluxcd.io/v2beta1 +kind: HelmRelease +metadata: + name: vpa + namespace: monitoring +spec: + interval: 5m + chart: + spec: + chart: vpa + version: 1.3.0 + sourceRef: + kind: HelmRepository + name: fairwinds-charts + namespace: flux-system + interval: 5m + timeout: 20m + values: + recommender: + enabled: true + updater: + enabled: false + admissionController: + enabled: false diff --git a/flux/cluster/apps/monitoring/vpa/kustomization.yaml b/flux/cluster/apps/monitoring/vpa/kustomization.yaml new file mode 100644 index 0000000..34a8531 --- /dev/null +++ b/flux/cluster/apps/monitoring/vpa/kustomization.yaml @@ -0,0 +1,4 @@ +apiVersion: kustomize.config.k8s.io/v1beta1 +kind: Kustomization +resources: + - helm-release.yaml diff --git a/flux/cluster/base/flux-system/charts/helm/fairwinds-charts.yaml b/flux/cluster/base/flux-system/charts/helm/fairwinds-charts.yaml new file mode 100644 index 0000000..a74526c --- /dev/null +++ b/flux/cluster/base/flux-system/charts/helm/fairwinds-charts.yaml @@ -0,0 +1,9 @@ +apiVersion: source.toolkit.fluxcd.io/v1beta1 +kind: HelmRepository +metadata: + name: fairwinds-charts + namespace: flux-system +spec: + interval: 15m + url: https://charts.fairwinds.com/stable + timeout: 3m diff --git a/flux/cluster/base/flux-system/charts/helm/kustomization.yaml b/flux/cluster/base/flux-system/charts/helm/kustomization.yaml index bf55245..5390dac 100644 --- a/flux/cluster/base/flux-system/charts/helm/kustomization.yaml +++ b/flux/cluster/base/flux-system/charts/helm/kustomization.yaml @@ -5,3 +5,4 @@ resources: - traefik-charts.yaml - external-secrets-charts.yaml - authentik-charts.yaml + - fairwinds-charts.yaml diff --git a/flux/cluster/core/namespaces/monitoring.yaml b/flux/cluster/core/namespaces/monitoring.yaml new file mode 100644 index 0000000..ff7ae1b --- /dev/null +++ b/flux/cluster/core/namespaces/monitoring.yaml @@ -0,0 +1,5 @@ +--- +apiVersion: v1 +kind: Namespace +metadata: + name: monitoring