File tree 2 files changed +10
-10
lines changed
2 files changed +10
-10
lines changed Original file line number Diff line number Diff line change 58
58
id : buildx
59
59
uses : docker/setup-buildx-action@v1
60
60
- name : Login to DockerHub
61
- uses : docker/login-action@v1
61
+ uses : docker/login-action@v2
62
62
with :
63
- username : ${{ secrets.DOCKERHUB_USERNAME }}
63
+ username : jpillora
64
64
password : ${{ secrets.DOCKERHUB_TOKEN }}
65
65
- name : Docker meta
66
66
id : docker_meta
Original file line number Diff line number Diff line change 1
1
# build stage
2
- FROM golang:1.19 as build
3
- LABEL maintainer=
"[email protected] "
4
- ENV CGO_ENABLED 0
2
+ FROM golang:alpine AS build
3
+ RUN apk update && apk add git
5
4
ADD . /src
6
5
WORKDIR /src
7
- RUN go mod download
6
+ ENV CGO_ENABLED 0
8
7
RUN go build \
9
8
-ldflags "-X github.com/jpillora/chisel/share.BuildVersion=$(git describe --abbrev=0 --tags)" \
10
- -o chisel
9
+ -o /tmp/bin
11
10
# run stage
12
11
FROM scratch
13
- COPY --from=alpine:latest /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/
12
+ LABEL maintainer=
"[email protected] "
13
+ COPY --from=build /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/
14
14
WORKDIR /app
15
- COPY --from=build /src/chisel /app/chisel
16
- ENTRYPOINT ["/app/chisel " ]
15
+ COPY --from=build /tmp/bin /app/bin
16
+ ENTRYPOINT ["/app/bin " ]
You can’t perform that action at this time.
0 commit comments