-
-
Save fr34k8/77a3c1e7e4ad387db250 to your computer and use it in GitHub Desktop.
using augeas to add user to sudoers
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
augtool -s set /files/etc/sudoers/spec[user='ubuntu']/user ubuntu | |
augtool -s set /files/etc/sudoers/spec[user='ubuntu']/host_group/host ALL | |
augtool -s set /files/etc/sudoers/spec[user='ubuntu']/host_group/command ALL | |
augtool -s set /files/etc/sudoers/spec[user='ubuntu']/host_group/command/runas_user ALL | |
augtool -s set /files/etc/sudoers/spec[user='ubuntu']/host_group/command/tag NOPASSWD |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment