fix: Can not use sudo when root

Signed-off-by: shenmo <jifengshenmo@outlook.com>
This commit is contained in:
shenmo 2024-03-30 06:48:13 +00:00 committed by Gitee
parent 97726bebf8
commit 2b311fe7ef
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F

View File

@ -17,6 +17,10 @@ fi
printf "\"%s\" ALL = (root) NOPASSWD:ALL\n" "${container_user_name}" >> /etc/sudoers.d/sudoers
fi
chmod 440 /etc/sudo.conf
chmod 440 /etc/sudoers
chmod 440 /etc/sudoers.d
printf "ACE: Setting up groups...\n"
# If not existing, ensure we have a group for our user.