fix(deps): update golang.org/x/exp digest to f9890c6 #247
Workflow file for this run
This file contains 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
on: | |
push: | |
paths-ignore: | |
- 'charts/**' | |
- 'manifests/**' | |
- 'docs/**' | |
- '/*.md' | |
- 'tests.rest' | |
branches: | |
- '*' | |
pull_request: | |
paths-ignore: | |
- 'manifests/**' | |
- 'charts/**' | |
- 'docs/**' | |
- '/*.md' | |
- 'tests.rest' | |
workflow_call: | |
env: | |
REGISTRY: ghcr.io | |
IMAGE_NAME: ${{ github.repository }} | |
name: Build and test | |
jobs: | |
test: | |
uses: ./.github/workflows/test.yml | |
trivy-scan: | |
uses: ./.github/workflows/trivy.yml | |
test-and-release-snapshot: | |
needs: | |
- trivy-scan | |
- test | |
permissions: | |
contents: read | |
packages: write | |
runs-on: ubuntu-latest | |
outputs: | |
docker_images: ${{ steps.docker_images.outputs.docker_images }} | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
with: | |
fetch-tags: true | |
fetch-depth: 0 | |
- name: Set up Go | |
uses: actions/setup-go@v5 | |
with: | |
go-version-file: './go.mod' | |
cache: true | |
id: go | |
# Workaround: https://github.com/docker/build-push-action/issues/461 | |
- name: Setup Docker buildx | |
uses: docker/setup-buildx-action@v3 | |
- name: Set SNAPSHOT_VERSION | |
run: | | |
echo "SNAPSHOT_VERSION=`echo ${{ github.ref_name }} | tr '/' '-'`" >> $GITHUB_ENV | |
- name: Run GoReleaser | |
uses: goreleaser/goreleaser-action@v6 | |
id: gorleaser | |
with: | |
version: "~> v2" | |
distribution: goreleaser | |
args: release --clean --snapshot | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
- name: set docker_images | |
id: docker_images | |
run: | | |
set -eux | |
cat dist/artifacts.json | |
DOCKER_IMAGES=`jq -r -c '[.[] | select(.type=="Docker Image") | .name]' dist/artifacts.json` | |
echo "docker_images=$DOCKER_IMAGES" >> "$GITHUB_OUTPUT" | |
- name: Log into registry ${{ env.REGISTRY }} | |
uses: docker/login-action@v3 | |
with: | |
registry: ${{ env.REGISTRY }} | |
username: ${{ github.actor }} | |
password: ${{ secrets.GITHUB_TOKEN }} | |
- name: Push images to registry | |
run: | | |
for image in `echo '${{ steps.docker_images.outputs.docker_images }}' | jq -r '.[]'`; do | |
docker push "$image" | |
done | |
scan: | |
name: "scan images with trivy" | |
needs: | |
- test-and-release-snapshot | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
docker_image: ${{ fromJSON(needs.test-and-release-snapshot.outputs.docker_images ) }} | |
steps: | |
- name: Log into registry ${{ env.REGISTRY }} | |
uses: docker/login-action@v3 | |
with: | |
registry: ${{ env.REGISTRY }} | |
username: ${{ github.actor }} | |
password: ${{ secrets.GITHUB_TOKEN }} | |
- name: Run Trivy vulnerability scanner in repo mode - non schedule & non master | |
uses: aquasecurity/trivy-action@master | |
with: | |
image-ref: ${{ matrix.docker_image }} | |
scan-type: 'image' | |
ignore-unfixed: true # we want to have full report | |
severity: 'CRITICAL,HIGH' #report all severities | |
exit-code: '1' | |
format: 'table' | |
chainsaw-e2e-snapshot: | |
uses: ./.github/workflows/chainsaw-test.yaml | |
needs: #TODO ucomment | |
- test-and-release-snapshot | |
strategy: | |
matrix: | |
IMAGE_TAG: ${{ fromJSON(needs.test-and-release-snapshot.outputs.docker_images ) }} | |