Skip to content

Merge pull request #223 from dntosas/feat/bump-pkgs #42

Merge pull request #223 from dntosas/feat/bump-pkgs

Merge pull request #223 from dntosas/feat/bump-pkgs #42

Workflow file for this run

---
name: "Release"
on:
push:
tags:
- "v[0-9]+.[0-9]+.[0-9]+"
jobs:
build:
name: Create Release
runs-on: ubuntu-latest
steps:
- name: Set up Go
uses: actions/[email protected]
with:
go-version: '1.21.1'
- name: Checkout code
uses: actions/[email protected]
with:
fetch-depth: 0
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Login to GitHub Container Registry
uses: docker/login-action@v2
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
logout: false
- name: Install Cosign
uses: sigstore/[email protected]
with:
cosign-release: 'v2.0.0'
- name: Write Cosign signing key to disk
run: 'echo "$KEY" > cosign.key'
shell: bash
env:
KEY: ${{ secrets.COSIGN_PRIVATE_KEY }}
- name: Run GoReleaser
uses: goreleaser/goreleaser-action@v4
with:
args: release --clean --config .github/config/goreleaser.yaml
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
COSIGN_PASSWORD: ${{ secrets.COSIGN_PRIVATE_KEY }}
# - name: Sign container image with annotations from our environment
# run: |
# cosign sign --key cosign.key \
# -a "repo=${{ github.repository }}" \
# -a "workflow=${{ github.workflow }}" \
# -a "ref=${{ github.sha }}" \
# ghcr.io/dntosas/capi2argo-cluster-operator:${{ github.event.release.tag_name }}
# env:
# COSIGN_PASSWORD: ""