Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save ingmarioalberto/3cf05baaa010e63760745f01218511a5 to your computer and use it in GitHub Desktop.
Save ingmarioalberto/3cf05baaa010e63760745f01218511a5 to your computer and use it in GitHub Desktop.
acordeones: visudo sudo config file
root ALL=(ALL:ALL) ALL
| | | | |
| | | | +-Command or All commands (without password?
| | | | add NOPASSWD: before keyword)
| | | +------Run cmd as Group or All groups
| | +----------Run cmd as User or All users
| +---------------Host or All hosts
+--------------------sys user or "sys %group" or "user aliases" to apply rule
User_Alias ~= groups (first letter must be uppercase)
User_Alias Chismosos = eder, hector, chucho
Cmnd_Alias ~= commands groups
POWER = /sbin/shutdown, /sbin/halt, /sbin/reboot, /sbin/restart
ex: Chismosos ALL = POWER
Runas_Alias ~= run as whatever user exists
WEB = www-data, apache
ex: Chismosos ALL = (WEB) ALL
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment