Skip to content

Commit

Permalink
update release workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
hard-nett committed Mar 19, 2024
1 parent 3c3cc45 commit 3b10918
Showing 1 changed file with 26 additions and 28 deletions.
54 changes: 26 additions & 28 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -1,35 +1,33 @@
---
name: release binary
# This workflow creates a release using goreleaser
# via the 'make release' command.

name: Create release

on:
release:
types: [created]
workflow_dispatch:
inputs:
release_tag:
description: "The desired tag for the release (e.g. v0.1.0)."
required: true

permissions:
contents: write

jobs:
release-alpine-static:
permissions: write-all
runs-on: ubuntu-latest
release:
name: Create release
runs-on: buildjet-4vcpu-ubuntu-2204
steps:
- name: Checkout
- name: Check out repository code
uses: actions/checkout@v4

- name: Docker compose
run: STAKE_TOKEN="uterp" TIMEOUT_COMMIT=500ms docker-compose up -d

- name: Copy binary
run: docker cp terpd_node_1:/usr/bin/terpd ./terpd

- name: Save sha256 sum
run: sha256sum ./terpd > ./terpd_sha256.txt

- name: Release
uses: softprops/action-gh-release@v1
with:
token: ${{ github.token }}
files: |
terpd
terpd_sha256.txt
- name: Dump docker logs on failure
if: failure()
uses: jwalton/gh-docker-logs@v2
fetch-depth: 0
ref: ${{ github.event.inputs.release_tag }}
- name: Make release
run: |
make release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: 🧹 Clean release folder
run: |
sudo rm -rf dist

0 comments on commit 3b10918

Please sign in to comment.