mirror of
https://github.com/harivansh-afk/agentikube.git
synced 2026-04-15 05:02:07 +00:00
help release fix
This commit is contained in:
parent
165ac465e7
commit
081739b9a3
3 changed files with 21 additions and 54 deletions
12
.github/workflows/ci.yml
vendored
12
.github/workflows/ci.yml
vendored
|
|
@ -20,21 +20,15 @@ jobs:
|
|||
with:
|
||||
go-version-file: go.mod
|
||||
|
||||
- name: Setup Helm
|
||||
uses: azure/setup-helm@v4
|
||||
|
||||
- name: Build
|
||||
run: go build ./...
|
||||
|
||||
- name: Test
|
||||
run: go test ./...
|
||||
|
||||
helm-lint:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Setup Helm
|
||||
uses: azure/setup-helm@v4
|
||||
|
||||
- name: Helm lint
|
||||
run: helm lint chart/agentikube/
|
||||
|
||||
|
|
|
|||
45
.github/workflows/release-helm.yml
vendored
45
.github/workflows/release-helm.yml
vendored
|
|
@ -1,45 +0,0 @@
|
|||
name: Release Helm Chart
|
||||
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- "v*"
|
||||
|
||||
permissions:
|
||||
packages: write
|
||||
contents: read
|
||||
|
||||
env:
|
||||
REGISTRY: ghcr.io
|
||||
CHART_PATH: chart/agentikube
|
||||
|
||||
jobs:
|
||||
release:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Setup Helm
|
||||
uses: azure/setup-helm@v4
|
||||
|
||||
- name: Log in to GHCR
|
||||
run: echo "${{ secrets.GITHUB_TOKEN }}" | helm registry login ${{ env.REGISTRY }} -u ${{ github.actor }} --password-stdin
|
||||
|
||||
- name: Extract version from tag
|
||||
id: version
|
||||
run: echo "version=${GITHUB_REF_NAME#v}" >> "$GITHUB_OUTPUT"
|
||||
|
||||
- name: Set chart version
|
||||
run: |
|
||||
sed -i "s/^version:.*/version: ${{ steps.version.outputs.version }}/" ${{ env.CHART_PATH }}/Chart.yaml
|
||||
sed -i "s/^appVersion:.*/appVersion: \"${{ steps.version.outputs.version }}\"/" ${{ env.CHART_PATH }}/Chart.yaml
|
||||
|
||||
- name: Lint
|
||||
run: helm lint ${{ env.CHART_PATH }}/
|
||||
|
||||
- name: Package
|
||||
run: helm package ${{ env.CHART_PATH }}/ --destination .helm-pkg
|
||||
|
||||
- name: Push to GHCR
|
||||
run: helm push .helm-pkg/agentikube-${{ steps.version.outputs.version }}.tgz oci://${{ env.REGISTRY }}/${{ github.repository_owner }}
|
||||
18
.github/workflows/release.yml
vendored
18
.github/workflows/release.yml
vendored
|
|
@ -9,6 +9,7 @@ on:
|
|||
|
||||
permissions:
|
||||
contents: write
|
||||
packages: write
|
||||
|
||||
concurrency:
|
||||
group: release-${{ github.ref }}
|
||||
|
|
@ -29,6 +30,9 @@ jobs:
|
|||
with:
|
||||
go-version-file: go.mod
|
||||
|
||||
- name: Setup Helm
|
||||
uses: azure/setup-helm@v4
|
||||
|
||||
- name: Compute next version
|
||||
id: version
|
||||
shell: bash
|
||||
|
|
@ -93,3 +97,17 @@ jobs:
|
|||
name: ${{ steps.version.outputs.next_tag }}
|
||||
generate_release_notes: true
|
||||
files: dist/*
|
||||
|
||||
- name: Set chart version
|
||||
run: |
|
||||
sed -i "s/^version:.*/version: ${{ steps.version.outputs.version }}/" chart/agentikube/Chart.yaml
|
||||
sed -i "s/^appVersion:.*/appVersion: \"${{ steps.version.outputs.version }}\"/" chart/agentikube/Chart.yaml
|
||||
|
||||
- name: Package Helm chart
|
||||
run: helm package chart/agentikube/ --destination .helm-pkg
|
||||
|
||||
- name: Log in to GHCR
|
||||
run: echo "${{ secrets.GITHUB_TOKEN }}" | helm registry login ghcr.io -u ${{ github.actor }} --password-stdin
|
||||
|
||||
- name: Push Helm chart to GHCR
|
||||
run: helm push .helm-pkg/agentikube-${{ steps.version.outputs.version }}.tgz oci://ghcr.io/${{ github.repository_owner }}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue