This repository has been archived on 2021-12-24. You can view files and clone it, but cannot push or open issues/pull-requests.
2021-12-24 09:02:03 +01:00
|
|
|
FROM rust:1.57-alpine3.13 AS builder
|
2021-06-19 11:54:46 +02:00
|
|
|
|
|
|
|
WORKDIR /src
|
|
|
|
|
2021-06-25 11:32:50 +02:00
|
|
|
# Install build dependencies
|
|
|
|
RUN apk add --no-cache \
|
|
|
|
musl-dev \
|
|
|
|
postgresql-dev
|
|
|
|
|
|
|
|
# Copy over source code
|
2021-06-19 11:54:46 +02:00
|
|
|
COPY Cargo.toml Cargo.lock ./
|
|
|
|
COPY src ./src/
|
|
|
|
|
|
|
|
RUN cargo build \
|
|
|
|
--release
|
|
|
|
|
|
|
|
|
2021-12-24 09:02:01 +01:00
|
|
|
FROM alpine:3.15
|
2021-06-19 11:54:46 +02:00
|
|
|
|
|
|
|
COPY --from=builder /src/target/release/hilde /usr/local/bin/hilde
|
|
|
|
|
|
|
|
ENTRYPOINT [ "/usr/local/bin/hilde" ]
|