Skip to content

Commit

Permalink
Add a release job to automatically generate artifacts upon release
Browse files Browse the repository at this point in the history
  • Loading branch information
nbarrientos committed May 26, 2020
1 parent 83fdfe7 commit cc0f08b
Showing 1 changed file with 32 additions and 0 deletions.
32 changes: 32 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
on:
release:
types: [published]

name: Release
jobs:
release-linux-amd64:
name: release linux/amd64
runs-on: ubuntu-latest
steps:
- name: Set up Go 1.13
uses: actions/setup-go@v1
with:
go-version: 1.13
id: go
- name: Check out code into the Go module directory
uses: actions/checkout@v1
- name: Build
env:
GOOS: linux
CGO_ENABLED: 0
run: make
- name: Upload Release Asset
id: upload-release-asset
uses: actions/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: ./cryptowat_exporter
asset_name: cryptowat_exporter_${{ github.event.release.tag_name}}_linux_amd64
asset_content_type: application/binary

0 comments on commit cc0f08b

Please sign in to comment.