- in
/etc/sudoers
# Allows user 'myuser' to reboot, update, upgrade, and remove.
myuser ALL=NOPASSWD:/sbin/reboot
myuser ALL=NOPASSWD:/usr/bin/apt-get update
myuser ALL=NOPASSWD:/usr/bin/apt-get -y upgrade
myuser ALL=NOPASSWD:/usr/bin/apt-get -y autoremove
User may not be in sudoers.