fix CVE-2025-22872 and CVE-2025-22871 #1883
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Precommit - Unit Tests | |
on: | |
pull_request: | |
branches: | |
- '*' | |
paths-ignore: | |
- 'docs/**' | |
- 'README.md' | |
- 'CHANGELOG.md' | |
- 'PROJECT' | |
- 'LICENSE' | |
- 'mesh-worker-service/README.md' | |
- 'tools/README.md' | |
jobs: | |
build: | |
name: unit-tests | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
go-version: [1.22.12, 1.24.2] | |
steps: | |
- name: Free Disk Space (Ubuntu) | |
uses: jlumbroso/free-disk-space@v1.3.0 | |
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: true | |
docker-images: true | |
swap-storage: true | |
- name: Set up Go | |
uses: actions/setup-go@v1 | |
with: | |
go-version: ${{ matrix.go-version }} | |
id: go | |
- name: Check out code into the Go module directory | |
uses: actions/checkout@v1 | |
- name: InstallKubebuilder | |
run: | | |
curl -L -o kubebuilder "https://github.com/kubernetes-sigs/kubebuilder/releases/download/v3.6.0/kubebuilder_linux_amd64" | |
chmod +x kubebuilder && mv kubebuilder /usr/local/bin/ | |
- name: InstallTool | |
run: | | |
wget -O - -q https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh| sh -s v1.64.7 | |
./bin/golangci-lint --version | |
- name: validate controller-gen | |
run: | | |
make manager | |
- name: BuildProject | |
run: | | |
go mod download | |
CGO_ENABLED=0 GOOS=linux GOARCH=amd64 GO111MODULE=on go build -a -o manager main.go | |
- name: CheckStyle | |
run: | | |
./bin/golangci-lint run -c ./.golangci.yml ./... | |
- name: Check License Header | |
run: | | |
go test license_test.go | |
- name: Get vertical-pod-autoscaler crd | |
run: | | |
wget https://raw.githubusercontent.com/kubernetes/autoscaler/master/vertical-pod-autoscaler/deploy/vpa-v1-crd-gen.yaml -O config/crd/bases/vpa-v1-crd.yaml | |
- name: Run unit test check | |
run: make test | |
- name: Run envtest for controller | |
run: make test-ginkgo |