From faf7cd159322a0c9a157ff9975099129d04bfce4 Mon Sep 17 00:00:00 2001 From: Antonio Ojea Date: Thu, 10 Dec 2020 10:40:54 +0100 Subject: [PATCH] ci for images compatibility --- .github/workflows/compatibility.yml | 86 +++++++++++++++++++++++++++++ 1 file changed, 86 insertions(+) create mode 100644 .github/workflows/compatibility.yml diff --git a/.github/workflows/compatibility.yml b/.github/workflows/compatibility.yml new file mode 100644 index 0000000000..4118bba54d --- /dev/null +++ b/.github/workflows/compatibility.yml @@ -0,0 +1,86 @@ +name: Compatibility + +on: + workflow_dispatch: + pull_request: + branches: + - master + +jobs: + images: + name: Node Images + runs-on: ubuntu-latest + timeout-minutes: 30 + steps: + - name: Check out code into the Go module directory + uses: actions/checkout@v2 + + - name: Verify + run: make verify + + - name: Install kind from current repository + run: sudo make install INSTALL_DIR=/usr/local/bin + + - name: Checkout Kubernetes + uses: actions/checkout@v2 + with: + path: src/k8s.io/kubernetes + repository: kubernetes/kubernetes + ref: v1.20.0 + + - name: Install kubectl + run: | + curl -LO https://storage.googleapis.com/kubernetes-release/release/$(curl -s https://storage.googleapis.com/kubernetes-release/release/stable.txt)/bin/linux/amd64/kubectl + chmod +x ./kubectl + sudo mv ./kubectl /usr/local/bin/kubectl + + - name: Build kind node image from current repository + run: | + KUBE_PATH="${{ github.workspace }}/src/k8s.io/kubernetes" + kind build node-image --kube-root ${KUBE_PATH} --image node:test -v7 + + - name: Create cluster from current repository + run: | + kind create cluster --name kind-pr --wait 1m --image node:test -v7 --retain + + - name: Create cluster with last stable version + run: | + curl -Lo ./kind https://kind.sigs.k8s.io/dl/v0.9.0/kind-linux-amd64 + chmod +x ./kind + cat <