Skip to content

0.0.1

0.0.1 #6

Workflow file for this run

name: Release workflow
on:
release:
types: [published]
permissions:
contents: write
jobs:
docker:
runs-on: ubuntu-latest
steps:
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Login to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build and push
uses: docker/build-push-action@v5
with:
push: true
platforms: linux/arm64/v8,linux/amd64
tags: fnxpt/cyclonedx-merge:latest,fnxpt/cyclonedx-merge:${{ github.ref_name }}
build:
runs-on: ubuntu-latest
strategy:
matrix:
# build and publish in parallel: linux/386, linux/amd64, linux/arm64, windows/386, windows/amd64, darwin/amd64, darwin/arm64
goos: [linux, darwin]
goarch: [amd64, arm64]
steps:
- uses: actions/checkout@v3
- uses: actions/setup-go@v4
with:
go-version: '^1.21.1' # The Go version to download (if necessary) and use.
- run: go build -o dist/cyclonedx-merge-${{ matrix.goos }}-${{ matrix.goarch }} .
env:
GOOS: ${{ matrix.goos }}
GOARCH: ${{ matrix.goarch }}
- name: Release
uses: fnkr/github-action-ghr@v1
env:
GHR_COMPRESS: gz
GHR_PATH: dist/cyclonedx-merge-${{ matrix.goos }}-${{ matrix.goarch }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}