feat(backend): 实例状态修改按信号模式处理集群状态 #2500 #8
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Auto Create Release | |
on: | |
push: | |
branches: | |
- "v[0-9]+.[0-9]+.[0-9]+" | |
paths: | |
- "helm-charts/bk-dbm/Chart.yaml" | |
jobs: | |
build: | |
runs-on: ubuntu-20.04 | |
steps: | |
- id: checkout | |
name: Checkout | |
uses: actions/checkout@v2 | |
- name: Get latest tag | |
id: latest-tag | |
run: | | |
git fetch --all --tags | |
LATEST_TAG=$(git describe --tags `git rev-list --tags --max-count=1`) | |
echo "latest_tag=$LATEST_TAG" >> $GITHUB_OUTPUT | |
- name: Run read-yaml action | |
id: yaml-data | |
uses: jbutcher5/read-yaml@main | |
with: | |
file: 'helm-charts/bk-dbm/Chart.yaml' | |
key-path: '["version"]' | |
- id: create-tag | |
name: Create tag | |
uses: actions/github-script@v6 | |
with: | |
script: | | |
// Create a lightweight tag | |
await github.rest.git.createRef({ | |
owner: context.repo.owner, | |
repo: context.repo.repo, | |
ref: 'refs/tags/${{ steps.yaml-data.outputs.data }}', | |
sha: context.sha | |
}); | |
- id: build-release-log | |
name: Build release log | |
uses: mikepenz/release-changelog-builder-action@v3.5.0 | |
with: | |
# 参考:https://github.com/mikepenz/release-changelog-builder-action | |
configuration: ".github/configuration.json" | |
commitMode: true | |
ignorePreReleases: false | |
fromTag: ${{ steps.latest-tag.outputs.latest_tag }} | |
toTag: ${{ steps.yaml-data.outputs.data }} | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
- id: create-release | |
name: Create release | |
uses: actions/create-release@latest | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
tag_name: ${{ steps.yaml-data.outputs.data }} | |
release_name: ${{ steps.yaml-data.outputs.data }} | |
body: ${{ steps.build-release-log.outputs.changelog }} | |
draft: false | |
prerelease: true |