Fixed some SUDO_USER instances.

This commit is contained in:
Scott Duensing 2025-06-08 19:56:19 -05:00
parent 1592e3a3c6
commit 48cc918251

View file

@ -101,8 +101,8 @@ function configureMachine() {
# Compile root update script so it can be suid.
shc -S -f /home/${USER}/unsafe-update.sh
mv -f /home/${USER}/unsafe-update.sh.x /home/${USER}/unsafe-update-root.sh.x
sudo chown root:root /home/${SUDO_USER}/unsafe-update-root.sh.x
sudo chmod u+s /home/${SUDO_USER}/unsafe-update-root.sh.x
sudo chown root:root /home/${USER}/unsafe-update-root.sh.x
sudo chmod u+s /home/${USER}/unsafe-update-root.sh.x
rm /home/${USER}/unsafe-update.sh.x.c
# Add auto update icon to autostart.
@ -137,4 +137,4 @@ if [[ ${EUID} -eq 0 ]]; then
fi
# All the config is in a function so we can stream this script from forge.duensing.digital.
configureMachine 2>&1 | tee /home/${USER}/configureMachine.log
configureMachine 2>&1 | tee /home/${USER}/install.log