blob: f364da172582b430105396c2eeeaf5ee740b5ab7 [file] [log] [blame]
Varun Patil794dcbd2024-05-05 16:12:48 -07001# syntax=docker/dockerfile:1
2
3ARG NDN_CXX_VERSION=latest
4FROM ghcr.io/named-data/ndn-cxx-build:${NDN_CXX_VERSION} AS build
5
6ARG JOBS
7ARG SOURCE_DATE_EPOCH
8RUN --mount=rw,target=/src <<EOF
9 set -eux
10 cd /src
11 ./waf configure \
12 --prefix=/usr \
13 --libdir=/usr/lib \
14 --sysconfdir=/etc \
15 --localstatedir=/var \
16 --sharedstatedir=/var
17 ./waf build
18 ./waf install
19EOF
20
21
Davide Pesavento6d00e0b2024-05-06 22:30:22 -040022FROM ghcr.io/named-data/ndn-cxx-runtime:${NDN_CXX_VERSION} AS ca
Varun Patil794dcbd2024-05-05 16:12:48 -070023
24COPY --link --from=build /usr/lib/libndn-cert.so.* /usr/lib/
25COPY --link --from=build /usr/bin/ndncert-ca-server /usr/bin/
26COPY --link --from=build /usr/bin/ndncert-ca-status /usr/bin/
27COPY --link --from=build /usr/bin/ndncert-send-email-challenge /usr/bin/
Varun Patil794dcbd2024-05-05 16:12:48 -070028
29RUN apt-get install -Uy --no-install-recommends \
30 python3 \
31 && apt-get distclean
32
33ENV HOME=/config
34VOLUME /config
35VOLUME /etc/ndncert
36VOLUME /run/nfd
37
38ENTRYPOINT ["/usr/bin/ndncert-ca-server"]
Davide Pesavento6d00e0b2024-05-06 22:30:22 -040039CMD ["-c", "/config/ndncert-ca.conf"]
40
41
42FROM ghcr.io/named-data/ndn-cxx-runtime:${NDN_CXX_VERSION} AS client
43
44COPY --link --from=build /usr/lib/libndn-cert.so.* /usr/lib/
45COPY --link --from=build /usr/bin/ndncert-client /usr/bin/
46COPY --link --from=build /etc/ndncert/client.conf.sample /config/ndncert-client.conf
47
48ENV HOME=/config
49VOLUME /config
50VOLUME /run/nfd
51
52ENTRYPOINT ["/usr/bin/ndncert-client"]
53CMD ["-c", "/config/ndncert-client.conf"]