diff --git a/Dockerfile b/Dockerfile index b670054..6c442d5 100644 --- a/Dockerfile +++ b/Dockerfile @@ -10,7 +10,7 @@ RUN echo 'fn main() { println!("Hello, world!"); }' >> src/main.rs COPY ./Cargo.lock ./Cargo.lock COPY ./Cargo.toml ./Cargo.toml # HACK: remove build-dependencies so we have at least some caching -RUN head -n $(($(grep -n "\[build-dependencies\]" Cargo.toml | cut -f1 -d:) - 1)) Cargo.toml | sed '/build.rs/d' > \ +RUN head -n $(($(grep -n "\[build-dependencies\]" Cargo.toml | cut -f1 -d:) - 1)) Cargo.toml | sed '/src\/build.rs/d' > \ Cargo.toml2 && rm Cargo.toml && mv Cargo.toml2 Cargo.toml # build to cache dependencies RUN cargo build --release @@ -24,7 +24,6 @@ COPY ./.git ./.git # copy source code COPY ./static ./static COPY ./templates ./templates -COPY ./build.rs ./build.rs COPY ./src ./src # build source code RUN cargo build --release