chore(docker): remove Rust edition workaround from Dockerfile

This commit is contained in:
Orhun Parmaksız 2022-02-25 00:14:14 +03:00
parent d6ba6ac630
commit 2ef453be28
No known key found for this signature in database
GPG Key ID: F83424824B3E4B90
1 changed files with 0 additions and 4 deletions

View File

@ -1,15 +1,11 @@
FROM ekidd/rust-musl-builder:latest as builder
WORKDIR /home/rust/src
COPY Cargo.toml Cargo.toml
# https://github.com/emk/rust-musl-builder/issues/130
RUN sed -i "s|edition = \"2021\"|edition = \"2018\"|" Cargo.toml
RUN mkdir -p src/
RUN echo "fn main() {println!(\"failed to build\")}" > src/main.rs
RUN cargo build --release
RUN rm -f target/release/deps/rustypaste*
COPY . .
# https://github.com/emk/rust-musl-builder/issues/130
RUN sed -i "s|edition = \"2021\"|edition = \"2018\"|" Cargo.toml
RUN cargo build --locked --release
RUN mkdir -p build-out/
RUN cp target/x86_64-unknown-linux-musl/release/rustypaste build-out/