You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

Dockerfile 527B

4 years ago
123456789101112131415161718192021
  1. FROM rust:slim AS builder
  2. RUN apt-get update -y && \
  3. apt-get install -y python-pip make g++ python-setuptools libssl-dev pkg-config rsync && \
  4. pip install dockerize && \
  5. rustup target add x86_64-unknown-linux-gnu
  6. WORKDIR /app
  7. COPY . .
  8. RUN cargo build --release --target x86_64-unknown-linux-gnu
  9. RUN mv target/x86_64-unknown-linux-gnu/release/zola /usr/bin
  10. RUN mkdir -p /workdir
  11. WORKDIR /workdir
  12. RUN dockerize -n -o /workdir /usr/bin/zola
  13. FROM scratch
  14. COPY --from=builder /workdir .
  15. ENTRYPOINT [ "/usr/bin/zola" ]