Skip to content

Commit

Permalink
Merge pull request #251 from codecrafters-io/simplify-rust
Browse files Browse the repository at this point in the history
Remove unnecessary cleanup commands from rust-1.77 Dockerfile.
  • Loading branch information
rohitpaulk authored Aug 23, 2024
2 parents fa904f4 + 162effc commit 18f6b1e
Showing 1 changed file with 0 additions and 12 deletions.
12 changes: 0 additions & 12 deletions dockerfiles/rust-1.77.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -8,18 +8,6 @@ COPY --exclude=.git --exclude=README.md . /app

RUN cargo build --release --target-dir=/tmp/codecrafters-redis-target

RUN rm /tmp/codecrafters-redis-target/release/redis-starter-rust
RUN rm /tmp/codecrafters-redis-target/release/redis-starter-rust.d

# Build caching schenanigans, see if this can be simplified
RUN find /tmp/codecrafters-redis-target/release -type f -maxdepth 1 -delete
RUN rm -f /tmp/codecrafters-redis-target/release/deps/*redis_starter_rust*
RUN rm -f /tmp/codecrafters-redis-target/release/deps/redis_starter_rust*
RUN rm -f /tmp/codecrafters-redis-target/release/.fingerprint/*redis_starter_rust*
RUN rm -f /tmp/codecrafters-redis-target/release/.fingerprint/redis_starter_rust*

RUN rm -rf /app/src

RUN echo "cd \${CODECRAFTERS_REPOSITORY_DIR} && cargo build --release --target-dir=/tmp/codecrafters-redis-target --manifest-path Cargo.toml" > /codecrafters-precompile.sh
RUN chmod +x /codecrafters-precompile.sh

Expand Down

0 comments on commit 18f6b1e

Please sign in to comment.