2020-03-21 21:09:15 +01:00
|
|
|
name: Release
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
tags:
|
|
|
|
- '*'
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
release:
|
|
|
|
name: Release
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v2
|
|
|
|
- name: Setup go
|
2020-10-24 10:54:18 +02:00
|
|
|
uses: actions/setup-go@v2.1.3
|
2020-03-21 21:09:15 +01:00
|
|
|
with:
|
2021-02-18 09:13:38 +01:00
|
|
|
go-version: '1.16.x'
|
2020-03-21 21:09:15 +01:00
|
|
|
- name: Create release artifacts
|
|
|
|
run: make release
|
2020-03-21 21:19:32 +01:00
|
|
|
env:
|
|
|
|
GOPATH: ${{ github.workspace }}/go
|
2020-03-21 21:09:15 +01:00
|
|
|
- name: Create Github Release
|
|
|
|
id: create_release
|
2021-05-12 07:20:22 +02:00
|
|
|
uses: actions/create-release@v1.1.4
|
2020-03-21 21:09:15 +01:00
|
|
|
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)
|
2020-03-21 21:19:32 +01:00
|
|
|
id: upload-release-asset-mac
|
2020-03-21 21:09:15 +01:00
|
|
|
uses: actions/upload-release-asset@v1
|
|
|
|
env:
|
|
|
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
with:
|
|
|
|
upload_url: ${{ steps.create_release.outputs.upload_url }}
|
2020-03-21 21:19:32 +01:00
|
|
|
asset_path: build/prometheus-jitsi-meet-exporter-darwin-amd64
|
|
|
|
asset_name: prometheus-jitsi-meet-exporter-darwin-amd64
|
2020-03-21 21:09:15 +01:00
|
|
|
asset_content_type: application/octet-stream
|
|
|
|
- name: Upload release artifacts (FreeBSD amd64)
|
2020-03-21 21:19:32 +01:00
|
|
|
id: upload-release-asset-freebsd
|
2020-03-21 21:09:15 +01:00
|
|
|
uses: actions/upload-release-asset@v1
|
|
|
|
env:
|
|
|
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
with:
|
|
|
|
upload_url: ${{ steps.create_release.outputs.upload_url }}
|
2020-03-21 21:19:32 +01:00
|
|
|
asset_path: build/prometheus-jitsi-meet-exporter-freebsd-amd64
|
|
|
|
asset_name: prometheus-jitsi-meet-exporter-freebsd-amd64
|
2020-03-21 21:09:15 +01:00
|
|
|
asset_content_type: application/octet-stream
|
|
|
|
- name: Upload release artifacts (Linux amd64)
|
2020-03-21 21:19:32 +01:00
|
|
|
id: upload-release-asset-linux
|
2020-03-21 21:09:15 +01:00
|
|
|
uses: actions/upload-release-asset@v1
|
|
|
|
env:
|
|
|
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
with:
|
|
|
|
upload_url: ${{ steps.create_release.outputs.upload_url }}
|
2020-03-21 21:19:32 +01:00
|
|
|
asset_path: build/prometheus-jitsi-meet-exporter-linux-amd64
|
|
|
|
asset_name: prometheus-jitsi-meet-exporter-linux-amd64
|
2020-03-21 21:09:15 +01:00
|
|
|
asset_content_type: application/octet-stream
|
2020-03-21 22:30:41 +01:00
|
|
|
- name: Upload release artifacts (shasums)
|
|
|
|
id: upload-release-asset-sha512sums
|
|
|
|
uses: actions/upload-release-asset@v1
|
|
|
|
env:
|
|
|
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
with:
|
|
|
|
upload_url: ${{ steps.create_release.outputs.upload_url }}
|
|
|
|
asset_path: build/sha512sums.txt
|
|
|
|
asset_name: sha512sums.txt
|
|
|
|
asset_content_type: application/octet-stream
|