Skip to content

build(deps): bump the k8s group across 4 directories with 8 updates #8949

build(deps): bump the k8s group across 4 directories with 8 updates

build(deps): bump the k8s group across 4 directories with 8 updates #8949

Workflow file for this run

# (C) Copyright Confidential Containers Contributors
# # SPDX-License-Identifier: Apache-2.0
#
# Build binary and run unit tests
---
name: build
on:
pull_request:
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
permissions: {}
jobs:
caa:
name: cloud-api-adaptor
runs-on: ${{ matrix.runner }}
strategy:
fail-fast: false
matrix:
type:
- dev
- release
runner:
- ubuntu-24.04
defaults:
run:
working-directory: src/cloud-api-adaptor
steps:
- name: Checkout the pull request code
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false
- name: Read properties from versions.yaml
run: |
go_version="$(yq '.tools.golang' versions.yaml)"
[ -n "$go_version" ]
echo "GO_VERSION=${go_version}" >> "$GITHUB_ENV"
- name: Setup Golang version ${{ env.GO_VERSION }}
uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e # v7.0.0
with:
go-version: ${{ env.GO_VERSION }}
cache-dependency-path: "**/go.sum"
cache: false
- name: Install build dependencies
if: matrix.type == 'dev'
run: |
sudo apt-get update -y
sudo apt-get install -y libvirt-dev
- name: Build
env:
BUILD_TYPE: ${{ matrix.type }}
run: |
# Build the binaries
if [ "${BUILD_TYPE}" == "release" ]; then
RELEASE_BUILD=true make build
else
RELEASE_BUILD=false make build
fi
- name: Test
if: matrix.type == 'dev'
run: |
go install github.com/jstemmer/go-junit-report@v1.0.0
export CI="true"
sudo -E env PATH="$PATH" make test | tee tests_report.txt
sudo chmod o+rw tests_report.txt
< tests_report.txt "$(go env GOPATH)/bin/go-junit-report" -set-exit-code > tests_report_junit.xml
shell: bash
- name: Upload tests report
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
if: matrix.type == 'dev'
with:
name: tests_report_junit-${{ matrix.runner }}_${{ env.GO_VERSION }}
path: ${{ github.workspace }}/tests_report_junit.xml
retention-days: 1
controllers:
name: controllers
runs-on: ubuntu-24.04
strategy:
fail-fast: false
matrix:
controller:
- peerpod-ctrl
defaults:
run:
working-directory: src/${{ matrix.controller }}
steps:
- name: Checkout the pull request code
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false
- name: Read properties from versions.yaml
run: |
go_version="$(yq '.tools.golang' ../cloud-api-adaptor/versions.yaml)"
[ -n "$go_version" ]
echo "GO_VERSION=${go_version}" >> "$GITHUB_ENV"
- name: Setup Golang version ${{ env.GO_VERSION }}
uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e # v7.0.0
with:
go-version: ${{ env.GO_VERSION }}
cache-dependency-path: "**/go.sum"
cache: false
- name: Install build dependencies
if: matrix.controller == 'peerpod-ctrl'
run: |
sudo apt-get update -y
sudo apt-get install -y libvirt-dev
- name: Verify go modules and manifests
run: make verify
- name: Build the controller manager
run: make build
- name: Run unit tests
run: make test
- name: Build the controller image
run: make docker-build
webhook:
name: webhook
runs-on: ubuntu-24.04
defaults:
run:
working-directory: src/webhook
steps:
- name: Checkout the pull request code
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false
- name: Read properties from versions.yaml
run: |
go_version="$(yq '.tools.golang' ../cloud-api-adaptor/versions.yaml)"
[ -n "$go_version" ]
echo "GO_VERSION=${go_version}" >> "$GITHUB_ENV"
- name: Setup Golang version ${{ env.GO_VERSION }}
uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e # v7.0.0
with:
go-version: ${{ env.GO_VERSION }}
cache-dependency-path: "**/go.sum"
cache: false
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@37fe631027851001ddb9b187196cc803df7f5f0e # v4.3.0
- name: Install kind
run: |
go install sigs.k8s.io/kind@v0.16.0
- name: Install bats
run: |
bats_version="$(yq '.tools.bats' ../cloud-api-adaptor/versions.yaml)"
[ -n "$bats_version" ]
git clone --branch "v${bats_version}" --single-branch \
https://github.com/bats-core/bats-core.git
cd bats-core
./install.sh ~/.local
- name: Verify go modules and manifests
run: make verify
- name: Build the webhook
run: make build
- name: Run unit tests and static checks
run: make test
- name: Run end-to-end tests
run: |
make test-e2e
cloud-provider:
name: cloud-provider
runs-on: ubuntu-24.04
defaults:
run:
working-directory: src/cloud-providers
steps:
- name: Checkout the pull request code
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false
- name: Read properties from versions.yaml
run: |
go_version="$(yq '.tools.golang' ../cloud-api-adaptor/versions.yaml)"
[ -n "$go_version" ]
echo "GO_VERSION=${go_version}" >> "$GITHUB_ENV"
- name: Setup Golang version ${{ env.GO_VERSION }}
uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e # v7.0.0
with:
go-version: ${{ env.GO_VERSION }}
cache-dependency-path: "**/go.sum"
cache: false
- name: Install build dependencies
run: |
sudo apt-get update -y
sudo apt-get install -y libvirt-dev
- name: Build , Run & Clean Tests
run: make all