vagrant.sh 686 B

1234567891011121314151617181920
  1. #!/usr/bin/bash -x
  2. # adjust ssh for vagrant
  3. sed -i "/^#\?PasswordAuthentication/d" /etc/ssh/sshd_config
  4. sed -i "/^#\?PermitRootLogin/d" /etc/ssh/sshd_config
  5. echo "PasswordAuthentication no" >> /etc/ssh/sshd_config
  6. echo "PermitRootLogin yes" >> /etc/ssh/sshd_config
  7. # install VirtualBox Guest Additions
  8. # @link: https://wiki.archlinux.org/index.php/VirtualBox
  9. pacman -Sy --noconfirm virtualbox-guest-utils nfs-utils
  10. echo -e 'vboxguest\nvboxsf\nvboxvideo' > /etc/modules-load.d/virtualbox.conf
  11. # enable related virtualization and networking services
  12. systemctl enable vboxservice.service
  13. systemctl enable rpcbind.service
  14. # Clean the pacman cache to minify image
  15. yes | pacman -Scc
  16. sync