From 0f39bac4b1edbc5e8eb8e6afc059d4806ca3abe4 Mon Sep 17 00:00:00 2001 From: Lance Ball Date: Fri, 17 Jul 2020 14:21:31 -0400 Subject: [PATCH] actions: add automated releases of faas binary --- .github/workflows/releases.yaml | 27 ++++++++++++++++++++++++--- 1 file changed, 24 insertions(+), 3 deletions(-) diff --git a/.github/workflows/releases.yaml b/.github/workflows/releases.yaml index c736495dc3..9a8c395fc5 100644 --- a/.github/workflows/releases.yaml +++ b/.github/workflows/releases.yaml @@ -8,6 +8,7 @@ on: jobs: build: + name: Build and Release Artifacts runs-on: ubuntu-latest steps: - uses: actions/checkout@v2 @@ -23,7 +24,27 @@ jobs: USER: ${{ secrets.QUAY_USERNAME }} PASS: ${{ secrets.QUAY_PASSWORD }} run: docker login -u "$USER" -p "$PASS" quay.io && make push + - name: Compress Release Binary + run: gzip ./faas + - name: Create Release + id: create_release + uses: actions/create-release@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + tag_name: ${{ github.ref }} + release_name: Release ${{ github.ref }} + draft: false + prerelease: false + - name: Upload Release Binary + uses: actions/upload-release-asset@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ steps.create_release.outputs.upload_url }} + asset_path: ./faas.gz + asset_name: faas.gz + asset_content_type: application/x-gzip - # TODO: make release - # - build cross-platform binaries - # - create a release with assets + # TODO: + # - build cross-platform binaries (make release)