Advertisement
andmalv

[Tip] No pedir contraseña en un comando o Script especifico

Mar 22nd, 2016
88
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 0.40 KB | None | 0 0
  1. Sintaxis
  2.         echo "$USER ALL=(ALL) NOPASSWD: [comando|Script]" | sudo tee -a /etc/sudoers
  3.  
  4. Ejemplos
  5.         echo "$USER ALL=(ALL) NOPASSWD: /usr/bin/bleachbit" | sudo tee -a /etc/sudoers
  6.    
  7.         echo "$USER ALL=(ALL) NOPASSWD: /sbin/shutdown, /sbin/reboot, /sbin/halt" | sudo tee -a /etc/sudoers
  8.        
  9.         echo "$USER ALL=(ALL) NOPASSWD: ${HOME}/Scripts/Script.sh" | sudo tee -a /etc/sudoers
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement