run only when env is set

This commit is contained in:
aptalca 2025-05-16 12:38:09 -04:00
parent f0fd6dab33
commit 92d4e80fa1
No known key found for this signature in database
GPG Key ID: BE36CFFB9FD85548

View File

@ -1,7 +1,7 @@
#!/usr/bin/with-contenv bash
# shellcheck shell=bash
if [[ -z ${LSIO_NON_ROOT_USER} ]]; then
if [[ -z ${LSIO_NON_ROOT_USER} ]] && [[ -n ${ATTACHED_DEVICES_PERMS} ]]; then
FILES=$(find ${ATTACHED_DEVICES_PERMS} -print 2>/dev/null)
for i in ${FILES}; do