Petros Angelatos 83393c04e3 switch to golang 1.6 to make the binary upx-able
https://github.com/golang/go/issues/13974
5e7110b92b

Signed-off-by: Petros Angelatos <petrosagg@gmail.com>
2016-09-14 01:38:36 +00:00

23 lines
419 B
Docker

# Build golang supervisor
FROM golang:1.6
RUN apt-get update \
&& apt-get install -y \
rsync \
&& rm -rf /var/lib/apt/lists/
COPY . /go/src/resin-supervisor/gosuper
WORKDIR /go/src/resin-supervisor/gosuper
ENV GOOS linux
ARG GOARCH=amd64
ARG GOARM=''
RUN go install -a -v ./gosuper \
&& cd /go/bin \
&& find -type f -name gosuper -exec mv {} /go/bin/gosuper \;
CMD rsync -a --delete /go/bin/gosuper /build