-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile.ce
33 lines (27 loc) · 1.04 KB
/
Dockerfile.ce
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
FROM debian:bookworm AS builder
RUN apt-get --yes update && apt-get install --yes --no-install-recommends \
build-essential cmake && apt-get clean && rm -rf /var/lib/apt/lists/*
COPY cmake /source/cmake
COPY src /source/src
COPY schemas /source/schemas
COPY vendor /source/vendor
COPY CMakeLists.txt /source/CMakeLists.txt
# For testing
COPY Makefile /source/Makefile
COPY test/cli /source/test/cli
RUN cmake -S /source -B ./build \
-DCMAKE_BUILD_TYPE:STRING=Release \
-DREGISTRY_INDEX:BOOL=ON \
-DREGISTRY_SERVER:BOOL=ON \
-DREGISTRY_DEVELOPMENT:BOOL=OFF \
-DREGISTRY_ENTERPRISE:BOOL=OFF \
-DBUILD_SHARED_LIBS:BOOL=OFF
RUN cmake --build /build --config Release --parallel 2
RUN cmake --install ./build --prefix /usr --verbose \
--config Release --component sourcemeta_registry
RUN make -C /source test PREFIX=/usr EDITION=ce
FROM debian:bookworm-slim
COPY --from=builder /usr/bin/sourcemeta-registry-index \
/usr/bin/sourcemeta-registry-index
COPY --from=builder /usr/bin/sourcemeta-registry-server \
/usr/bin/sourcemeta-registry-server