sudo config
0
sudo is a standard way to give users some administrative rights without giving out the root password. This can also be configured for non root users as well.
1 2 3 |
vi /etc/sudoers and add the following line Syntax: user hosts = (runas) commands |
1 2 |
# user john is allowed to run some_script.sh as jack with no password john ALL = (jack) NOPASSWD: /work/some_script.sh |
1 2 3 |
# Any user part of the opsgrp will be allowed to mount and unmount squashfiles as root with no password. User_Alias OPSACC = %opsgrp OPSACC ALL = (root) NOPASSWD: /bin/mount -t squashfs -o loop *, /bin/umount -t squashfs * |