57 lines
1.9 KiB
YAML
57 lines
1.9 KiB
YAML
|
name: Release
|
||
|
|
||
|
on:
|
||
|
push:
|
||
|
tags:
|
||
|
- '*'
|
||
|
|
||
|
jobs:
|
||
|
release:
|
||
|
name: Release
|
||
|
runs-on: ubuntu-latest
|
||
|
steps:
|
||
|
- uses: actions/checkout@v2
|
||
|
- name: Setup go
|
||
|
uses: actions/setup-go@v1
|
||
|
with:
|
||
|
go-version: '1.14.x'
|
||
|
- name: Create release artifacts
|
||
|
run: make release
|
||
|
- name: Create Github Release
|
||
|
id: create_release
|
||
|
uses: actions/create-release@v1
|
||
|
env:
|
||
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||
|
with:
|
||
|
tag_name: ${{ github.ref }}
|
||
|
release_name: ${{ github.ref }}
|
||
|
draft: false
|
||
|
prerelease: false
|
||
|
- name: Upload release artifacts (Mac OS amd64)
|
||
|
id: upload-release-asset
|
||
|
uses: actions/upload-release-asset@v1
|
||
|
env:
|
||
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||
|
with:
|
||
|
upload_url: ${{ steps.create_release.outputs.upload_url }}
|
||
|
asset_path: build/prometheus-jitsi-meet-exporter-${{ github.ref }}-darwin-amd64
|
||
|
asset_content_type: application/octet-stream
|
||
|
- name: Upload release artifacts (FreeBSD amd64)
|
||
|
id: upload-release-asset
|
||
|
uses: actions/upload-release-asset@v1
|
||
|
env:
|
||
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||
|
with:
|
||
|
upload_url: ${{ steps.create_release.outputs.upload_url }}
|
||
|
asset_path: build/prometheus-jitsi-meet-exporter-${{ github.ref }}-freebsd-amd64
|
||
|
asset_content_type: application/octet-stream
|
||
|
- name: Upload release artifacts (Linux amd64)
|
||
|
id: upload-release-asset
|
||
|
uses: actions/upload-release-asset@v1
|
||
|
env:
|
||
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||
|
with:
|
||
|
upload_url: ${{ steps.create_release.outputs.upload_url }}
|
||
|
asset_path: build/prometheus-jitsi-meet-exporter-${{ github.ref }}-freebsd-amd64
|
||
|
asset_content_type: application/octet-stream
|