docker/diesel/Dockerfile.arm64v8

32 lines
535 B
Docker
Raw Permalink Normal View History

2020-03-16 23:44:12 +00:00
FROM arm64v8/rust:1.42.0-buster AS builder
ARG BUILD_DATE
RUN apt-get update && \
apt-get install -y libpq-dev && \
cargo install diesel_cli --no-default-features --features postgres
FROM arm64v8/ubuntu:19.10
ARG UID=991
ARG GID=991
RUN \
apt-get update && \
apt-get upgrade -y
RUN \
addgroup --gid "${GID}" relay && \
adduser \
--disabled-password \
--gecos "" \
--ingroup relay \
--uid "${UID}" \
relay
COPY --from=builder /usr/local/cargo/bin/diesel /usr/local/bin/diesel
USER relay
CMD ["relay"]