github.com/Psiphon-Labs/psiphon-tunnel-core@v2.0.28+incompatible/Server/Dockerfile-binary-builder (about)

     1  FROM alpine:3.10.2
     2  
     3  ENV GOLANG_VERSION 1.17.13
     4  ENV GOLANG_SRC_URL https://golang.org/dl/go$GOLANG_VERSION.src.tar.gz
     5  
     6  RUN set -ex \
     7  	&& apk add --no-cache \
     8  		bash \
     9  		ca-certificates \
    10  		gcc \
    11  		git \
    12  		go \
    13  		musl-dev \
    14  		openssl \
    15  		perl \
    16  	\
    17  	&& export GOROOT_BOOTSTRAP="$(go env GOROOT)" \
    18  	\
    19  	&& wget -q "$GOLANG_SRC_URL" -O golang.tar.gz \
    20  	&& tar -C /usr/local -xzf golang.tar.gz \
    21  	&& rm golang.tar.gz \
    22  	&& cd /usr/local/go/src \
    23  	&& ./make.bash
    24  
    25  ENV GOPATH /go
    26  ENV PATH $GOPATH/bin:/usr/local/go/bin:$PATH
    27  
    28  RUN mkdir -p "$GOPATH/src" "$GOPATH/bin" && chmod -R 777 "$GOPATH"
    29  WORKDIR $GOPATH