Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bump Dependencies for MetalK8s 2.10 #3279

Closed
thomasdanan opened this issue Apr 9, 2021 · 2 comments · Fixed by #3362, #3360, #3363, #3364 or #3371
Closed

Bump Dependencies for MetalK8s 2.10 #3279

thomasdanan opened this issue Apr 9, 2021 · 2 comments · Fixed by #3362, #3360, #3363, #3364 or #3371
Assignees
Labels
kind:dependencies Pull requests that update a dependency file priority:urgent Any issue we should jump in as soon as possible topic:build Anything related to building steps

Comments

@thomasdanan
Copy link
Contributor

Component:

'build'

Why this is needed:

We didn't update dependencies such as Prometheus, Grafana, etc ... since branch 2.8. We want to always embed the latest fix, security fixes, or new features and do it before releasing the first patch version of a specific branch.

What should be done:

Check and update all dependencies and make sure we don't break anything ...

Implementation proposal (strongly recommended):

Test plan:

@thomasdanan thomasdanan added topic:build Anything related to building steps kind:dependencies Pull requests that update a dependency file labels Apr 9, 2021
@thomasdanan thomasdanan added this to the MetalK8s 2.9.0-alpha2 milestone Apr 9, 2021
@thomasdanan thomasdanan added the priority:urgent Any issue we should jump in as soon as possible label Apr 13, 2021
@gdemonet
Copy link
Contributor

Not sure if we'll have time to handle this before 2.9.0. We'll try at least to update K8s to the latest version here, and may postpone upgrading addons to a 2.10.

@TeddyAndrieux
Copy link
Collaborator

Kubernetes update for MetalK8s 2.9 - K8s 1.20.6 was done in #3311
Removed the milestone for the rest

@TeddyAndrieux TeddyAndrieux removed this from the MetalK8s 2.9.0 milestone Apr 22, 2021
@TeddyAndrieux TeddyAndrieux changed the title Bump Dependencies for MetalK8s 2.9 Bump Dependencies for MetalK8s 2.10 Apr 29, 2021
@alexandre-allard alexandre-allard self-assigned this May 7, 2021
alexandre-allard added a commit that referenced this issue May 7, 2021
We update the chart to the version 15.4.4

```
rm -rf charts/kube-prometheus-stack
helm repo add prometheus-community https://prometheus-community.github.io/helm-charts
helm repo update
helm fetch -d charts --untar prometheus-community/kube-prometheus-stack
```

Refs: #3279
alexandre-allard added a commit that referenced this issue May 7, 2021
We are using Jinja templated strings for some
values to be then rendered at runtime by Salt, but
it seems that helm templating is also interpreting
these tags, so we now escape them.

Refs: #3279
alexandre-allard added a commit that referenced this issue May 7, 2021
This was necessary because of a bug in the version
(7.3.1) shipped in the kube-prometheus-stack charts
we were using until now.
The Grafana version is now 7.5.5

Refs: #3279
alexandre-allard added a commit that referenced this issue May 7, 2021
This was used by previous kube-prometheus-stack
but it is no longer the case, so we remove it.

Refs: #3279
alexandre-allard added a commit that referenced this issue May 7, 2021
Bump images to reflect what is used in
kube-prometheus-stack chart in version 15.4.4

Refs: #3279
alexandre-allard added a commit that referenced this issue May 7, 2021
Version of the chart has been bump to 15.4.4, so
we need to regenerate this formula as follows:

```
./charts/render.py prometheus-operator \
  charts/kube-prometheus-stack.yaml \
  charts/kube-prometheus-stack/ \
  --namespace metalk8s-monitoring \
  --service-config grafana \
  metalk8s-grafana-config \
  metalk8s/addons/prometheus-operator/config/grafana.yaml \
  metalk8s-monitoring \
  --service-config prometheus \
  metalk8s-prometheus-config \
  metalk8s/addons/prometheus-operator/config/prometheus.yaml \
  metalk8s-monitoring \
  --service-config alertmanager \
  metalk8s-alertmanager-config \
  metalk8s/addons/prometheus-operator/config/alertmanager.yaml \
  metalk8s-monitoring \
  --service-config dex \
  metalk8s-dex-config \
  metalk8s/addons/dex/config/dex.yaml.j2 metalk8s-auth \
  --drop-prometheus-rules charts/drop-prometheus-rules.yaml \
  > salt/metalk8s/addons/prometheus-operator/deployed/chart.sls
```

Refs: #3279
alexandre-allard added a commit that referenced this issue May 7, 2021
Update the prometheus-adapter chart using:
```
rm -rf charts/prometheus-adapter/
helm repo add prometheus-community https://prometheus-community.github.io/helm-charts
helm repo update
helm fetch -d charts --untar prometheus-community/prometheus-adapter
```

Refs: #3279
alexandre-allard added a commit that referenced this issue May 7, 2021
We have bumped prometheus-adapter chart to version
2.12.2, so we need to re-render this formula as
follows:

```
./charts/render.py prometheus-adapter --namespace metalk8s-monitoring \
  charts/prometheus-adapter.yaml  charts/prometheus-adapter/ \
  > salt/metalk8s/addons/prometheus-adapter/deployed/chart.sls
```

Refs: #3279
alexandre-allard added a commit that referenced this issue May 7, 2021
Previous helm chart repository
https://grafana.github.io/loki/charts is now
deprecated, so we move to the new one.

Update fluent-bit chart using:
```
rm -rf charts/fluent-bit
helm repo add grafana https://grafana.github.io/helm-charts
helm repo update
helm fetch -d charts --untar grafana/fluent-bit
```

Refs: #3279
alexandre-allard added a commit that referenced this issue May 7, 2021
We have bump fluent-bit chart, so we need
to re-render this formula as follows:

```
./charts/render.py fluent-bit --namespace metalk8s-logging \
  --remove-manifest ConfigMap fluent-bit \
  charts/fluent-bit.yaml charts/fluent-bit/ \
  > salt/metalk8s/addons/logging/fluent-bit/deployed/chart.sls
```

Refs: #3279
alexandre-allard added a commit that referenced this issue May 7, 2021
Previous helm chart repository
https://grafana.github.io/loki/charts is now
deprecated, so we move to the new one.

Update loki chart using:
```
rm -rf charts/loki
helm repo add grafana https://grafana.github.io/helm-charts
helm repo update
helm fetch -d charts --untar grafana/loki
```

Refs: #3279
alexandre-allard added a commit that referenced this issue May 7, 2021
alexandre-allard added a commit that referenced this issue May 7, 2021
We have bump loki chart, so we need
to re-render this formula as follows:

```
./charts/render.py loki charts/loki.yaml charts/loki/ \
  --remove-manifest Secret loki \
  --namespace metalk8s-logging \
  --service-config loki metalk8s-loki-config \
                   metalk8s/addons/logging/loki/config/loki.yaml \
                   metalk8s-logging \
  > salt/metalk8s/addons/logging/loki/deployed/chart.sls
```

Refs: #3279
alexandre-allard added a commit that referenced this issue May 7, 2021
We need to regenerate these files as we bumped the
Prometheus Operator version.

The alerting & recording rules are generated using:
```
$ ./tools/rule_extractor/rule_extractor.py \
    -i <control-plane-ip> -p 8443 -t rules
```

Refs: #3279
@gdemonet gdemonet linked a pull request May 7, 2021 that will close this issue
alexandre-allard added a commit that referenced this issue May 11, 2021
We have bumped prometheus-adapter chart to version
2.12.2, so we need to re-render this formula as
follows:

```
./charts/render.py prometheus-adapter --namespace metalk8s-monitoring \
  charts/prometheus-adapter.yaml  charts/prometheus-adapter/ \
  > salt/metalk8s/addons/prometheus-adapter/deployed/chart.sls
```

Refs: #3279
alexandre-allard added a commit that referenced this issue May 11, 2021
Update the prometheus-adapter chart using:
```
rm -rf charts/prometheus-adapter/
helm repo add prometheus-community https://prometheus-community.github.io/helm-charts
helm repo update
helm fetch -d charts --untar prometheus-community/prometheus-adapter
```

Refs: #3279
alexandre-allard added a commit that referenced this issue May 11, 2021
We have bumped prometheus-adapter chart to version
2.12.2, so we need to re-render this formula as
follows:

```
./charts/render.py prometheus-adapter --namespace metalk8s-monitoring \
  charts/prometheus-adapter.yaml  charts/prometheus-adapter/ \
  > salt/metalk8s/addons/prometheus-adapter/deployed/chart.sls
```

Refs: #3279
alexandre-allard added a commit that referenced this issue May 11, 2021
We can not bump the chart version as it is no
longer supported and the new chart
(https://github.com/dexidp/helm-charts) does
not offer yet the full capabilities that we need:

- no HTTPS configuration in Ingress
- not possible to disable HTTP in Service/Deployment
- not possible to override checksum/config annotation
- ...

We then re-render the Salt formula:

```
./charts/render.py dex \
      --namespace metalk8s-auth charts/dex.yaml \
      --service-config dex metalk8s-dex-config \
      metalk8s/addons/dex/config/dex.yaml.j2 metalk8s-auth \
      --remove-manifest Secret dex \
      charts/dex/ > salt/metalk8s/addons/dex/deployed/chart.sls
```

Refs: #3279
alexandre-allard added a commit that referenced this issue May 11, 2021
Update Calico binaries from 3.17.0 to 3.18.3

Calico binaries sha256 updated from:
  https://github.com/projectcalico/cni-plugin/releases/tag/v3.18.3

Refs: #3279
alexandre-allard added a commit that referenced this issue May 11, 2021
Image bumped from v3.17.0 to v3.18.3.

Refs: #3279
alexandre-allard added a commit that referenced this issue May 11, 2021
Update Calico manifest from v3.17.0 to v3.18.3

Deployment manifest updated based on upstream from:
  https://docs.projectcalico.org/v3.18.3/manifests/calico.yaml

Refs: #3279
@alexandre-allard alexandre-allard linked a pull request May 11, 2021 that will close this issue
alexandre-allard added a commit that referenced this issue May 11, 2021
We update the chart to the version 15.4.4

```
rm -rf charts/kube-prometheus-stack
helm repo add prometheus-community https://prometheus-community.github.io/helm-charts
helm repo update
helm fetch -d charts --untar prometheus-community/kube-prometheus-stack
```

Refs: #3279
alexandre-allard added a commit that referenced this issue May 11, 2021
We are using Jinja templated strings for some
values to be then rendered at runtime by Salt, but
it seems that helm templating is also interpreting
these tags, so we now escape them.

Refs: #3279
alexandre-allard added a commit that referenced this issue May 11, 2021
This was necessary because of a bug in the version
(7.3.1) shipped in the kube-prometheus-stack charts
we were using until now.
The Grafana version is now 7.5.5

Refs: #3279
alexandre-allard added a commit that referenced this issue May 11, 2021
This was used by previous kube-prometheus-stack
but it is no longer the case, so we remove it.

Refs: #3279
alexandre-allard added a commit that referenced this issue May 11, 2021
Bump images to reflect what is used in
kube-prometheus-stack chart in version 15.4.4

Refs: #3279
alexandre-allard added a commit that referenced this issue May 11, 2021
Version of the chart has been bump to 15.4.4, so
we need to regenerate this formula as follows:

```
./charts/render.py prometheus-operator \
  charts/kube-prometheus-stack.yaml \
  charts/kube-prometheus-stack/ \
  --namespace metalk8s-monitoring \
  --service-config grafana \
  metalk8s-grafana-config \
  metalk8s/addons/prometheus-operator/config/grafana.yaml \
  metalk8s-monitoring \
  --service-config prometheus \
  metalk8s-prometheus-config \
  metalk8s/addons/prometheus-operator/config/prometheus.yaml \
  metalk8s-monitoring \
  --service-config alertmanager \
  metalk8s-alertmanager-config \
  metalk8s/addons/prometheus-operator/config/alertmanager.yaml \
  metalk8s-monitoring \
  --service-config dex \
  metalk8s-dex-config \
  metalk8s/addons/dex/config/dex.yaml.j2 metalk8s-auth \
  --drop-prometheus-rules charts/drop-prometheus-rules.yaml \
  > salt/metalk8s/addons/prometheus-operator/deployed/chart.sls
```

Refs: #3279
alexandre-allard added a commit that referenced this issue May 11, 2021
We need to regenerate these files as we bumped the
Prometheus Operator version.

The alerting & recording rules are generated using:
```
$ ./tools/rule_extractor/rule_extractor.py \
    -i <control-plane-ip> -p 8443 -t rules
```

Refs: #3279
alexandre-allard added a commit that referenced this issue May 11, 2021
Update Calico from 3.17.0 to 3.19.0

Calico binaries sha256 updated from:
  https://github.com/projectcalico/cni-plugin/releases/tag/v3.19.0

Images bumped with:
  docker.io/calico/node:v3.19.0
  docker.io/calico/kube-controllers:v3.19.0

Deployment manifest updated based on upstream from:
  https://docs.projectcalico.org/v3.19/manifests/calico.yaml

Refs: #3279
alexandre-allard added a commit that referenced this issue May 11, 2021
Update Calico from 3.17.0 to 3.19.0

Calico binaries sha256 updated from:
  https://github.com/projectcalico/cni-plugin/releases/tag/v3.19.0

Images bumped with:
  docker.io/calico/node:v3.19.0
  docker.io/calico/kube-controllers:v3.19.0

Deployment manifest updated based on upstream from:
  https://docs.projectcalico.org/v3.19/manifests/calico.yaml

Refs: #3279
alexandre-allard added a commit that referenced this issue May 11, 2021
Update nginx-ingress chart using:
```
rm -rf charts/nginx-ingress
helm repo add ingress-nginx https://kubernetes.github.io/ingress-nginx
helm repo update
helm fetch -d charts --untar ingress-nginx/ingress-nginx
```

Refs: #3279
alexandre-allard added a commit that referenced this issue May 11, 2021
Needed by the update of the helm charts to
version 3.30.0

Refs: #3279
alexandre-allard added a commit that referenced this issue May 11, 2021
Needed as we have bumped the Helm chart version
to 3.30.0, re-render using:

```
./charts/render.py ingress-nginx --namespace metalk8s-ingress \
  charts/ingress-nginx.yaml charts/ingress-nginx/ \
  > salt/metalk8s/addons/nginx-ingress/deployed/chart.sls
./charts/render.py ingress-nginx-control-plane --namespace metalk8s-ingress \
  charts/ingress-nginx-control-plane.yaml charts/ingress-nginx/ \
  > salt/metalk8s/addons/nginx-ingress-control-plane/deployed/chart.sls
```

Refs: #3279
alexandre-allard added a commit that referenced this issue May 12, 2021
Update Calico from 3.17.0 to 3.19.0

Calico binaries sha256 updated from:
  https://github.com/projectcalico/cni-plugin/releases/tag/v3.19.0

Images bumped with:
  docker.io/calico/node:v3.19.0
  docker.io/calico/kube-controllers:v3.19.0

Deployment manifest updated based on upstream from:
  https://docs.projectcalico.org/v3.19/manifests/calico.yaml

Refs: #3279
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment