Skip to content

v3.1.3

v3.1.3 #68

Workflow file for this run

# This workflow will build the binary once a a new release tag occurs
name: release
on:
release:
types: [released]
jobs:
release-linux-amd64-to-bucket:
name: release linux/amd64 to bucket
runs-on: ubuntu-20.04
if: startsWith( github.ref, 'refs/tags/v')
env:
GCS_BUCKET: ${{ secrets.SIXNET_BINARIES_BUCKET }}
BINARY_VERSION: ${{ github.event.release.tag_name }}
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup - gcloud / gsutil
uses: google-github-actions/auth@v0
with:
credentials_json: ${{ secrets.SIXNET_BINARIES_SA_KEY }}
project_id: ${{ secrets.SIXNET_BINARIES_PROJECT }}
- name: Setup - golang
uses: actions/setup-go@v3
with:
go-version: 1.18.1
- name: Set up GCC & Make
run: sudo apt-get update && sudo apt-get install build-essential
- name: Download dependencies
run: go get github.com/thesixnetwork/sixnft@latest
- name: Build binary
run: make build
- name: Create binary folder
run: mkdir $BINARY_VERSION
- name: Copy binary to version folder
run: cp ./build/sixd ./$BINARY_VERSION/sixd
- name: Check architecture
run: go env GOOS GOARCH
- name: Binary Test Version
run: $BINARY_VERSION/sixd version
- name: Binary Test
run: $BINARY_VERSION/sixd
- name: Upload to cloud storage
uses: google-github-actions/upload-cloud-storage@v0
with:
path: ${{ github.event.release.tag_name }}
destination: ${{ secrets.SIXNET_BINARIES_BUCKET }}