Skip to content
Snippets Groups Projects
  1. Oct 19, 2022
  2. Aug 28, 2022
  3. Jul 25, 2022
  4. Jun 25, 2022
  5. May 19, 2022
  6. May 14, 2022
    • Sheogorath's avatar
      Upgrade calico to version 3.23.0 · 0f1af5de
      Sheogorath authored
      This patch Upgrades calico to version 3.23.0, which is a complicated
      endeavour since it switches the helm release namespaces from default to
      tigera-operator.
      
      Besides the regular upgrade tasks, this reqires some explicit adjusting
      of helm annotations and flux labels, in order to convince the cluster,
      that's how it always has been.
      
      The following tasks need to be done:
      
      Before you start
      ---
      
      Disable flux:
      
      ```
      kubectl scale deployment -n flux-system source-controller --replicas 0
      kubectl scale deployment -n flux-system helm-controller --replicas 0
      kubectl scale deployment -n flux-system kustomize-controller --replicas 0
      ```
      
      The upgrade
      ---
      
      Push/merge this patch. (!!!)
      
      Update helm release annotations:
      ```
      kubectl patch installation default --type=merge -p '{"metadata": {"annotations": {"meta.helm.sh/release-namespace": "tigera-operator"}}}'
      kubectl patch apiserver default --type=merge -p '{"metadata": {"annotations": {"meta.helm.sh/release-namespace": "tigera-operator"}}}'
      kubectl patch podsecuritypolicy tigera-operator --type=merge -p '{"metadata": {"annotations": {"meta.helm.sh/release-namespace": "tigera-operator"}}}'
      kubectl patch -n tigera-operator deployment tigera-operator --type=merge -p '{"metadata": {"annotations": {"meta.helm.sh/release-namespace": "tigera-operator"}}}'
      kubectl patch -n tigera-operator serviceaccount tigera-operator --type=merge -p '{"metadata": {"annotations": {"meta.helm.sh/release-namespace": "tigera-operator"}}}'
      kubectl patch clusterrole tigera-operator --type=merge -p '{"metadata": {"annotations": {"meta.helm.sh/release-namespace": "tigera-operator"}}}'
      kubectl patch clusterrolebinding tigera-operator tigera-operator --type=merge -p '{"metadata": {"annotations": {"meta.helm.sh/release-namespace": "tigera-operator"}}}'
      ```
      
      Patch flux labels:
      ```
      kubectl patch installation default --type=merge -p '{"metadata": {"labels": {"helm.toolkit.fluxcd.io/namespace": "tigera-operator"}}}'
      kubectl patch apiserver default --type=merge -p '{"metadata": {"labels": {"helm.toolkit.fluxcd.io/namespace": "tigera-operator"}}}'
      kubectl patch podsecuritypolicy tigera-operator --type=merge -p '{"metadata": {"labels": {"helm.toolkit.fluxcd.io/namespace": "tigera-operator"}}}'
      kubectl patch -n tigera-operator deployment tigera-operator --type=merge -p '{"metadata": {"labels": {"helm.toolkit.fluxcd.io/namespace": "tigera-operator"}}}'
      kubectl patch -n tigera-operator serviceaccount tigera-operator --type=merge -p '{"metadata": {"labels": {"helm.toolkit.fluxcd.io/namespace": "tigera-operator"}}}'
      kubectl patch clusterrole tigera-operator --type=merge -p '{"metadata": {"labels": {"helm.toolkit.fluxcd.io/namespace": "tigera-operator"}}}'
      kubectl patch clusterrolebinding tigera-operator tigera-operator --type=merge -p '{"metadata": {"labels": {"helm.toolkit.fluxcd.io/namespace": "tigera-operator"}}}'
      ```
      
      Remove flux labels from namespace:
      
      ```
      kubectl label namespace tigera-operator helm.toolkit.fluxcd.io/namespace-
      ```
      
      Get values:
      
      ```
      helm get values -n default calico > values.yaml
      ```
      
      Install calico:
      
      ```
      helm repo add projectcalico https://projectcalico.docs.tigera.io/charts
      helm install calico projectcalico/tigera-operator --version v3.23.0 --namespace tigera-operator --values values.yaml
      ```
      
      Migrate flux helmrelease:
      
      ```
      kubectl apply -n tigera-operator -f bootstrap/calico/release.yaml
      kubectl patch helmrelease calico --type=json -p="[{'op': 'remove', 'path': '/metadata/finalizers'}]" -n default
      kubectl delete helmrelease -n default calico
      ```
      
      Delete old helm install:
      
      ```
      kubectl delete secret -n default -l name=calico -l owner=helm
      ```
      
      Starting flux again
      ---
      
      ```
      kubectl scale deployment -n flux-system source-controller --replicas 1
      kubectl scale deployment -n flux-system helm-controller --replicas 1
      kubectl scale deployment -n flux-system kustomize-controller --replicas 1
      ```
      
      References:
      https://projectcalico.docs.tigera.io/archive/v3.23/release-notes/
      0f1af5de
  7. Apr 20, 2022
  8. Apr 16, 2022
  9. Mar 04, 2022
  10. Feb 06, 2022
  11. Feb 04, 2022
  12. Feb 03, 2022
    • Sheogorath's avatar
      fix(system-upgrades): Add temporary broad networkpolicy · a0aeb9bd
      Sheogorath authored
      This patch adds a broader networkpolicy for system-upgrades namespace,
      which should ensure network access within the namespace.
      a0aeb9bd
    • Sheogorath's avatar
      fix(kyverno): Remove kyverno from setup · 8a5ed52b
      Sheogorath authored
      It's the 3rd update of kyverno and each time, things break in minor
      version. This is no modi operandi for this setup. Things are supposed to
      be stable and solid to work with. Kyverno is too unstable for this
      use-case.
      
      This time the installation of the pods failed due to wrong deployment
      names. This is nothing we change or adjust.
      
      Further the removal doesn't have any major impact on the platform, since
      network policies are already deployed via gitops from the `shared/`
      directory.
      
      BREAKING CHANGE: Removing kyverno and related CRDs/APIs.
      8a5ed52b
  13. Feb 02, 2022
  14. Feb 01, 2022
  15. Jan 31, 2022
  16. Jan 17, 2022
  17. Jan 14, 2022
  18. Jan 10, 2022
  19. Jan 03, 2022
  20. Nov 05, 2021
  21. Oct 10, 2021
  22. Oct 09, 2021
Loading