docker work
This commit is contained in:
parent
1375505011
commit
389c61e44e
23
Dockerfile
23
Dockerfile
|
@ -1,10 +1,21 @@
|
|||
FROM ubuntu
|
||||
FROM rust:1.59 as builder
|
||||
|
||||
WORKDIR /build
|
||||
|
||||
COPY ./src/ /build/src
|
||||
COPY ./Cargo.toml /build/Cargo.toml
|
||||
|
||||
RUN rustup update nightly && rustup default nightly && \
|
||||
cargo clean && cargo build --release
|
||||
|
||||
|
||||
FROM debian:buster-slim
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
COPY ./target/release/fastcloud /app/fastcloud
|
||||
COPY ./templates /app/templates
|
||||
|
||||
RUN mkdir /app/templates/service
|
||||
ENV FASTCLOUD_DIR /app/templates/service
|
||||
COPY --from=builder /build/target/release/fastcloud /app/fastcloud
|
||||
RUN mkdir /app/service
|
||||
COPY ./templates/ /app/templates
|
||||
ENV FASTCLOUD_DIR /app/service
|
||||
|
||||
CMD [ "/app/fastcloud" ]
|
||||
|
|
Loading…
Reference in New Issue
Block a user