11# --- builder image
2- ARG NODEJS_BUILDER=registry.redhat.io /ubi9/nodejs-22@sha256:f3a99a68869d161c9aa501e2cdc8071b65fba255991db02b9f890092777f29ee
2+ ARG NODEJS_BUILDER=registry.access. redhat.com /ubi9/nodejs-22@sha256:f3a99a68869d161c9aa501e2cdc8071b65fba255991db02b9f890092777f29ee
33ARG RUNTIME=registry.access.redhat.com/ubi9/nginx-124@sha256:f9f80c202baf79daaeb8638a5f7281581c486b665eac1a31f27c19a96936c438
44
55FROM $NODEJS_BUILDER AS builder
@@ -25,6 +25,7 @@ ARG REMOTE_SOURCE=/go/src/github.com/tektoncd/hub
2525
2626COPY --from=builder $REMOTE_SOURCE/ui/build /opt/app-root/src
2727COPY --from=builder --chown=1001 $REMOTE_SOURCE/ui/image/start.sh /usr/bin/
28+ ENV BASE_PATH="/opt/app-root/src"
2829ARG VERSION=hub-ui-1.20.0
2930
3031USER root
@@ -36,19 +37,9 @@ RUN fips-mode-setup --enable && \
3637 openssl version -a | grep -i fips && \
3738 (openssl md5 /dev/null || echo "MD5 test passed (expected failure in FIPS mode)" )
3839
39-
40- # Use /tmp/config for writable config.js
41- ENV BASE_PATH="/tmp/config"
42- ENV CONFIG_DIR="/tmp/config"
43-
44-
45- USER root
46- # Create writable directory for config.js and ensure proper permissions
47- RUN mkdir -p /tmp/config && \
48- chmod +x /usr/bin/start.sh && \
49- chgrp -R 0 /tmp/config && \
50- chmod -R g=u /tmp/config && \
51- echo 'location = /config.js { alias /tmp/config/config.js; }' > "${NGINX_DEFAULT_CONF_PATH}" /config-location.conf
40+ RUN chmod ugo+rw /opt/app-root/src/config.js && \
41+ chown nginx:nginx /opt/app-root/src/config.js && \
42+ chmod +x /usr/bin/start.sh
5243USER nginx
5344
5445EXPOSE 8080
0 commit comments