Public Repository

Last pushed: 4 months ago
Short Description
Golang Images
Full Description
FROM docker.io/phusion/baseimage:0.9.21
MAINTAINER Quanyi Ma <maquanyi@huawei.com>

RUN apt-get update && apt-get install -y git make

ARG go_version
ENV GO_VERSION ${go_version}

COPY go${GO_VERSION}.sha256 /tmp/
RUN curl -sSL https://storage.googleapis.com/golang/go${GO_VERSION}.linux-amd64.tar.gz -o /tmp/go.tar.gz && \
    echo "$(cat /tmp/go${GO_VERSION}.sha256)  /tmp/go.tar.gz" | sha256sum -c - && \
    tar -C /var/opt -xzf /tmp/go.tar.gz && \
    rm /tmp/go.tar.gz /tmp/go${GO_VERSION}.sha256 && \
    mkdir -p /var/opt/gopath && \
    chmod -R 777 /var/opt/gopath

ENV GOROOT /var/opt/go
ENV GOPATH /var/opt/gopath
ENV PATH $PATH:$GOROOT/bin:$GOPATH:/bin

WORKDIR $GOPATH
Docker Pull Command
Owner
containerops

Comments (0)