Skip to content

Release snapshot

Release snapshot #576

---
# Release snapshot on CRON schedule or on demand.
name: Release snapshot
on:
workflow_dispatch: {}
schedule:
- cron: "0 0 * * *" # every night
env:
GO_VERSION: "1.17"
jobs:
release-snapshot:
name: Release unversioned snapshot
runs-on: ubuntu-20.04
env:
DOCKER_CLI_EXPERIMENTAL: "enabled"
steps:
- name: Set up QEMU
uses: docker/setup-qemu-action@v1
- name: Set up Docker Buildx
id: buildx
uses: docker/setup-buildx-action@v1
- name: Available platforms
run: echo ${{ steps.buildx.outputs.platforms }}
- name: Setup Go
uses: actions/setup-go@v2
with:
go-version: ${{ env.GO_VERSION }}
- name: Checkout code
uses: actions/checkout@v3
- uses: actions/cache@v3
with:
path: ~/go/pkg/mod
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
restore-keys: |
${{ runner.os }}-go-
- name: Release snapshot
uses: goreleaser/goreleaser-action@v2
with:
version: v1.7.0
args: release --snapshot --skip-publish --rm-dist
- name: Scan Starboard CLI image for vulnerabilities
uses: aquasecurity/trivy-action@master
with:
image-ref: 'docker.io/aquasec/starboard:${{ github.sha }}-amd64'
exit-code: '1'
ignore-unfixed: true
severity: 'CRITICAL,HIGH'
- name: Scan Starboard Operator image for vulnerabilities
uses: aquasecurity/trivy-action@master
with:
image-ref: 'docker.io/aquasec/starboard-operator:${{ github.sha }}-amd64'
exit-code: '1'
ignore-unfixed: true
severity: 'CRITICAL,HIGH'
- name: Scan Starboard Scanner Aqua image for vulnerabilities
uses: aquasecurity/trivy-action@master
with:
image-ref: 'docker.io/aquasec/starboard-scanner-aqua:${{ github.sha }}'
exit-code: '1'
ignore-unfixed: true
severity: 'CRITICAL,HIGH'