Skip to content

default $GOPATH environment variable #129

@zchee

Description

@zchee

Hi, thanks for maintaining the good base image for Go.

This issue is a just proposal.

I think you already know, go1.8 has been implemented default $GOPATH to $HOME/go(on Unix).
golang/go@dc4a815

I know that is not language spec, and it can be changed arbitrarily by the users.
However, As the typical install go toolchain directory is /usr/local/go(on Unix), I think GOPATH=$HOME/go will also be a defacto directory path for $GOPATH to some extent.
But, current official golang docker image sets the $GOPATH to /go, which is not $HOME/go even if the user is root. (in case of not set --user flag)

I do not think it is absolutely necessary, but might be ENV GOPATH $HOME/go is a better setting than using a golang image specific setting.
But also that change might be no backward compatibility.

What do you think about it?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions