Skip to content

Commit

Permalink
Update Dockerfile (#133)
Browse files Browse the repository at this point in the history
  • Loading branch information
bogo-y committed Oct 27, 2023
1 parent 16211da commit 979d9a2
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Build the manager binary
FROM golang:1.14.2 as builder
FROM golang:1.19 as builder

# Copy in the go src
WORKDIR /go/src/github.com/AliyunContainerService/kubernetes-cronhpa-controller
Expand All @@ -11,12 +11,12 @@ COPY vendor/ vendor/
RUN CGO_ENABLED=0 GOOS=linux GOARCH=amd64 GO111MODULE=off go build -a -o kubernetes-cronhpa-controller github.com/AliyunContainerService/kubernetes-cronhpa-controller/cmd/kubernetes-cronhpa-controller

# Copy the controller-manager into a thin image
FROM alpine:3.12.0
FROM alpine:3.17
RUN apk add --no-cache tzdata
WORKDIR /root/
COPY --from=builder /go/src/github.com/AliyunContainerService/kubernetes-cronhpa-controller/kubernetes-cronhpa-controller .
COPY docker-entrypoint.sh .
RUN chmod +x /root/docker-entrypoint.sh

ENTRYPOINT ["/root/docker-entrypoint.sh"]
CMD ["/root/kubernetes-cronhpa-controller"]
CMD ["/root/kubernetes-cronhpa-controller"]

0 comments on commit 979d9a2

Please sign in to comment.