rust-lang / docker-rust

The official Docker images for Rust
431 stars 89 forks source link

Update Docker Hub description #129

Closed lfrancke closed 1 year ago

lfrancke commented 1 year ago

I don't know if this is a good place to report this.

The description on https://hub.docker.com/_/rust currently says:

FROM rust:1.40 as builder
WORKDIR /usr/src/myapp
COPY . .
RUN cargo install --path .

FROM debian:buster-slim
RUN apt-get update && apt-get install -y extra-runtime-dependencies && rm -rf /var/lib/apt/lists/*
COPY --from=builder /usr/local/cargo/bin/myapp /usr/local/bin/myapp
CMD ["myapp"]

Can we update this to a newer version?

FROM rust:1.66 as builder
WORKDIR /usr/src/myapp
COPY . .
RUN cargo install --path .

FROM debian:bullseye-slim
RUN apt-get update && apt-get install -y extra-runtime-dependencies && rm -rf /var/lib/apt/lists/*
COPY --from=builder /usr/local/cargo/bin/myapp /usr/local/bin/myapp
CMD ["myapp"]

I assume lots of people take that snippet, update the Rust version and then not update buster to bullseye. That's a problem because bullseye is used for later versions of the builder image and buster doesn't have glibc 2.29. So things compiled on one, might not work on the other.

kovar commented 1 year ago

Hey Lars 👋

I believe you can create a pull request here on the content.md file according to these instructions.

lfrancke commented 1 year ago

Excellent, thank you! I managed not to find that somehow. I'll confirm and will close this issue when I'm done.

lfrancke commented 1 year ago

Opened a PR here: https://github.com/docker-library/docs/pull/2275

I'll close this. Sorry for the noise.