Skip to content

webhosting-operator: Update dependency go to v1.22.2 #236

webhosting-operator: Update dependency go to v1.22.2

webhosting-operator: Update dependency go to v1.22.2 #236

name: webhosting-operator
on:
push:
branches:
- main
tags:
- v*
paths:
- "webhosting-operator/**"
- ".github/workflows/webhosting-operator.yaml"
- "!**.md"
pull_request:
paths:
- "webhosting-operator/**"
- ".github/workflows/webhosting-operator.yaml"
jobs:
verify:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version-file: webhosting-operator/go.mod
cache-dependency-path: webhosting-operator/go.sum
- name: Verify
run: make -C webhosting-operator verify
images:
runs-on: ubuntu-latest
env:
# renovate: datasource=github-releases depName=ko-build/ko
KO_VERSION: v0.15.2
steps:
- uses: actions/checkout@v4
with:
# fetch all history so that git describe works (needed by hack/prepare-image-metadata.sh)
fetch-depth: 0
- uses: actions/setup-go@v5
with:
go-version-file: webhosting-operator/go.mod
cache-dependency-path: webhosting-operator/go.sum
- uses: ko-build/[email protected]
with:
version: ${{ env.KO_VERSION }}
- name: Prepare image metadata
id: meta
run: ./hack/prepare-image-metadata.sh
- name: ko build
run: |
set -ex
cd ./webhosting-operator
entrypoints=(
./cmd/experiment
./cmd/webhosting-operator
)
ko build --push=${{ github.event_name != 'pull_request' }} --sbom none --base-import-paths \
--tags "${{ steps.meta.outputs.tags }}" --image-label "${{ steps.meta.outputs.labels }}" \
--platform linux/amd64,linux/arm64 \
"${entrypoints[@]}"