Skip to content

Version 1.5.9 (Mainnet + Testnet + Stagenet) #2

Version 1.5.9 (Mainnet + Testnet + Stagenet)

Version 1.5.9 (Mainnet + Testnet + Stagenet) #2

Workflow file for this run

name: Publish Release
on:
release:
types: [published]
jobs:
publish-node-image:
name: Publish node image
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: '11'
cache: 'sbt'
- uses: sbt/setup-sbt@v1
- run: sbt --mem 4096 --batch ';buildTarballsForDocker;buildRIDERunnerForDocker'
- uses: docker/setup-buildx-action@v3
- uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USER }}
password: ${{ secrets.DOCKERHUB_PASSWORD }}
- id: meta-public
uses: docker/metadata-action@v5
with:
images: wavesplatform/wavesnode
flavor: latest=false
tags: |
type=match,pattern=v(.*),group=1
type=raw,value=latest,enable=${{ github.event.release.prerelease == false }}
- id: meta-private
uses: docker/metadata-action@v5
with:
images: wavesplatform/waves-private-node
flavor: latest=false
tags: |
type=ref,event=tag
type=raw,value=latest,enable=${{ github.event.release.prerelease == false }}
- id: meta-ride-runner
uses: docker/metadata-action@v5
with:
images: wavesplatform/ride-runner
flavor: latest=false
tags: |
type=match,pattern=v(.*),group=1
type=raw,value=latest,enable=${{ github.event.release.prerelease == false }}
- uses: docker/build-push-action@v5
with:
platforms: linux/amd64,linux/arm64
context: ./docker
push: true
pull: true
tags: ${{ steps.meta-public.outputs.tags }}
- uses: docker/build-push-action@v5
with:
platforms: linux/amd64,linux/arm64
context: ./docker/private
push: true
pull: true
tags: ${{ steps.meta-private.outputs.tags }}
build-args: |
NODE_TAG=${{ steps.meta-public.outputs.version }}
- uses: docker/build-push-action@v5
with:
context: ./ride-runner/docker
push: true
pull: true
tags: ${{ steps.meta-ride-runner.outputs.tags }}
publish-node-sbt-builder-image:
name: Publish node SBT builder image
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- id: extract-versions
run: |
echo "waves-version=$(cut -d\" -f2 version.sbt)" >> $GITHUB_OUTPUT
echo "sbt-version=$(cut -d= -f2 project/build.properties)" >> $GITHUB_OUTPUT
- uses: docker/setup-buildx-action@v3
- uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USER }}
password: ${{ secrets.DOCKERHUB_PASSWORD }}
- uses: docker/build-push-action@v5
with:
platforms: linux/amd64,linux/arm64
context: ./docker
file: ./docker/node-sbt-builder.Dockerfile
push: true
pull: true
tags: wavesplatform/node-sbt-builder:${{ steps.extract-versions.outputs.waves-version }}
build-args: |
WAVES_VERSION=${{ steps.extract-versions.outputs.waves-version }}
SBT_VERSION=${{ steps.extract-versions.outputs.sbt-version }}
publish-release-jars:
name: Publish jars to Sonatype
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- id: sbt-version
run: |
sbt_version=$(cut -d\" -f2 version.sbt)
echo "sbt_version=$sbt_version" >> "$GITHUB_OUTPUT"
- if: ${{ format('v{0}', steps.sbt-version.outputs.sbt_version) != github.ref_name }}
env:
SBT_VERSION: ${{ steps.sbt-version.outputs.sbt_version }}
RELEASE_VERSION: ${{ github.ref_name }}
run: |
echo "::error::Release version $RELEASE_VERSION does not match SBT version $SBT_VERSION"
exit 1
- uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: '11'
cache: 'sbt'
gpg-private-key: ${{ secrets.OSSRH_GPG_KEY }}
gpg-passphrase: ${{ secrets.OSSRH_GPG_PASSPHRASE }}
- uses: sbt/setup-sbt@v1
- name: Publish release jars
env:
SONATYPE_PASSWORD: ${{ secrets.OSSRH_PASSWORD }}
SONATYPE_USERNAME: ${{ secrets.OSSRH_USERNAME }}
PGP_PASSPHRASE: ${{ secrets.OSSRH_GPG_PASSPHRASE }}
run: |
sbt --mem 4096 --batch ";publishSigned;sonatypeBundleRelease"