Lightweight server monitoring with historical data, docker stats, and alerts.
fix(helm): publish immutable chart releases safely, maybe
henrygdc67b69d17e93
diff --git a/.github/workflows/release-please.yml b/.github/workflows/release-please.ymlindex e4ad5c712..e2e4965c6 100644--- a/.github/workflows/release-please.yml+++ b/.github/workflows/release-please.yml@@ -2,6 +2,11 @@ on:push:branches:- main+ paths:+ - ".github/workflows/release-please.yml"+ - "release-please-config.json"+ - ".release-please-manifest.json"+ - "supplemental/helm/**"permissions:contents: write@@ -61,6 +66,7 @@ jobs:if: ${{ needs.release.outputs.items_to_publish != '' && toJson(fromJson(needs.release.outputs.items_to_publish)) != '[]' }}strategy:fail-fast: false+ max-parallel: 1matrix:path: ${{ fromJSON(needs.release.outputs.items_to_publish) }}@@ -101,14 +107,10 @@ jobs:.tmp/cr package ${{ matrix.path }}ls -la .cr-release-packages/- - name: Upload binaries to release- uses: svenstaro/upload-release-action@v2- with:- repo_token: ${{ secrets.GITHUB_TOKEN }}- file: .cr-release-packages/*.tgz- file_glob: true- overwrite: true- tag: ${{ env.TAG }}+ - name: Upload chart package to draft release+ env:+ GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}+ run: gh release upload "$TAG" .cr-release-packages/*.tgz --clobber- name: Update indexrun: |@@ -122,3 +124,15 @@ jobs:# Generate index.yaml for GitHub Pagesargs=(-o "$owner" -r "$repo" -c "https://henrygd.github.io/beszel" --push -t "${{ secrets.CR_TOKEN }}" --index-path docs/index.yaml).tmp/cr index "${args[@]}"++ - name: Publish chart release+ env:+ GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}+ CHART_PATH: ${{ matrix.path }}+ run: |+ chart_name="${CHART_PATH##*/}"+ release_id=$(gh api "repos/${GITHUB_REPOSITORY}/releases/tags/${TAG}" --jq .id)+ gh api --method PATCH "repos/${GITHUB_REPOSITORY}/releases/${release_id}" \+ -f "name=Helm chart: ${chart_name} v${VERSION}" \+ -F draft=false \+ -f make_latest=falsediff --git a/release-please-config.json b/release-please-config.jsonindex c60bcbe18..069ad95ef 100644--- a/release-please-config.json+++ b/release-please-config.json@@ -8,7 +8,8 @@"changelog-path": "CHANGELOG.md","bump-minor-pre-major": true,"bump-patch-for-minor-pre-major": true,- "draft": false,+ "draft": true,+ "force-tag-creation": true,"prerelease": false},"supplemental/helm/beszel-hub": {@@ -17,7 +18,8 @@"changelog-path": "CHANGELOG.md","bump-minor-pre-major": true,"bump-patch-for-minor-pre-major": true,- "draft": false,+ "draft": true,+ "force-tag-creation": true,"prerelease": false}}diff --git a/supplemental/helm/beszel-agent/Chart.yaml b/supplemental/helm/beszel-agent/Chart.yamlindex ee501d3b9..be94952b1 100644--- a/supplemental/helm/beszel-agent/Chart.yaml+++ b/supplemental/helm/beszel-agent/Chart.yaml@@ -3,7 +3,7 @@ description: Installs beszel-agent in kuberneteshome: https://github.com/henrygd/beszel/tree/main/supplemental/helm/beszel-agentname: beszel-agentappVersion: "0.17.0"-# Do not touch will be updated during release+# This version is managed automatically by Release Please.version: 0.1.1sources:- https://github.com/henrygd/beszel/tree/main/supplemental/helm/beszel-agentdiff --git a/supplemental/helm/beszel-hub/Chart.yaml b/supplemental/helm/beszel-hub/Chart.yamlindex 7a5293c5c..6e9b6ef5e 100644--- a/supplemental/helm/beszel-hub/Chart.yaml+++ b/supplemental/helm/beszel-hub/Chart.yaml@@ -3,7 +3,7 @@ description: Installs beszel-hub in kuberneteshome: https://github.com/henrygd/beszel/tree/main/supplemental/helm/beszel-hubname: beszel-hubappVersion: "0.17.0"-# Do not touch will be updated during release+# This version is managed automatically by Release Please.version: 0.1.1sources:- https://github.com/henrygd/beszel/tree/main/supplemental/helm/beszel-hub