mirror of
https://github.com/kata-containers/kata-containers.git
synced 2025-04-27 19:35:32 +00:00
This PR makes changes to remove steps to run scripts for preparing and cleaning the runner and instead use runner hooks env variables to manage them. Fixes: #9934 Signed-off-by: Amulyam24 <amulmek1@in.ibm.com>
78 lines
2.0 KiB
YAML
78 lines
2.0 KiB
YAML
name: CI | Run kubernetes tests on Power(ppc64le)
|
|
on:
|
|
workflow_call:
|
|
inputs:
|
|
registry:
|
|
required: true
|
|
type: string
|
|
repo:
|
|
required: true
|
|
type: string
|
|
tag:
|
|
required: true
|
|
type: string
|
|
pr-number:
|
|
required: true
|
|
type: string
|
|
commit-hash:
|
|
required: false
|
|
type: string
|
|
target-branch:
|
|
required: false
|
|
type: string
|
|
default: ""
|
|
|
|
jobs:
|
|
run-k8s-tests:
|
|
strategy:
|
|
fail-fast: false
|
|
matrix:
|
|
vmm:
|
|
- qemu
|
|
k8s:
|
|
- kubeadm
|
|
runs-on: k8s-ppc64le
|
|
env:
|
|
DOCKER_REGISTRY: ${{ inputs.registry }}
|
|
DOCKER_REPO: ${{ inputs.repo }}
|
|
DOCKER_TAG: ${{ inputs.tag }}
|
|
GH_PR_NUMBER: ${{ inputs.pr-number }}
|
|
GOPATH: ${{ github.workspace }}
|
|
KATA_HYPERVISOR: ${{ matrix.vmm }}
|
|
KUBERNETES: ${{ matrix.k8s }}
|
|
USING_NFD: "false"
|
|
TARGET_ARCH: "ppc64le"
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
with:
|
|
ref: ${{ inputs.commit-hash }}
|
|
fetch-depth: 0
|
|
|
|
- name: Rebase atop of the latest target branch
|
|
run: |
|
|
./tests/git-helper.sh "rebase-atop-of-the-latest-target-branch"
|
|
env:
|
|
TARGET_BRANCH: ${{ inputs.target-branch }}
|
|
|
|
- name: Install golang
|
|
run: |
|
|
./tests/install_go.sh -f -p
|
|
echo "/usr/local/go/bin" >> "$GITHUB_PATH"
|
|
|
|
- name: Prepare the runner for k8s cluster creation
|
|
run: bash "${HOME}/scripts/k8s_cluster_cleanup.sh"
|
|
|
|
- name: Create k8s cluster using kubeadm
|
|
run: bash "${HOME}/scripts/k8s_cluster_create.sh"
|
|
|
|
- name: Deploy Kata
|
|
timeout-minutes: 10
|
|
run: bash tests/integration/kubernetes/gha-run.sh deploy-kata-kubeadm
|
|
|
|
- name: Run tests
|
|
timeout-minutes: 30
|
|
run: bash tests/integration/kubernetes/gha-run.sh run-tests
|
|
|
|
- name: Delete cluster and post cleanup actions
|
|
run: bash "${HOME}/scripts/k8s_cluster_cleanup.sh"
|