Skip to content

Commit

Permalink
Merge pull request #1 from OverOrion/axoflow-org
Browse files Browse the repository at this point in the history
Adjust for fork
  • Loading branch information
OverOrion authored Feb 14, 2024
2 parents a4aba56 + cb83bb2 commit e3710fd
Show file tree
Hide file tree
Showing 15 changed files with 39 additions and 722 deletions.
26 changes: 5 additions & 21 deletions .github/workflows/ci-goreleaser.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,21 +19,7 @@ jobs:
name: Check GoReleaser Configuration
strategy:
matrix:
GOOS: [linux, windows, darwin]
GOARCH: ["386", amd64, arm64, ppc64le, arm, s390x]
exclude:
- GOOS: darwin
GOARCH: "386"
- GOOS: darwin
GOARCH: s390x
- GOOS: windows
GOARCH: arm64
- GOOS: darwin
GOARCH: arm
- GOOS: windows
GOARCH: arm
- GOOS: windows
GOARCH: s390x
GOOS: [linux]
runs-on: ubuntu-20.04

steps:
Expand All @@ -45,7 +31,7 @@ jobs:
- name: Setup QEMU
uses: docker/setup-qemu-action@v3
with:
platforms: arm64,ppc64le,linux/arm/v7,s390x
platforms: arm64

- name: Setup Docker Buildx
uses: docker/setup-buildx-action@v3
Expand All @@ -62,10 +48,8 @@ jobs:
- name: Run GoReleaser
uses: goreleaser/goreleaser-action@v5
with:
distribution: goreleaser-pro
version: latest
args: --snapshot --clean --skip-sign --skip-sbom --timeout 2h --split
distribution: goreleaser
version: v1.24.0
args: --snapshot --clean --skip-sign --skip-sbom --timeout 2h
env:
GOOS: ${{ matrix.GOOS }}
GOARCH: ${{ matrix.GOARCH }}
GORELEASER_KEY: ${{ secrets.GORELEASER_KEY }}
100 changes: 13 additions & 87 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,24 +5,15 @@ on:
tags: ["v*"]

jobs:
prepare:
Release:
permissions:
id-token: write
packages: write
contents: write

strategy:
matrix:
GOOS: [linux, windows, darwin]
GOARCH: ["386", amd64, arm64, ppc64le, arm, s390x]
exclude:
- GOOS: darwin
GOARCH: "386"
- GOOS: darwin
GOARCH: s390x
- GOOS: windows
GOARCH: arm64
- GOOS: darwin
GOARCH: arm
- GOOS: windows
GOARCH: arm
- GOOS: windows
GOARCH: s390x
GOOS: [linux]
runs-on: ubuntu-20.04

steps:
Expand All @@ -34,7 +25,7 @@ jobs:

- uses: docker/setup-qemu-action@v3
with:
platforms: arm64,ppc64le,linux/arm/v7,s390x
platforms: arm64

- uses: docker/setup-buildx-action@v3

Expand All @@ -46,12 +37,6 @@ jobs:
- name: Generate distribution sources
run: make generate-sources

- name: Log into Docker.io
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}

- name: Login to GitHub Package Registry
uses: docker/login-action@v3
with:
Expand All @@ -64,75 +49,16 @@ jobs:
echo "sha_short=$(git rev-parse --short HEAD)" >> $GITHUB_ENV
- uses: goreleaser/goreleaser-action@v5
if: steps.cache.outputs.cache-hit != 'true' # do not run if cache hit
with:
distribution: goreleaser-pro
version: latest
args: release --clean --split --timeout 2h
distribution: goreleaser
version: v1.24.0
args: release --clean --timeout 2h
env:
GOOS: ${{ matrix.GOOS }}
GOARCH: ${{ matrix.GOARCH }}
GITHUB_TOKEN: ${{ secrets.GH_PAT }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
COSIGN_EXPERIMENTAL: true
GORELEASER_KEY: ${{ secrets.GORELEASER_KEY }}

- uses: actions/upload-artifact@v3
- uses: actions/upload-artifact@v4
with:
name: all-artifacts
path: dist/*/*

release:
name: Release
runs-on: ubuntu-20.04
needs: prepare

permissions:
id-token: write
packages: write
contents: write

steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0

- uses: sigstore/cosign-installer@v2

- uses: anchore/sbom-action/[email protected]

- uses: docker/setup-qemu-action@v3
with:
platforms: arm64,ppc64le,s390x

- uses: docker/setup-buildx-action@v3

- uses: actions/setup-go@v5
with:
go-version: '~1.21.7'
check-latest: true

- uses: actions/download-artifact@v3
with:
name: all-artifacts
path: dist

- name: Log into Docker.io
run: echo "${{ secrets.DOCKER_PASSWORD }}" | docker login -u ${{ secrets.DOCKER_USERNAME }} --password-stdin

- name: Login to GitHub Package Registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}

- uses: goreleaser/goreleaser-action@v5
if: steps.cache.outputs.cache-hit != 'true' # do not run if cache hit
with:
distribution: goreleaser-pro
version: latest
args: continue --merge --timeout 2h
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
COSIGN_EXPERIMENTAL: true
GORELEASER_KEY: ${{ secrets.GORELEASER_KEY }}
Loading

0 comments on commit e3710fd

Please sign in to comment.