Skip to content

Commit

Permalink
Upgrade calico and cilium
Browse files Browse the repository at this point in the history
  • Loading branch information
fjammes committed Oct 28, 2024
1 parent 5824d00 commit 514b700
Show file tree
Hide file tree
Showing 5 changed files with 24 additions and 7 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/e2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,10 @@ jobs:
kubectl get nodes
- name: Start nginx
run: |
./itest/run-nginx.sh
./e2e/run-nginx.sh
- name: Test nginx
run: |
./itest/test-nginx.sh
./e2e/test-nginx.sh
check_argo:
name: Check argoCD install
runs-on: ubuntu-22.04
Expand Down
4 changes: 1 addition & 3 deletions cmd/create.go
Original file line number Diff line number Diff line change
Expand Up @@ -84,9 +84,7 @@ func createCluster(clusterName string) {

switch c.Cni {
case "calico":
cmd = `kubectl create -f https://raw.githubusercontent.com/projectcalico/calico/v3.24.5/manifests/tigera-operator.yaml &&
kubectl create -f https://raw.githubusercontent.com/projectcalico/calico/v3.24.5/manifests/custom-resources.yaml`
_, _, err = ExecCmd(cmd, false)
_, _, err = ExecCmd(resources.CiliumInstallScript, false)
case "cilium":
_, _, err = ExecCmd(resources.CiliumInstallScript, false)

Expand Down
3 changes: 3 additions & 0 deletions resources/constants.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@ var ArgoCDInstallScript string
//go:embed install-argoworkflows.sh
var ArgoWorkflowInstallScript string

//go:embed install-calico.sh
var CalicoInstallScript string

//go:embed install-cilium.sh
var CiliumInstallScript string

Expand Down
17 changes: 17 additions & 0 deletions resources/install-calico.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
#!/bin/bash

# Install Cilium cli and CNI plugin

# @author Fabrice Jammes

set -euxo pipefail

# Install calico cni plugin
CALICO_VERSION="v3.28.2"

kubectl create -f https://raw.githubusercontent.com/projectcalico/calico/$CALICO_VERSION/manifests/tigera-operator.yaml
kubectl create -f https://raw.githubusercontent.com/projectcalico/calico/$CALICO_VERSION/manifests/custom-resources.yaml


echo "Wait for calico pods to be ready"
kubectl wait --for=condition=Ready pods --all -n calico-system --timeout=600s
3 changes: 1 addition & 2 deletions resources/install-cilium.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,9 @@ set -euxo pipefail
# Retrieve latest Cilium cli version with:
# curl -s https://raw.githubusercontent.com/cilium/cilium-cli/main/stable.txt)
CILIUM_CLI_VERSION="v0.16.4"
CILIUM_VERSION="1.15.2"
CILIUM_VERSION="1.16.3"

# Install cilium cli
CILIUM_VERSION="1.15.4"
CLI_ARCH=amd64
if [ "$(uname -m)" = "aarch64" ]; then CLI_ARCH=arm64; fi
curl -L --fail --remote-name-all https://github.com/cilium/cilium-cli/releases/download/${CILIUM_CLI_VERSION}/cilium-linux-${CLI_ARCH}.tar.gz{,.sha256sum}
Expand Down

0 comments on commit 514b700

Please sign in to comment.