fix dockerfile
This commit is contained in:
parent
7f60f8fd3d
commit
1780be3104
1 changed files with 8 additions and 4 deletions
12
Dockerfile
12
Dockerfile
|
@ -5,10 +5,14 @@ ADD . .
|
||||||
RUN apt update && apt install -y musl-tools
|
RUN apt update && apt install -y musl-tools
|
||||||
RUN rustup target add x86_64-unknown-linux-musl
|
RUN rustup target add x86_64-unknown-linux-musl
|
||||||
RUN cargo build --release --target x86_64-unknown-linux-musl
|
RUN cargo build --release --target x86_64-unknown-linux-musl
|
||||||
RUN strip /app/target/release/macnickenson
|
RUN find /app/target -name macnickenson
|
||||||
|
RUN strip /app/target/x86_64-unknown-linux-musl/release/macnickenson
|
||||||
|
|
||||||
# ---
|
# ---
|
||||||
|
|
||||||
FROM debian:buster-slim
|
FROM scratch
|
||||||
COPY --from=builder /app/target/release/macnickenson /opt/macnickenson
|
WORKDIR /app/static
|
||||||
CMD /opt/macnickenson
|
WORKDIR /app
|
||||||
|
COPY --from=builder /app/target/x86_64-unknown-linux-musl/release/macnickenson /app/macnickenson
|
||||||
|
USER 1000
|
||||||
|
CMD ["/app/macnickenson"]
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue