Skip to content

Commit

Permalink
ci: supporting riscv64
Browse files Browse the repository at this point in the history
  • Loading branch information
criyle committed Jul 21, 2023
1 parent 5d037c7 commit 185c73b
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 3 deletions.
13 changes: 12 additions & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ jobs:
goreleaser:
name: Goreleaser
runs-on: ubuntu-latest
if: ${{ contains(github.ref, 'v') }}
steps:
-
name: Checkout
Expand Down Expand Up @@ -39,13 +38,23 @@ jobs:
-
name: Run GoReleaser
uses: goreleaser/goreleaser-action@v3
if: ${{ contains(github.ref, 'v') }}
with:
# either 'goreleaser' (default) or 'goreleaser-pro'
distribution: goreleaser
version: latest
args: release --clean
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
-
name: Test GoReleaser
uses: goreleaser/goreleaser-action@v3
if: ${{ ! contains(github.ref, 'v') }}
with:
# either 'goreleaser' (default) or 'goreleaser-pro'
distribution: goreleaser
version: latest
args: release --snapshot --clean
build:
name: Build-${{ matrix.os }}-${{ matrix.GOARCH }}
runs-on: ${{ matrix.os }}
Expand All @@ -64,6 +73,8 @@ jobs:
GOARCH: "arm"
- os: ubuntu-latest
GOARCH: "arm64"
- os: ubuntu-latest
GOARCH: "riscv64"
- os: macos-latest
GOARCH: "arm64"
steps:
Expand Down
13 changes: 13 additions & 0 deletions .goreleaser.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ builds:
- amd64
- arm
- arm64
- riscv64
goarm:
- "6"
- "7"
Expand Down Expand Up @@ -82,17 +83,29 @@ dockers:
- "mount.yaml"
build_flag_templates:
- "--platform=linux/arm/v7"
# Debian is not supporting riscv64 on stable branch, skip it first
# - image_templates:
# - "criyle/executorserver:{{ .Tag }}-riscv64"
# use: buildx
# dockerfile: "Dockerfile.goreleaser"
# goarch: riscv64
# extra_files:
# - "mount.yaml"
# build_flag_templates:
# - "--platform=linux/riscv64"
docker_manifests:
- name_template: "criyle/executorserver:{{ .Tag }}"
image_templates:
- "criyle/executorserver:{{ .Tag }}-amd64"
- "criyle/executorserver:{{ .Tag }}-arm64"
- "criyle/executorserver:{{ .Tag }}-arm"
# - "criyle/executorserver:{{ .Tag }}-riscv64"
- name_template: "criyle/executorserver:latest"
image_templates:
- "criyle/executorserver:{{ .Tag }}-amd64"
- "criyle/executorserver:{{ .Tag }}-arm64"
- "criyle/executorserver:{{ .Tag }}-arm"
# - "criyle/executorserver:{{ .Tag }}-riscv64"
skip_push: auto
checksum:
name_template: "checksums.txt"
Expand Down
4 changes: 2 additions & 2 deletions Dockerfile.goreleaser
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ubuntu
FROM debian:latest
WORKDIR /opt
ENTRYPOINT [ "/opt/executorserver" ]
COPY executorserver mount.yaml /opt/
COPY executorserver mount.yaml /opt/

0 comments on commit 185c73b

Please sign in to comment.