🐳 Fix Docker
parent
bbb88c01e8
commit
5f9e84f7f6
14
Dockerfile
14
Dockerfile
|
@ -8,12 +8,12 @@ RUN apt-get update \
|
||||||
# Make sure the dependencies are all cached so we won't hammer crates.io
|
# Make sure the dependencies are all cached so we won't hammer crates.io
|
||||||
|
|
||||||
ADD old-git.tar.gz .
|
ADD old-git.tar.gz .
|
||||||
RUN git checkout 151f236a0b8de510b1896deeaa9c571f845040af \
|
RUN git checkout bbb88c01e8ad28d256c8faf316f46d7214184ec2 \
|
||||||
&& git reset --hard \
|
&& git reset --hard \
|
||||||
&& cargo check
|
&& cargo check -p ptth_relay
|
||||||
|
|
||||||
RUN cargo test --release \
|
RUN cargo test --release --all \
|
||||||
&& cargo build --release --bin ptth_relay
|
&& cargo build --release -p ptth_relay
|
||||||
|
|
||||||
COPY .git .git
|
COPY .git .git
|
||||||
|
|
||||||
|
@ -22,8 +22,8 @@ ARG gitcommithash=HEAD
|
||||||
RUN git checkout "$gitcommithash" \
|
RUN git checkout "$gitcommithash" \
|
||||||
&& git reset --hard \
|
&& git reset --hard \
|
||||||
&& echo "pub const GIT_VERSION: Option <&str> = Some (\"$(git rev-parse HEAD)\");" > src/git_version.rs \
|
&& echo "pub const GIT_VERSION: Option <&str> = Some (\"$(git rev-parse HEAD)\");" > src/git_version.rs \
|
||||||
&& cargo test --release \
|
&& cargo test --release --all \
|
||||||
&& cargo build --release --bin ptth_relay
|
&& cargo build --release -p ptth_relay
|
||||||
|
|
||||||
FROM debian:buster-slim as deploy
|
FROM debian:buster-slim as deploy
|
||||||
|
|
||||||
|
@ -33,7 +33,7 @@ RUN apt-get update \
|
||||||
|
|
||||||
COPY --from=build /usr/src/target/release/ptth_relay /root
|
COPY --from=build /usr/src/target/release/ptth_relay /root
|
||||||
COPY --from=build /usr/src/src/git_version.rs /root/git_version.rs
|
COPY --from=build /usr/src/src/git_version.rs /root/git_version.rs
|
||||||
COPY --from=build /usr/src/ptth_handlebars /root/ptth_handlebars
|
COPY --from=build /usr/src/handlebars /root/handlebars
|
||||||
|
|
||||||
WORKDIR /root
|
WORKDIR /root
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue