diff --git a/Dockerfile.rocky9 b/Dockerfile.rocky9 index f0f95647..8a0d24ce 100755 --- a/Dockerfile.rocky9 +++ b/Dockerfile.rocky9 @@ -909,6 +909,33 @@ RUN git clone ${MIG_GIT_REPO} migrid.git && \ rm -rf migrid.git/ && \ echo "migrid version: ${MIG_GIT_REPO} ${MIG_GIT_BRANCH} ${MIG_GIT_REV}" > ./active-migrid-version.txt +# With the repository available, we have access to definitions and scripts +# within it. As such, we can gather any dependencies defined there. + +RUN if [ -e "$MIG_ROOT/envhelp/scripts/expand_sources.py" ]; then \ + "$MIG_ROOT/envhelp/scripts/expand_sources.py" --use-wget; fi + +# In a per-feature requirements file future, we will have something generic +# across the features here. For now, perform one-off logic to arrange for a +# package of migrid UX that we can install; then do so. + +USER root +ENV FEATURE_MIGUX="$MIG_ROOT/mig/install/requirements/migux-requirements.txt" +RUN if [ -e "$FEATURE_MIGUX" ]; then \ + python3 -m pip install dumb-pypi; \ + dumb-pypi \ + --package-list "$MIG_ROOT/envhelp/staging/.packages.lst" \ + --packages-url='../..' \ + --output-dir "$MIG_ROOT/envhelp/staging"; \ + python3 -m pip install \ + -r "$FEATURE_MIGUX" \ + --extra-index-url="$MIG_ROOT/envhelp/staging/simple"; \ + fi +USER $USER + +RUN if [ -e "$MIG_ROOT/mig/install/postinstall/migux-postinstall" ]; then \ + "$MIG_ROOT/mig/install/postinstall/migux-postinstall"; fi + #------------------------- next stage -----------------------------# FROM --platform=linux/$ARCH download_mig AS install_mig @@ -1291,6 +1318,10 @@ RUN cp generated-confs/MiGserver.conf $MIG_ROOT/mig/server/ \ && cp generated-confs/static-skin.css $MIG_ROOT/mig/images/ \ && cp generated-confs/index.html $MIG_ROOT/state/user_home/ +# With the configuration in hand, prime any configured templates +RUN python3 -m mig.lib.templates prime \ + -c $MIG_ROOT/mig/server/MiGserver.conf + # Site conf for js helpers including status page and auth options on index page RUN [ -e "$MIG_ROOT/mig/images/site-conf-${DOMAIN}.js" ] || \ cp -a $MIG_ROOT/mig/images/site-conf-${EMULATE_FQDN}.js \