From bdd2846bda29126fdfd460dbd101b46703d5eaee Mon Sep 17 00:00:00 2001 From: Eric Vaandering Date: Fri, 8 Sep 2023 17:41:43 -0500 Subject: [PATCH] Update CMS Rucio images for Alma9/Rucio 32 --- build-rucio-images.sh | 4 ++-- docker/rucio-daemons/Dockerfile | 8 ++------ docker/rucio-probes/Dockerfile | 4 ++-- docker/rucio-server/Dockerfile | 13 +------------ docker/rucio-ui/Dockerfile | 10 +--------- src/policy/CMSRucioPolicy/__init__.py | 2 +- 6 files changed, 9 insertions(+), 32 deletions(-) diff --git a/build-rucio-images.sh b/build-rucio-images.sh index 49e0e99b..9c9dd70e 100755 --- a/build-rucio-images.sh +++ b/build-rucio-images.sh @@ -2,8 +2,8 @@ set -e -export RUCIO_VERSION=1.31.6 -export CMS_VERSION=${RUCIO_VERSION}.cms3 +export RUCIO_VERSION=32.3.1 +export CMS_VERSION=${RUCIO_VERSION}.cms1 export HARBOR=registry.cern.ch/cmsrucio diff --git a/docker/rucio-daemons/Dockerfile b/docker/rucio-daemons/Dockerfile index aab4a190..a7fc697b 100644 --- a/docker/rucio-daemons/Dockerfile +++ b/docker/rucio-daemons/Dockerfile @@ -22,7 +22,7 @@ RUN /tmp/install_mail_templates.sh RUN python3 -m pip install --no-cache-dir globus-sdk pyyaml ADD docker/rucio-daemons/globus-config.yml.j2 /tmp -RUN mkdir -p /etc/grid-security && ln -s /cvmfs/grid.cern.ch/etc/grid-security/certificates /etc/grid-security/ +RUN rmdir /etc/grid-security/certificates && ln -s /cvmfs/grid.cern.ch/etc/grid-security/certificates /etc/grid-security/certificates ADD docker/rucio-daemons/cms-entrypoint.sh / @@ -39,11 +39,7 @@ ADD docker/rucio-daemons/cms-entrypoint.sh / # Cannot make patch directory unless there are patches RUN mkdir -p /patch -# Eric's patch for FNAL URL problem -# Merged for Rucio 32 -ADD https://patch-diff.githubusercontent.com/raw/rucio/rucio/pull/6097.patch /patch/6097.patch - # Patch for auto approve plugin rucio/pull/6215 -ADD https://raw.githubusercontent.com/dynamic-entropy/rucio/b55a1d62e39565ac0a220b64f42530db96cb468f/0001-Policies-Adding-plugin-hook-for-auto-approval-flow.patch /patch/6203.patch +ADD https://github.com/rucio/rucio/pull/6215.patch /patch/6215.patch ENTRYPOINT ["/cms-entrypoint.sh"] diff --git a/docker/rucio-probes/Dockerfile b/docker/rucio-probes/Dockerfile index a486f2e8..290bb6a1 100644 --- a/docker/rucio-probes/Dockerfile +++ b/docker/rucio-probes/Dockerfile @@ -11,13 +11,13 @@ ARG RUCIO_VERSION FROM rucio/probes:$RUCIO_VERSION # For now CMS versions use python3 explicitly. Can be removed when main container goes to python3 -RUN ln -s /usr/bin/python3 /usr/local/bin/python +#RUN ln -s /usr/bin/python3 /usr/local/bin/python # Add CMS policy package RUN mkdir -p /opt/rucio/policy/CMSRucioPolicy COPY src/policy/CMSRucioPolicy /opt/rucio/policy/CMSRucioPolicy # Make it search the policy directory. Needs a change for python upgrades -RUN echo "/opt/rucio/policy" > /usr/local/lib/python3.6/site-packages/policy.pth +RUN echo "/opt/rucio/policy" > /usr/local/lib/python3.9/site-packages/policy.pth # Temporary additions diff --git a/docker/rucio-server/Dockerfile b/docker/rucio-server/Dockerfile index f3da23b2..d8db5e15 100644 --- a/docker/rucio-server/Dockerfile +++ b/docker/rucio-server/Dockerfile @@ -11,10 +11,6 @@ ARG RUCIO_VERSION FROM rucio/rucio-server:release-$RUCIO_VERSION -RUN yum update -y && \ - yum clean all && \ - rm -rf /var/cache/yum - # Add CMS policy package RUN mkdir -p /opt/rucio/policy/CMSRucioPolicy COPY src/policy/CMSRucioPolicy/ /opt/rucio/policy/CMSRucioPolicy/ @@ -27,17 +23,10 @@ ADD docker/rucio-server/cms-entrypoint.sh / ADD docker/rucio-server/install_mail_templates.sh /tmp/ RUN /tmp/install_mail_templates.sh -# Might get recreated if apache was upgraded -RUN rm -f /etc/httpd/conf.d/welcome.conf /etc/httpd/conf.d/userdir.conf /etc/httpd/conf.d/ssl.conf - # Cannot make patch directory unless there are patches RUN mkdir -p /patch -# Eric's patch for FNAL URL problem -# Merged for Rucio 32 -ADD https://patch-diff.githubusercontent.com/raw/rucio/rucio/pull/6097.patch /patch/6097.patch - # Patch for auto approve plugin rucio/pull/6215 -ADD https://raw.githubusercontent.com/dynamic-entropy/rucio/b55a1d62e39565ac0a220b64f42530db96cb468f/0001-Policies-Adding-plugin-hook-for-auto-approval-flow.patch /patch/6203.patch +ADD https://github.com/rucio/rucio/pull/6215.patch /patch/6215.patch ENTRYPOINT ["/cms-entrypoint.sh"] diff --git a/docker/rucio-ui/Dockerfile b/docker/rucio-ui/Dockerfile index e281447d..81eb7252 100644 --- a/docker/rucio-ui/Dockerfile +++ b/docker/rucio-ui/Dockerfile @@ -10,10 +10,6 @@ ARG RUCIO_VERSION FROM rucio/rucio-ui:release-$RUCIO_VERSION -RUN yum update -y \ - && yum clean all \ - && rm -rf /var/cache/yum - # Add CMS policy package RUN mkdir -p /opt/rucio/policy/CMSRucioPolicy COPY src/policy/CMSRucioPolicy /opt/rucio/policy/CMSRucioPolicy @@ -28,12 +24,8 @@ ENV RUCIO_CA_PATH="/cvmfs/grid.cern.ch/etc/grid-security/certificates" # Cannot make patch directory unless there are patches RUN mkdir -p /patch -# Eric's patch for FNAL URL problem -# Merged for Rucio 32 -ADD https://patch-diff.githubusercontent.com/raw/rucio/rucio/pull/6097.patch /patch/6097.patch - # Patch for auto approve plugin rucio/pull/6215 -ADD https://raw.githubusercontent.com/dynamic-entropy/rucio/b55a1d62e39565ac0a220b64f42530db96cb468f/0001-Policies-Adding-plugin-hook-for-auto-approval-flow.patch /patch/6203.patch +ADD https://github.com/rucio/rucio/pull/6215.patch /patch/6215.patch ADD docker/rucio-ui/cms-entrypoint.sh / ENTRYPOINT ["/cms-entrypoint.sh"] diff --git a/src/policy/CMSRucioPolicy/__init__.py b/src/policy/CMSRucioPolicy/__init__.py index 069c85ef..a9d27375 100644 --- a/src/policy/CMSRucioPolicy/__init__.py +++ b/src/policy/CMSRucioPolicy/__init__.py @@ -4,7 +4,7 @@ from CMSRucioPolicy.algorithms import lfn2pfn, auto_approve -SUPPORTED_VERSION = ["1.30", "1.31"] +SUPPORTED_VERSION = ["1.30", "1.31", "32"] def get_algorithms():