Adding updated code that should work with the latest version of Vagrant (1.6.x).