Skip to content

Commit c3d5ef7

Browse files
committed
ci: return release
1 parent c6b52f9 commit c3d5ef7

File tree

3 files changed

+35
-70
lines changed

3 files changed

+35
-70
lines changed

.github/workflows/release.yml

Lines changed: 27 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -5,31 +5,31 @@ on:
55
- v*
66

77
jobs:
8-
# release:
9-
# runs-on: [ubuntu-latest]
10-
# steps:
11-
# - uses: actions/setup-go@v3
12-
# with: { go-version: 1.18 }
13-
#
14-
# - uses: actions/setup-node@v3
15-
# with: { node-version: '16' }
16-
#
17-
# - run: go install github.com/go-task/task/v3/cmd/task@latest
18-
#
19-
# - run: sudo apt update && sudo apt-get install rpm
20-
#
21-
# - uses: actions/checkout@v3
22-
#
23-
# - run: task deps
24-
#
25-
# - run: |
26-
# echo ${{ secrets.GPG_KEY }} | tr " " "\n" | base64 -d | gpg --import --batch
27-
# gpg --sign -u "58A7 CC3D 8A9C A2E5 BB5C 141D 4064 23EA F814 63CA" --pinentry-mode loopback --yes --batch --passphrase "${{ secrets.GPG_PASS }}" --output unlock.sig --detach-sign README.md
28-
# rm -f unlock.sig
29-
#
30-
# - run: git reset --hard
31-
#
32-
# - run: GITHUB_TOKEN=${{ secrets.GH_TOKEN }} task release:prod
8+
release:
9+
runs-on: [ubuntu-latest]
10+
steps:
11+
- uses: actions/setup-go@v3
12+
with: { go-version: 1.18 }
13+
14+
- uses: actions/setup-node@v3
15+
with: { node-version: '16' }
16+
17+
- run: go install github.com/go-task/task/v3/cmd/task@latest
18+
19+
- run: sudo apt update && sudo apt-get install rpm
20+
21+
- uses: actions/checkout@v3
22+
23+
- run: task deps
24+
25+
- run: |
26+
echo ${{ secrets.GPG_KEY }} | tr " " "\n" | base64 -d | gpg --import --batch
27+
gpg --sign -u "58A7 CC3D 8A9C A2E5 BB5C 141D 4064 23EA F814 63CA" --pinentry-mode loopback --yes --batch --passphrase "${{ secrets.GPG_PASS }}" --output unlock.sig --detach-sign README.md
28+
rm -f unlock.sig
29+
30+
- run: git reset --hard
31+
32+
- run: GITHUB_TOKEN=${{ secrets.GH_TOKEN }} task release:prod
3333

3434

3535
deploy-prod:
@@ -59,6 +59,6 @@ jobs:
5959
with:
6060
context: .
6161
platforms: linux/amd64,linux/arm64
62-
file: ./deployment/docker/prod/buildx.Dockerfile
62+
file: ./deployment/docker/prod/Dockerfile
6363
push: true
64-
tags: semaphoreui/semaphore:latest,semaphoreui/semaphore:${{ github.ref_name }}
64+
tags: semaphoreui/semaphore:latest,semaphoreui/semaphore:${{ github.ref_name }}

deployment/docker/prod/Dockerfile

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,17 @@
1+
ARG BUILDPLATFORM=linux/amd64
2+
13
# ansible-semaphore production image
2-
FROM golang:1.18.3-alpine3.16 as builder
4+
FROM --platform=$BUILDPLATFORM golang:1.18.3-alpine3.16 as builder
35

46

57
COPY ./ /go/src/github.com/ansible-semaphore/semaphore
68
WORKDIR /go/src/github.com/ansible-semaphore/semaphore
79

10+
ARG TARGETOS=linux
11+
ARG TARGETARCH=amd64
12+
ENV GOOS="${TARGETOS}"
13+
ENV GOARCH="${TARGETARCH}"
14+
815
RUN apk add --no-cache -U libc-dev curl nodejs npm git && \
916
./deployment/docker/prod/bin/install
1017

deployment/docker/prod/buildx.Dockerfile

Lines changed: 0 additions & 42 deletions
This file was deleted.

0 commit comments

Comments
 (0)