Skip to content

Move installed binaries out of $CARGO_HOME #18

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from

Conversation

mzabaluev
Copy link

This is a one-line fix for #17. The binaries, plus an env file which is only meaningful when $CARGO_HOME is populated with binaries, are all that is installed there by the Docker image build.

If a container run invokes rustup, this may override the binaries
moved to /usr/local/bin with freshly installed binaries in $CARGO_HOME/bin/.
This is perfectly fine for incremental container images.

The intent is to make the container workable with $CARGO_HOME mounted
from the host, to preserve Cargo caches and the authentication token
between container runs.

If a container run invokes rustup, this may override the binaries
moved to /usr/local/bin with freshly installed binaries in $CARGO_HOME/bin/.
This is perfectly fine for incremental container images.
@sfackler
Copy link
Member

Why do you think this PR will be merged?

@mzabaluev
Copy link
Author

Why do you think this PR will be merged?

Because it solves an acute problem for users of this container, in a clean and simple way, with no disadvantages known to me?
Sorry, but "rustup does it" was not a compelling explanation why not to fix this. rustup manages most of its installation in $RUSTUP_HOME, only the binary installation directory is an outlier.

@sfackler
Copy link
Member

rustup manages most of its installation in $RUSTUP_HOME, only the binary installation directory is an outlier.

Then rustup is the thing that needs to be changed!

This is the official Docker image for the Rust programming language, and as such it should be have as "normally" as possible. Having rustup's proxy binaries in some random directory is not a normal thing to do. If you want to move these binaries out of the way, you're welcome to do that in your own image based off of the official one, or even make your own from scratch.

@sfackler sfackler closed this Dec 21, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants