mirror of
https://github.com/nosqlbench/nosqlbench.git
synced 2025-02-25 18:55:28 -06:00
backport auto pre-release on -rc branches
This commit is contained in:
parent
daea786c1f
commit
8cce0173ff
49
.github/workflows/release.yml
vendored
49
.github/workflows/release.yml
vendored
@ -10,7 +10,7 @@ jobs:
|
|||||||
runs-on: ubuntu-18.04
|
runs-on: ubuntu-18.04
|
||||||
steps:
|
steps:
|
||||||
|
|
||||||
- name: checkout repo
|
- name: checkout repo
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v2
|
||||||
|
|
||||||
- name: setup java
|
- name: setup java
|
||||||
@ -87,7 +87,8 @@ jobs:
|
|||||||
- name: prepare release
|
- name: prepare release
|
||||||
run: scripts/release-prepare.sh
|
run: scripts/release-prepare.sh
|
||||||
env:
|
env:
|
||||||
RELEASE_BRANCH_NAME: "main"
|
RELEASE_BRANCH_NAME: "main"
|
||||||
|
PRERELEASE_BRANCH_PATTERN: "-rc"
|
||||||
GIT_RELEASE_BOT_NAME: "nb-droid"
|
GIT_RELEASE_BOT_NAME: "nb-droid"
|
||||||
GIT_RELEASE_BOT_EMAIL: ${{ secrets.GIT_RELEASE_BOT_EMAIL }}
|
GIT_RELEASE_BOT_EMAIL: ${{ secrets.GIT_RELEASE_BOT_EMAIL }}
|
||||||
ACCESS_TOKEN: ${{ secrets.GITHUB_ACCESS_TOKEN }}
|
ACCESS_TOKEN: ${{ secrets.GITHUB_ACCESS_TOKEN }}
|
||||||
@ -103,7 +104,7 @@ jobs:
|
|||||||
- name: bundle integration test logs
|
- name: bundle integration test logs
|
||||||
run: |
|
run: |
|
||||||
pwd
|
pwd
|
||||||
ls -l
|
find nb
|
||||||
mkdir -p itlogs/nb
|
mkdir -p itlogs/nb
|
||||||
cp -R nb/logs itlogs/nb
|
cp -R nb/logs itlogs/nb
|
||||||
|
|
||||||
@ -138,22 +139,34 @@ jobs:
|
|||||||
mkdir staging
|
mkdir staging
|
||||||
cp nb/target/nb.jar nb/target/nb staging
|
cp nb/target/nb.jar nb/target/nb staging
|
||||||
|
|
||||||
- name: upload artifacts
|
- name: upload artifacts
|
||||||
uses: actions/upload-artifact@v1
|
uses: actions/upload-artifact@v1
|
||||||
with:
|
with:
|
||||||
name: binaries
|
name: binaries
|
||||||
path: staging
|
path: staging
|
||||||
|
|
||||||
- name: docker push
|
- name: select release type from branch name
|
||||||
uses: docker/build-push-action@v1
|
run: |
|
||||||
with:
|
current_branch=$(git rev-parse --abbrev-ref HEAD)
|
||||||
username: ${{ secrets.DOCKER_USERNAME }}
|
if [[ ${current_branch} == *"-rc"* ]]
|
||||||
password: ${{ secrets.DOCKER_PASSWORD }}
|
then
|
||||||
repository: nosqlbench/nosqlbench
|
echo "PRERELEASE=true" >> $GITHUB_ENV
|
||||||
tags: latest, ${{ env.RELEASE_VERSION }}
|
echo "DOCKER_TAGS='"${{ env.RELEASE_VERSION }}"'" >> $GITHUB_ENV
|
||||||
tag_with_ref: false
|
else
|
||||||
|
echo "PRERELEASE=false" >> $GITHUB_ENV
|
||||||
|
echo "DOCKER_TAGS='latest,"${{ env.RELEASE_VERSION }}"'" >> $GITHUB_ENV
|
||||||
|
fi
|
||||||
|
|
||||||
- name: bundle guidebook
|
- name: docker push
|
||||||
|
uses: docker/build-push-action@v1
|
||||||
|
with:
|
||||||
|
username: ${{ secrets.DOCKER_USERNAME }}
|
||||||
|
password: ${{ secrets.DOCKER_PASSWORD }}
|
||||||
|
repository: nosqlbench/nosqlbench
|
||||||
|
tags: ${{ env.DOCKER_TAGS }}
|
||||||
|
tag_with_ref: false
|
||||||
|
|
||||||
|
- name: bundle guidebook
|
||||||
run: mkdir guidebook && cp -R nb/target/guidebook guidebook
|
run: mkdir guidebook && cp -R nb/target/guidebook guidebook
|
||||||
|
|
||||||
- name: upload guidebook
|
- name: upload guidebook
|
||||||
@ -171,7 +184,7 @@ jobs:
|
|||||||
tag_name: ${{ env.RELEASE_TAGNAME }}
|
tag_name: ${{ env.RELEASE_TAGNAME }}
|
||||||
release_name: Release ${{ env.RELEASE_TAGNAME }}
|
release_name: Release ${{ env.RELEASE_TAGNAME }}
|
||||||
draft: false
|
draft: false
|
||||||
prerelease: false
|
prerelease: ${{ env.PRERELEASE }}
|
||||||
body: ${{ steps.prepare_summary.outputs.release_summary }}
|
body: ${{ steps.prepare_summary.outputs.release_summary }}
|
||||||
|
|
||||||
- name: upload nb.jar
|
- name: upload nb.jar
|
||||||
|
Loading…
Reference in New Issue
Block a user