Last active
August 29, 2015 14:08
-
-
Save BernardoSilva/472d28c710e7d56f1f6b to your computer and use it in GitHub Desktop.
How to remove vagrant up password prompt
This file contains hidden or 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
# This is working for vagrant 1.6.x | |
# If you have any problems, add a comment. | |
$ sudo visudo | |
# Paste this and save. | |
# let vagrant set up NFS shares without password prompt | |
Cmnd_Alias VAGRANT_EXPORTS_ADD = /usr/bin/tee -a /etc/exports | |
Cmnd_Alias VAGRANT_NFSD = /sbin/nfsd restart | |
Cmnd_Alias VAGRANT_EXPORTS_REMOVE = /usr/bin/sed -E -e /*/ d -ibak /etc/exports | |
%admin ALL=(root) NOPASSWD: VAGRANT_EXPORTS_ADD, VAGRANT_NFSD, VAGRANT_EXPORTS_REMOVE | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment