Skip to content

Commit

Permalink
Run release builds on all branches
Browse files Browse the repository at this point in the history
  • Loading branch information
jeffijoe committed Sep 6, 2024
1 parent 87b2232 commit 40f051a
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ permissions:
on:
push:
branches:
- main
- "**"
tags:
- 'v*'

Expand All @@ -21,6 +21,8 @@ jobs:
outputs:
tag: ${{ steps.compute.outputs.tag }}
docker_tags: ${{ steps.compute.outputs.docker_tags }}
push: ${{ startsWith(github.ref, 'refs/tags/v') || github.ref == 'refs/heads/main' }}

steps:
- name: "Compute Release Tag"
id: compute
Expand Down Expand Up @@ -79,7 +81,7 @@ jobs:
context: .
file: ./Dockerfile
platforms: linux/386,linux/amd64,linux/arm64
push: true
push: ${{ fromJSON(needs.tag.outputs.push) }}
tags: ${{ needs.tag.outputs.docker_tags }}

binary:
Expand Down Expand Up @@ -200,13 +202,15 @@ jobs:
- name: Upload Artifact
uses: actions/upload-artifact@v4
if: ${{ fromJSON(needs.tag.outputs.push) }}
with:
name: ${{ matrix.asset_name }}
path: ./target/${{ matrix.target }}/release/${{ matrix.artifact_name }}

- name: Archive Release
shell: bash
id: archive
if: ${{ fromJSON(needs.tag.outputs.push) }}
run: |
# Compress to zip or tar.gz based on the OS.
DEST="";
Expand Down

0 comments on commit 40f051a

Please sign in to comment.