From bb79f53df3de01ba1886d07638018a8c1e3b1f9e Mon Sep 17 00:00:00 2001 From: Stefan Prodan Date: Tue, 5 Dec 2023 11:17:52 +0200 Subject: [PATCH] Install metrics-server in CI Signed-off-by: Stefan Prodan --- .github/workflows/test.yaml | 18 ++++++++++++++---- timoni/bundles/flux-metrics.cue | 17 +++++++++++++++++ 2 files changed, 31 insertions(+), 4 deletions(-) create mode 100644 timoni/bundles/flux-metrics.cue diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yaml index e11a720..0ec2faa 100644 --- a/.github/workflows/test.yaml +++ b/.github/workflows/test.yaml @@ -29,14 +29,24 @@ jobs: run: make timoni-push - name: Install Flux run: make flux-up + - name: Install metrics-server + run: timoni bundle apply -f timoni/bundles/flux-metrics.cue - name: Run kustomize install benchmark - run: KS=${{ matrix.RESOURCES }} timoni bundle apply -f timoni/bundles/flux-benchmark.cue --runtime-from-env --timeout=30m + run: | + KS=${{ matrix.RESOURCES }} timoni bundle apply -f timoni/bundles/flux-benchmark.cue --runtime-from-env --timeout=30m + kubectl -n flux-system top pods - name: Run kustomize upgrade benchmark - run: KS=${{ matrix.RESOURCES }} MCPU=2 timoni bundle apply -f timoni/bundles/flux-benchmark.cue --runtime-from-env --timeout=30m + run: | + KS=${{ matrix.RESOURCES }} MCPU=2 timoni bundle apply -f timoni/bundles/flux-benchmark.cue --runtime-from-env --timeout=30m + kubectl -n flux-system top pods - name: Run helm install benchmark - run: HR=${{ matrix.RESOURCES }} timoni bundle apply -f timoni/bundles/flux-benchmark.cue --runtime-from-env --timeout=30m + run: | + HR=${{ matrix.RESOURCES }} timoni bundle apply -f timoni/bundles/flux-benchmark.cue --runtime-from-env --timeout=30m + kubectl -n flux-system top pods - name: Run helm upgrade benchmark - run: HR=${{ matrix.RESOURCES }} MCPU=2 timoni bundle apply -f timoni/bundles/flux-benchmark.cue --runtime-from-env --timeout=30m + run: | + HR=${{ matrix.RESOURCES }} MCPU=2 timoni bundle apply -f timoni/bundles/flux-benchmark.cue --runtime-from-env --timeout=30m + kubectl -n flux-system top pods - name: Debug failure if: failure() run: | diff --git a/timoni/bundles/flux-metrics.cue b/timoni/bundles/flux-metrics.cue new file mode 100644 index 0000000..0e6bf52 --- /dev/null +++ b/timoni/bundles/flux-metrics.cue @@ -0,0 +1,17 @@ +bundle: { + apiVersion: "v1alpha1" + name: "flux-monitoring" + instances: { + "metrics-server": { + module: url: "oci://ghcr.io/stefanprodan/modules/flux-helm-release" + namespace: "monitoring" + values: { + repository: url: "https://kubernetes-sigs.github.io/metrics-server" + chart: name: "metrics-server" + helmValues: { + args: ["--kubelet-insecure-tls"] + } + } + } + } +}