SUDO With No Password

I use SSH Keys for everything… and generally dont know my password for a linux machine once built. Hence I need to set sudoers correctly.. This is how I do that (for reference).

vi /etc/sudoers

Then make the block look like:

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

(Your just adding NOPASSWD: right before the last ALL)

Tags:

Categories:

Updated: