-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
24 lines (22 loc) · 942 Bytes
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
FROM sbtscala/scala-sbt:eclipse-temurin-jammy-21.0.2_13_1.9.9_3.4.0 as build
RUN apt update && apt install -y clang mold libstdc++-12-dev libgc-dev libutf8proc-dev libssl-dev libsodium-dev git cmake
RUN git clone -b v1.4.14 https://github.com/aws/s2n-tls /tmp/s2n-tls
WORKDIR /tmp/s2n-tls
RUN prefix=/usr make install
WORKDIR /src
COPY . /src
ENV DOCKER_BUILD=1
RUN sbt "nativeLink;stageBinary"
FROM sbtscala/scala-sbt:eclipse-temurin-jammy-21.0.2_13_1.9.9_3.4.0 as runner
RUN apt update && apt install -y libstdc++-12-dev libgc-dev libutf8proc-dev libssl-dev
COPY --from=build /src/router /router
COPY --from=build /usr/lib64/libs2n.so /usr/lib/libs2n.so
COPY --from=build /usr/lib64/libs2n.a /usr/lib/libs2n.a
COPY systems.json /systems.json
COPY capitals.json /capitals.json
COPY citadels.json /citadels.json
COPY rigsizes.json /rigsizes.json
WORKDIR /
ENV S2N_DONT_MLOCK=1
ENV LOGLEVEL=Info
ENTRYPOINT ["/router", "run", "/config.yml"]