2025-11-06 22:25:17 +01:00
|
|
|
FROM rust:alpine AS build-container
|
2025-11-05 22:47:06 +01:00
|
|
|
|
2025-11-13 14:06:08 +01:00
|
|
|
RUN apk add --no-cache protobuf-dev git musl-dev lld openssl-dev openssl-libs-static yq bash
|
2025-11-05 22:47:06 +01:00
|
|
|
|
2025-11-06 22:22:37 +01:00
|
|
|
FROM build-container AS builder
|
2025-03-25 07:30:10 +00:00
|
|
|
|
|
|
|
|
WORKDIR /app
|
|
|
|
|
|
|
|
|
|
COPY . .
|
|
|
|
|
|
2025-11-13 14:34:11 +01:00
|
|
|
ARG EDITION
|
2025-11-13 14:06:08 +01:00
|
|
|
|
2025-03-25 07:30:10 +00:00
|
|
|
RUN git submodule update --init --recursive
|
|
|
|
|
|
2025-11-13 14:06:08 +01:00
|
|
|
RUN ./test-edition.sh
|
|
|
|
|
RUN ./build-edition.sh
|
2025-03-25 07:30:10 +00:00
|
|
|
|
2025-11-05 21:54:47 +01:00
|
|
|
FROM scratch AS node-holder
|
2025-11-05 22:13:56 +01:00
|
|
|
COPY --from=builder /app/target/x86_64-unknown-linux-musl/release/edge_node_holder_server /edge_node_holder_server
|
2025-11-05 21:54:47 +01:00
|
|
|
ENTRYPOINT ["/edge_node_holder_server"]
|
2025-03-25 07:30:10 +00:00
|
|
|
|
|
|
|
|
|
2025-11-13 14:06:08 +01:00
|
|
|
FROM alpine:latest AS proxy-insecure
|
2025-11-05 22:13:56 +01:00
|
|
|
COPY --from=builder /app/target/x86_64-unknown-linux-musl/release/proxy_insecure /proxy_insecure
|
2025-11-07 18:42:15 +00:00
|
|
|
RUN apk add --no-cache ca-certificates
|
|
|
|
|
RUN update-ca-certificates
|
2025-11-05 21:54:47 +01:00
|
|
|
ENTRYPOINT ["/proxy_insecure"]
|
|
|
|
|
|
2025-11-13 14:06:08 +01:00
|
|
|
FROM alpine:latest AS proxy-secure
|
2025-11-05 22:13:56 +01:00
|
|
|
COPY --from=builder /app/target/x86_64-unknown-linux-musl/release/proxy_secure /proxy_secure
|
2025-11-07 18:42:15 +00:00
|
|
|
RUN apk add --no-cache ca-certificates
|
|
|
|
|
RUN update-ca-certificates
|
2025-11-05 21:54:47 +01:00
|
|
|
ENTRYPOINT ["/proxy_secure"]
|
2025-11-07 18:06:22 +00:00
|
|
|
|
|
|
|
|
|
2025-11-05 21:54:47 +01:00
|
|
|
FROM scratch AS backend-auth
|
2025-11-05 22:13:56 +01:00
|
|
|
COPY --from=builder /app/target/x86_64-unknown-linux-musl/release/backend_server_insecure /backend_server_insecure
|
2025-11-07 18:06:22 +00:00
|
|
|
ENTRYPOINT ["/backend_server_insecure"]
|
2025-11-05 21:54:47 +01:00
|
|
|
|
|
|
|
|
FROM scratch AS backend-secure
|
2025-11-05 22:13:56 +01:00
|
|
|
COPY --from=builder /app/target/x86_64-unknown-linux-musl/release/backend_server_secure /backend_server_secure
|
2025-11-05 21:54:47 +01:00
|
|
|
ENTRYPOINT ["/backend_server_secure"]
|
2025-11-05 22:47:06 +01:00
|
|
|
|
|
|
|
|
# make sure the final output container is the dev container so that we can use it from the devcontainer.json
|
2025-11-06 22:22:37 +01:00
|
|
|
FROM build-container AS dev-container
|
|
|
|
|
RUN apk add openjdk21-jdk gcompat
|