File tree Expand file tree Collapse file tree 2 files changed +9
-5
lines changed
Expand file tree Collapse file tree 2 files changed +9
-5
lines changed Original file line number Diff line number Diff line change 77 build :
88 name : Build image
99 runs-on : ubuntu-latest
10+ permissions :
11+ contents : read
12+ packages : write
1013
1114 steps :
1215 - name : Checkout Repository
2023 uses : redhat-actions/buildah-build@v2
2124 with :
2225 image : saturn
23- tags : latest ${{ github.sha }} ${{ github.ref_name }}
26+ tags : latest ${{ github.sha }} ${{ github.ref_name.replace('/', '-') }}
2427 containerfiles : |
2528 ./Containerfile
2629
Original file line number Diff line number Diff line change @@ -2,15 +2,16 @@ FROM docker.io/golang:1.25-alpine3.22 AS buildStage
22
33WORKDIR /app
44
5+ COPY go.mod ./
6+ COPY go.sum ./
7+ RUN go mod download
58COPY types.go ./
69COPY timer.go ./
710COPY main.go ./
8- COPY go.mod ./
9- COPY go.sum ./
1011
11- RUN go build -o saturn
12+ RUN CGO_ENABLED=0 go build -trimpath -ldflags= '-s -w' -o saturn
1213
13- FROM docker.io/alpine:3.20
14+ FROM docker.io/alpine:3.22
1415
1516WORKDIR /opt
1617COPY --from=buildStage /app/saturn /opt/saturn
You can’t perform that action at this time.
0 commit comments