Skip to content
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

Add advice for nightly usage #88

Open
polarathene opened this issue Oct 27, 2021 · 4 comments
Open

Add advice for nightly usage #88

polarathene opened this issue Oct 27, 2021 · 4 comments

Comments

@polarathene
Copy link

polarathene commented Oct 27, 2021

This is not covered on the DockerHub image page.

I came across this issue which mentions rustlang/rust and links to the official image. It would be nice to have a mention of preferring that image from the official one as well when interested in the nightly channel.

@detly
Copy link

detly commented Mar 7, 2022

Yes please, I found this very confusing. I assumed that rustlang/rust was simply an abbreviated way to refer to the rust images. My initial confusion came down to: Why is it different? Is it still official? Why don't the official docs mention it?

@chrysn
Copy link

chrysn commented Feb 7, 2023

The README says: "An image tracking the Rust nightly toolchain is available via rustlang/rust:nightly." -- and has said so for the last 6 years. Is this sufficient advice, or do you think it should be mentioned somewhere else too?

@polarathene
Copy link
Author

The README says
do you think it should be mentioned somewhere else too?

Yes... that's the problem. You only see that if you land on the README here on Github.

No where on the DockerHub page for the official image does it mention anything about nightly toolchain (or the alternative image for it). Often Docker users will land on DockerHub when searching for an image, and rarely expect the documentation to differ in any meaningful way at the source (which is not always linked to).

Meanwhile, the nightly image is clear that despite the image name, it's only focused on nightly builds, and references the reader to the official image for anything else. The official image should likewise link to the nightly image for those that need that.

"An image tracking the Rust nightly toolchain is available via rustlang/rust:nightly." -- and has said so for the last 6 years.

I assume I did not see that, nor did the reporter of the issue I referenced 🤷‍♂️ Perhaps I landed on that issue directly via Google, I don't recall. Either way, requesting a mention on the DockerHub page still seems valid.

@detly
Copy link

detly commented Feb 8, 2023

Sorry, I re-read what I wrote a year ago and had no idea what I meant. But I think the issue/workflow was: let's say you come at this resource via working on CI. Your CI config has

  • image: rust:1.56-slim for MSRV tests
  • image: rust:1-slim for latest stable tests

You want to add nightly tests. You know the images follow the pattern rust:<version>-slim but nightly doesn't quite fit that pattern. nightly-slim? 1-nightly-slim? Welp, off to the last place you saw this pattern documented, the official Docker image page.

Oh, there's no nightly there. But the image page says it's official, and maintained by the Rust project devs, which links to here. So I come here, I read the README. I see there's a rustlang/rust:nightly. Wait, isn't rustlang/rust where I just came from?

Turns out, no! It's not! Where I came from was an official Docker image. This new thing (rustlang/rust) is... not? Where the official image has a Rust logo, and a nice green Docker Official Image tag, this one does not. The original one has no "by" link, but this one does. So... is it the same team or not? Where the official image had a _/ in the URL, this has r/rustlang. The team page has no description and doesn't contain or link to the official images.

These are the kinds of heuristics that go through my mind when I'm trying to make sure I don't accidentally use a malicious image for CI, or use an out-of-date image, etc. etc. Any little inconsistency is a red flag.

And eventually, yes, going through the code and the docs confirms that this is indeed the "Rust official" image even if it's not a "Rust AND Docker official" image. But it could be clearer I think. Something like:

Images published from this repo

The Docker-official Rust image is probably what you're after if you want a Docker image for testing or deploying Rust programs in a consistent way. It has tags for each stable release, and is has variants for Docker's standard buildpack distro, Debian Slim and Alpine.

(I don't know if this is actually correct!) There are also images published under the rustlang community account that provide the nightly toolchain and crater-test images. These are less commonly needed.

...or...

An image tracking the Rust nightly toolchain is available via rustlang/rust:nightly. This is officially maintained and kept up-to-date by the same team, but less commonly needed for general development and is therefore not a Docker-official image. It is published under the rustlang community account (is that actually what it is?) .

And then also maybe a liiiiitle more exposition on the Docker team and image pages?

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

No branches or pull requests

3 participants