Improve the Ruby code in Vagrantfile

I improved the Ruby code in Vagrantfile a bit.