bitwarden_rs_ldap/Dockerfile.alpine

22 lines
529 B
Docker
Raw Normal View History

FROM ekidd/rust-musl-builder:1.46.0 AS builder
2019-04-19 01:13:31 +00:00
WORKDIR /home/rust/src
# Cache build deps
2019-04-19 01:13:31 +00:00
RUN USER=rust cargo init
COPY Cargo.toml Cargo.lock ./
RUN cargo build --locked --release && \
rm src/*.rs
2019-04-19 01:13:31 +00:00
COPY --chown=rust:rust ./src ./src
RUN touch ./src/main.rs && \
cargo build --release
2019-04-19 01:13:31 +00:00
FROM alpine:3
RUN apk --no-cache add ca-certificates=20191127-r5
2019-04-19 01:13:31 +00:00
COPY --from=builder \
2021-05-07 19:55:29 +00:00
/home/rust/src/target/x86_64-unknown-linux-musl/release/vaultwarden_ldap \
2019-04-19 01:13:31 +00:00
/usr/local/bin/
2021-05-07 19:55:29 +00:00
CMD ["/usr/local/bin/vaultwarden_ldap"]