#
# This file MUST be edited with the 'visudo' command as root.
#
# Please consider adding local content in /etc/sudoers.d/ instead of
# directly modifying this file.
#
# See the man page for details on how to write a sudoers file.
#
Defaults        env_reset
Defaults        mail_badpass
Defaults        secure_path="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"

# Host alias specification

# User alias specification

# Cmnd alias specification

# User privilege specification
root    ALL=(ALL:ALL) ALL

# Allow members of group sudo to execute any command
%sudo   ALL=(ALL:ALL) ALL

# See sudoers(5) for more information on "#include" directives:

#includedir /etc/sudoers.d
%admin  ALL=(ALL) ALL

# EVTEC
xfc	ALL=NOPASSWD:/sbin/reboot
xfc	ALL=NOPASSWD:/sbin/hwclock
xfc	ALL=NOPASSWD:/sbin/ip link set *

xfc	ALL=NOPASSWD:/bin/date
xfc	ALL=NOPASSWD:/sbin/sysctl vm.drop_caches*

# by adding www-data to the service-operators group, you could delete the systemctl rules,
# but you may need to change the code as the command would only run without sudo.
www-data ALL=NOPASSWD:/bin/systemctl restart *
www-data ALL=NOPASSWD:/bin/systemctl status *
www-data ALL=NOPASSWD:/bin/systemctl reboot
www-data ALL=NOPASSWD:/sbin/reboot
www-data ALL=NOPASSWD:/usr/bin/rauc status *
www-data ALL=NOPASSWD:/usr/bin/rauc install *

%service-operators ALL=NOPASSWD:/usr/sbin/netplan
%service-operators ALL=NOPASSWD:/bin/mount
