2020-07-10 01:01:29 +00:00
|
|
|
FROM golang:alpine AS builder
|
|
|
|
|
2020-07-10 01:07:46 +00:00
|
|
|
ADD . /go/src
|
2020-07-10 01:06:38 +00:00
|
|
|
|
2020-07-10 01:07:46 +00:00
|
|
|
RUN cd /go/src; go build -o sleeper
|
2020-07-10 01:01:29 +00:00
|
|
|
|
|
|
|
FROM alpine
|
|
|
|
|
2020-07-10 02:09:58 +00:00
|
|
|
ADD docker/entrypoint.sh /entrypoint.sh
|
|
|
|
COPY --from=builder /go/src/sleeper /usr/bin/sleeper
|
2020-07-10 01:01:29 +00:00
|
|
|
|
2020-07-10 02:09:58 +00:00
|
|
|
RUN chmod +x /entrypoint.sh
|
|
|
|
|
|
|
|
ENTRYPOINT "/entrypoint.sh"
|