blob: 3f36ec8618d34fb08bdd257d8a7480ed257e4149 [file] [log] [blame]
Adrià Vilanova Martínez250457f2021-08-08 01:23:14 +02001FROM golang:latest as builder
2
3ENV CGO_ENABLED=0
4
5ENV GO111MODULE=on
6ENV GOPROXY=https://proxy.golang.org
7
8RUN mkdir /gocache
9ENV GOCACHE /gocache
10
11WORKDIR /go/src/gomodules.avm99963.com/gitwatcher
12COPY . /go/src/gomodules.avm99963.com/gitwatcher
13
14# Optimization for iterative docker build speed, not necessary for correctness:
15
16RUN go install gomodules.avm99963.com/gitwatcher
17
18FROM alpine
19LABEL maintainer "me@avm99963.com"
20
21RUN apk add --no-cache tini
22COPY --from=builder /go/bin/gitwatcher /
23ENTRYPOINT ["/sbin/tini", "--", "/gitwatcher"]