mirror of
https://github.com/replicatedhq/troubleshoot.git
synced 2026-04-15 07:16:34 +00:00
56 lines
1.5 KiB
YAML
56 lines
1.5 KiB
YAML
name: release
|
|
|
|
on:
|
|
push:
|
|
tags:
|
|
- 'v*'
|
|
|
|
concurrency:
|
|
group: ${{ github.workflow }}-${{ github.ref }}
|
|
cancel-in-progress: false
|
|
|
|
jobs:
|
|
goreleaser:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Verify release branch
|
|
run: |
|
|
if [[ "${{ github.ref }}" != refs/heads/v1beta3 ]]; then
|
|
echo "::error::Releases can only be created from the v1beta3 branch"
|
|
echo "Current ref: ${{ github.ref }}"
|
|
exit 1
|
|
fi
|
|
- name: Checkout
|
|
uses: actions/checkout@v5
|
|
with:
|
|
fetch-depth: 0
|
|
|
|
- uses: azure/docker-login@v2
|
|
with:
|
|
username: ${{ secrets.DOCKERHUB_USER }}
|
|
password: ${{ secrets.DOCKERHUB_PASSWORD }}
|
|
|
|
- uses: actions/setup-go@v6
|
|
with:
|
|
go-version-file: 'go.mod'
|
|
|
|
- name: Run GoReleaser
|
|
uses: goreleaser/goreleaser-action@v6
|
|
with:
|
|
version: "v2.12.3"
|
|
args: release --clean --config deploy/.goreleaser.yaml
|
|
env:
|
|
GITHUB_TOKEN: ${{ secrets.HOMEBREW_GITHUB_TOKEN }}
|
|
|
|
- name: Update new preflight version in krew-index
|
|
if: ${{ !contains(github.ref_name, '-') }}
|
|
uses: rajatjindal/krew-release-bot@v0.0.47
|
|
with:
|
|
krew_template_file: deploy/krew/preflight.yaml
|
|
|
|
- name: Update new support-bundle version in krew-index
|
|
if: ${{ !contains(github.ref_name, '-') }}
|
|
uses: rajatjindal/krew-release-bot@v0.0.47
|
|
with:
|
|
krew_template_file: deploy/krew/support-bundle.yaml
|