Skip to content

Commit 3b4f127

Browse files
committed
fix docker build
1 parent 7b21d2c commit 3b4f127

File tree

1 file changed

+12
-3
lines changed

1 file changed

+12
-3
lines changed

Dockerfile

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,16 @@
1-
FROM golang:latest AS builder
1+
FROM golang:alpine AS builder
22

3-
ADD . /go/src/github.com/ochinchina/supervisord
4-
RUN go get -v -u github.com/ochinchina/supervisord && go build -o /usr/local/bin/supervisord github.com/ochinchina/supervisord
3+
RUN apk update && \
4+
apk add git
5+
6+
# uncomments this if golang.org is not accessible
7+
#RUN mkdir -p $GOPATH/src/golang.org/x && \
8+
# cd $GOPATH/src/golang.org/x && \
9+
# git clone https://github.com/golang/crypto && \
10+
# git clone https://github.com/golang/sys
11+
12+
RUN go get -v -u github.com/ochinchina/supervisord && \
13+
go build -o /usr/local/bin/supervisord github.com/ochinchina/supervisord
514

615
FROM alpine:latest
716

0 commit comments

Comments
 (0)