Created
April 18, 2017 15:18
-
-
Save binarytemple-external/ac0c1c8e0dedccfd7cbfdc375df82c09 to your computer and use it in GitHub Desktop.
Dockerfile golang centos
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM centos:latest | |
MAINTAINER [email protected] | |
ENV GOROOT /usr/local/go | |
#ENV GOROOT1_5 /usr/local/go1_5 | |
#ENV GOBIN $GOROOT/bin | |
#ENV GOROOT_BOOTSTRAP $GOROOT | |
RUN yum update -y | |
RUN yum install -y gcc wget git which | |
ENV GOLANG_VERSION 1.8.1 | |
ENV GOLANG_TAR_BALL go$GOLANG_VERSION.linux-amd64.tar.gz | |
ENV GOLANG_DOWNLOAD_URL https://storage.googleapis.com/golang/$GOLANG_TAR_BALL | |
ENV GOLANG_DOWNLOAD_SHA1 a433f76c569055ff8536d796995518dd91a9fa5b | |
RUN wget $GOLANG_DOWNLOAD_URL \ | |
&& echo "$GOLANG_DOWNLOAD_SHA1 $GOLANG_TAR_BALL" | sha1sum -c - \ | |
&& tar -C /usr/local -xzf $GOLANG_TAR_BALL \ | |
&& rm $GOLANG_TAR_BALL | |
#ENV GOPATH /go | |
ENV PATH $GOROOT/bin:$PATH | |
#RUN mkdir -p $GOROOT \ | |
# && cd $GOROOT \ | |
# && git clone https://github.com/golang/go.git . \ | |
# && cd ./src \ | |
# && CGO_ENABLED=1 ./make.bash | |
# | |
#WORKDIR $GOPATH | |
RUN go version | |
RUN gcc -v |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment