You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This can be fixed by slightly optimizing the Dockerfile
FROM rust:1.67 as build# create a new empty shell projectRUN USER=root cargo new --bin apiWORKDIR /api# copy over your manifestsCOPY ./Cargo.lock ./Cargo.lockCOPY ./Cargo.toml ./Cargo.toml# this build step will cache your dependenciesRUN cargo build --releaseRUN rm src/*.rs# copy your source treeCOPY ./src ./src# build for releaseRUN rm ./target/release/deps/holodeck*RUN cargo build --release# our final baseFROM rust:1.67# copy the build artifact from the build stageCOPY --from=build /api/target/release/api .# set the startup command to run your binaryCMD ["./api"]
The text was updated successfully, but these errors were encountered:
This can be fixed by slightly optimizing the
Dockerfile
The text was updated successfully, but these errors were encountered: