File tree 2 files changed +18
-1
lines changed
2 files changed +18
-1
lines changed Original file line number Diff line number Diff line change @@ -73,11 +73,20 @@ jobs:
73
73
tags : |
74
74
coderblvck/kpeek:latest
75
75
coderblvck/kpeek:${{ steps.bump_version.outputs.new_tag }}
76
+ build-args : |
77
+ KPEEK_VERSION=${{ steps.bump_version.outputs.new_tag }}
76
78
cache-from : type=registry,ref=coderblvck/kpeek:buildcache
77
79
cache-to : type=registry,ref=coderblvck/kpeek:buildcache,mode=max
78
80
secrets : |
79
81
GIT_AUTH_TOKEN=${{ secrets.ACCESS_TOKEN }}
80
82
83
+ # Upload the built binary as an artifact
84
+ - name : Upload kpeek binary
85
+ uses : actions/upload-artifact@v4
86
+ with :
87
+ name : kpeek-binary
88
+ path : kpeek
89
+
81
90
# Create GitHub Release.
82
91
- name : Create GitHub Release
83
92
if : ${{ success() }}
Original file line number Diff line number Diff line change 1
1
# Dockerfile
2
+ FROM golang:1.24-alpine AS builder
3
+ WORKDIR /app
4
+ COPY go.mod go.sum ./
5
+ RUN go mod download
6
+ COPY . .
7
+ RUN go build -ldflags "-X github.com/hacktivist123/kpeek/cmd.version=${KPEEK_VERSION}" -o kpeek .
8
+
2
9
FROM alpine:3.18
3
- COPY kpeek /usr/local/bin/kpeek
10
+ WORKDIR /app
11
+ COPY --from=builder /app/kpeek /usr/local/bin/kpeek
4
12
ENTRYPOINT ["kpeek" ]
You can’t perform that action at this time.
0 commit comments