Skip to content

feat: add a webhook to prevent eviction of pods on kosmos NotReady nodes #68

feat: add a webhook to prevent eviction of pods on kosmos NotReady nodes

feat: add a webhook to prevent eviction of pods on kosmos NotReady nodes #68

Workflow file for this run

name: CI
on:
push:
pull_request:
jobs:
golangci:
name: lint
runs-on: ubuntu-22.04
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Install Go
uses: actions/setup-go@v4
with:
go-version: '1.20'
- name: golint
uses: golangci/golangci-lint-action@v3
with:
version: v1.54.1
verify:
name: verify
runs-on: ubuntu-22.04
env:
GOPATH: ${{ github.workspace }}
WORKSPACE: ${{ github.workspace }}/src/github.com/kosmos-io/kosmos
defaults:
run:
working-directory: ${{ env.WORKSPACE }}
steps:
- name: Checkout code
uses: actions/checkout@v3
with:
path: ${{ env.WORKSPACE }}
- name: Install Go
uses: actions/setup-go@v4
with:
go-version: '1.20'
- run: hack/verify-vendor.sh
- run: hack/verify-codegen.sh
- run: hack/verify-crds.sh
build:
name: build
needs: verify
runs-on: ubuntu-22.04
steps:
- name: Checkout code
uses: actions/checkout@v3
with:
# https://github.com/actions/checkout#fetch-all-history-for-all-tags-and-branches
fetch-depth: 0
- name: Install Go
uses: actions/setup-go@v4
with:
go-version: '1.20'
- name: Compile
run: make all
test:
name: Unit test
needs: build
runs-on: ubuntu-22.04
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Install Go
uses: actions/setup-go@v4
with:
go-version: '1.20'
- run: make test
e2e:
name: E2e test
needs: build
runs-on: ubuntu-22.04
steps:
# Free up disk space on Ubuntu
- name: Free Disk Space (Ubuntu)
uses: jlumbroso/free-disk-space@main
with:
# this might remove tools that are actually needed, if set to "true" but frees about 6 GB
tool-cache: false
# all of these default to true, but feel free to set to "false" if necessary for your workflow
android: true
dotnet: true
haskell: true
large-packages: false
docker-images: false
swap-storage: false
- name: Checkout code
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Install Go
uses: actions/setup-go@v4
with:
go-version: '1.20'
- name: Prepare e2e env
run: ./hack/prepare-e2e.sh
- name: Run e2e test
run: ./hack/rune2e.sh
- name: Upload logs
uses: actions/upload-artifact@v3
if: failure()
with:
name: kosmos-e2e-logs-${{ github.run_id }}
path: ${{ github.workspace }}/e2e-test/logs-*