-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Finally include dockerfile, and tweaks readme instructions
- Loading branch information
Showing
2 changed files
with
28 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
FROM rust:1.71-slim-buster as builder | ||
|
||
RUN apt-get update && apt-get install -y libudev-dev clang pkg-config libssl-dev build-essential cmake protobuf-compiler | ||
|
||
RUN update-ca-certificates | ||
|
||
WORKDIR /usr/src/app | ||
|
||
COPY . . | ||
|
||
RUN --mount=type=cache,mode=0777,target=/home/root/app/target \ | ||
--mount=type=cache,mode=0777,target=/usr/local/cargo/registry \ | ||
cargo build --release --bin validator-keeper | ||
|
||
######### | ||
|
||
FROM debian:buster as validator-history | ||
RUN apt-get update && apt-get install -y ca-certificates | ||
ENV APP="validator-keeper" | ||
|
||
COPY --from=builder /usr/src/app/target/release/$APP ./$APP | ||
|
||
ENTRYPOINT ./$APP | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters