Hi all, a quick update.
Vagrant.configure("2") do |config|
config.ssh.forward_agent = true
config.vm.synced_folder "../django", "/django", nfs: true
config.vm.network "private_network", ip: "1.2.3.4"
end
If we choose to compile the box with a Vagrantfile approximating the above, then getting a vagrant image would be as simple as:
mkdir djangobox
cd djangobox
vagrant init djangoproject/django-box-1.11
vagrant up
No need for cloning the djangobox repository at all, but does still require the image to be installed in a folder beside the django directory.
There's a further step we could go to, which would be bundling only the Vagrantfile within the django repo. It'd look something like this (provided we bundle the previous Vagrantfile within the image):
Vagrant.configure("2") do |config|
config.vm.synced_folder ".", "/django", nfs: true
end
We might want to play with that a bit more to be solid on linux/windows/osx, but it removes the concept of compiling a system and places it within the django-box repo, but still allows a user to checkout django, and bring up a VM immediately to do testing. I'm liking this avenue a lot more than I had previously, because it only involves bundling a Vagrantfile and not the entire ansible roles needed to compile it.
I should say that I'm OK with waiting and proving that this project has some following before moving down that road. No point bundling a Vagrantfile if no one is going to use it. But I can see the value and simplicity now. In the mean time, I'll try and get around to updating the Wiki to point people to the django-box image, and the various docs around the place.
Thanks