This commit is contained in:
Alexandre
2024-01-10 10:30:16 +01:00
parent 6a2a67245c
commit 7ad415381f

View File

@@ -17,8 +17,11 @@ for SCRIPTS in /etc/cont-init.d/*; do
chmod a+x "$SCRIPTS"
else
bashio::log.warning "Script executed with user $(id -u):$(id -g), things can break and chown won't work"
# Disable chown in scripts
sed -i "s/chown /true # chown /g" "$SCRIPTS"
# Disable chown and chmod in scripts
sed -i "s/^chown /true # chown /g" "$SCRIPTS"
sed -i "s/ chown / true # chown /g" "$SCRIPTS"
sed -i "s/^chmod /true # chmod /g" "$SCRIPTS"
sed -i "s/ chmod / true # chmod /g" "$SCRIPTS"
fi
# Get current shebang, if not available use another