Change permissions of sudoers.d file to 0440

This commit is contained in:
Aaron Bull Schaefer 2013-08-25 21:36:50 -07:00
parent e6d4b53462
commit 8a6c736afd

View file

@ -61,6 +61,7 @@ cat <<-EOF > "${TARGET_DIR}${CONFIG_SCRIPT}"
/usr/bin/useradd --password ${PASSWORD} --comment 'Vagrant User' --create-home --gid users vagrant
echo 'Defaults env_keep += "SSH_AUTH_SOCK"' > /etc/sudoers.d/10_vagrant
echo 'vagrant ALL=(ALL) NOPASSWD: ALL' >> /etc/sudoers.d/10_vagrant
/usr/bin/chmod 0440 /etc/sudoers.d/10_vagrant
/usr/bin/install --directory --owner=vagrant --group=users --mode=0700 /home/vagrant/.ssh
/usr/bin/curl --output /home/vagrant/.ssh/authorized_keys https://raw.github.com/mitchellh/vagrant/master/keys/vagrant.pub
/usr/bin/chown vagrant:users /home/vagrant/.ssh/authorized_keys