From 6120a5356f7617a198438e9df0f9c98da7816e4d Mon Sep 17 00:00:00 2001 From: Tony Murray Date: Thu, 22 Jan 2026 13:22:53 -0600 Subject: [PATCH] remove xargs and clear ownership logic --- rootfs/etc/cont-init.d/03-config.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/rootfs/etc/cont-init.d/03-config.sh b/rootfs/etc/cont-init.d/03-config.sh index 973b6b4..f7ab725 100644 --- a/rootfs/etc/cont-init.d/03-config.sh +++ b/rootfs/etc/cont-init.d/03-config.sh @@ -105,7 +105,7 @@ if [ -d "${LIBRENMS_PATH}/html/plugins/Weathermap" ]; then ln -sf /data/weathermap ${LIBRENMS_PATH}/html/plugins/Weathermap/configs fi chown -h librenms:librenms ${LIBRENMS_PATH}/html/plugins/Weathermap/configs - find /data/weathermap ${LIBRENMS_PATH}/html/plugins/Weathermap/output -not \( -user librenms -group librenms \) -print0 | xargs -0 -r chown librenms:librenms + find /data/weathermap ${LIBRENMS_PATH}/html/plugins/Weathermap/output \( ! -user librenms -o ! -group librenms \) -exec chown librenms:librenms {} + fi # cleanup bad symlink: https://github.com/librenms/docker/issues/294#issuecomment-1190389960 @@ -219,7 +219,7 @@ done # Fix perms echo "Fixing perms..." chown librenms:librenms /data/config /data/monitoring-plugins /data/plugins /data/rrd /data/weathermap /data/alert-templates -find /data/logs ${LIBRENMS_PATH}/composer* ${LIBRENMS_PATH}/config.d ${LIBRENMS_PATH}/bootstrap ${LIBRENMS_PATH}/logs ${LIBRENMS_PATH}/storage ${LIBRENMS_PATH}/vendor -not \( -user librenms -group librenms \) -print0 | xargs -0 -r chown librenms:librenms +find /data/logs ${LIBRENMS_PATH}/composer* ${LIBRENMS_PATH}/config.d ${LIBRENMS_PATH}/bootstrap ${LIBRENMS_PATH}/logs ${LIBRENMS_PATH}/storage ${LIBRENMS_PATH}/vendor \( ! -user librenms -o ! -group librenms \) -exec chown librenms:librenms {} + chmod ug+rw /data/logs /data/rrd ${LIBRENMS_PATH}/bootstrap/cache ${LIBRENMS_PATH}/storage ${LIBRENMS_PATH}/storage/framework/* # Check additional Monitoring plugins