From a83e0076d0f28becfb964b9aedcd5362d9c8f31f Mon Sep 17 00:00:00 2001 From: Daniele Dal Santo <dal.santo.daniele@cern.ch> Date: Wed, 27 Nov 2024 17:55:33 +0100 Subject: [PATCH] s6 script 'finish' --- api/root/etc/s6-overlay/s6-rc.d/run-service/finish | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100755 api/root/etc/s6-overlay/s6-rc.d/run-service/finish diff --git a/api/root/etc/s6-overlay/s6-rc.d/run-service/finish b/api/root/etc/s6-overlay/s6-rc.d/run-service/finish new file mode 100755 index 0000000..41f0b9d --- /dev/null +++ b/api/root/etc/s6-overlay/s6-rc.d/run-service/finish @@ -0,0 +1,12 @@ +#!/command/with-contenv bash + +ITK_UID=$(id -u itk) + +# Check if the UID is different from 1111 +if [ "$ITK_UID" -ne 1111 ]; then + echo "Taking posession of /workspace with 'itk' UID $ITK_UID." + demiown -R itk:itk /workspace +else + echo "The user 'itk' has UID 1111, meaning it is probably not cloning your local UID." +fi +echo "PANDA" -- GitLab