mirror of
https://github.com/lukaszraczylo/helm-charts.git
synced 2026-12-06 12:04:08 +00:00
fix(release): serialise chart releases so the gh-pages push does not race (#1)
Two repository_dispatch releases pushed gh-pages together; the second was rejected with 'cannot lock ref ... expected ...'. Add a concurrency group and rebase before the push.
This commit is contained in:
@@ -25,6 +25,12 @@ on:
|
||||
permissions:
|
||||
contents: write
|
||||
|
||||
# Two chart releases used to push gh-pages at the same time and the second
|
||||
# lost the ref lock. Serialise them; the checkout then sees the previous push.
|
||||
concurrency:
|
||||
group: release-chart-gh-pages
|
||||
cancel-in-progress: false
|
||||
|
||||
jobs:
|
||||
release:
|
||||
runs-on: ubuntu-latest
|
||||
@@ -196,4 +202,5 @@ jobs:
|
||||
# Only add specific paths, not source-repo
|
||||
git add charts/ index.yaml README.md
|
||||
git diff --staged --quiet || git commit -m "Release ${{ steps.inputs.outputs.chart_name }} ${{ steps.inputs.outputs.version }}"
|
||||
git pull --rebase origin gh-pages
|
||||
git push origin gh-pages
|
||||
|
||||
Reference in New Issue
Block a user