-
-
Notifications
You must be signed in to change notification settings - Fork 14
/
Copy pathDockerfile.ui
40 lines (32 loc) · 1.33 KB
/
Dockerfile.ui
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
34
35
36
37
38
39
40
# Builder image
FROM registry.access.redhat.com/ubi9/nodejs-22:latest AS builder
USER 1001
COPY --chown=1001 ./server/ui .
COPY --chown=1001 ./entrypoint.ui.sh ./entrypoint.sh
RUN npm install -g npm@9
RUN npm clean-install --ignore-scripts && npm run build && npm run dist
# Runner image
FROM registry.access.redhat.com/ubi9/nodejs-22-minimal:latest
# Add ps package to allow liveness probe for k8s cluster
# Add tar package to allow copying files with kubectl scp
USER 0
RUN microdnf -y install tar procps-ng && microdnf clean all
USER 1001
LABEL name="openubl/openubl-ui" \
description="Openubl - User Interface" \
help="For more information visit https://project-openubl.github.io/" \
license="Apache License 2.0" \
maintainer="[email protected]" \
summary="Openubl - User Interface" \
url="https://ghcr.io/project-openubl/openubl-ui" \
usage="podman run -p 80 -v project-openubl/openubl-ui:latest" \
io.k8s.display-name="openubl-ui" \
io.k8s.description="Openubl - User Interface" \
io.openshift.expose-services="80:http" \
io.openshift.tags="operator,openubl,ui,nodejs22" \
io.openshift.min-cpu="100m" \
io.openshift.min-memory="350Mi"
COPY --from=builder /opt/app-root/src/dist /opt/app-root/dist/
ENV DEBUG=1
WORKDIR /opt/app-root/dist
ENTRYPOINT ["./entrypoint.sh"]