diff --git a/golang/centos7/Dockerfile b/golang/centos7/Dockerfile index 974c0692..2b265ed6 100644 --- a/golang/centos7/Dockerfile +++ b/golang/centos7/Dockerfile @@ -1,10 +1,11 @@ FROM centos:7 -RUN yum -y update && yum clean all +ENV GOPATH /go -RUN mkdir -p /go && chmod -R 777 /go && \ +RUN yum -y update && \ + mkdir -p "$GOPATH/src" "$GOPATH/bin" && chmod -R 777 "$GOPATH" && \ yum -y install git golang && yum clean all -ENV GOPATH /go +ENV PATH $PATH:$GOPATH/bin -WORKDIR /go +WORKDIR $GOPATH