Moving from Vagrant to Vagrant with Docker
I currently use a local dev setup with Vagrant to manage my vm’s per platform. so I have a vm/vagrantfile for wordpress, laravel, static sites etc. I use scotchbox but with a multiple vhost setup with apache on the host machine, synched to my local files. This works, but obviously the performance is not great, especially with so many projects on each vm. I have also played around with just using one vm per project, but I want something better.
I have done some reading about docker, and using vagrant with docker, and would like to go that route. Problem is I keep running into issues, and I have tried several different approaches. I did happen to get a setup going where I used a host vm to attach docker and then spin up a container for Nginx..initially I had some port forwarding issues but resolved that.
My question is, how have some of you went about setting this up? What does your Vagrantfile look like for the host and for the project? What other scripts are you loading? How are you handling multiple projects, file sharing and hostnames?
I have read so many different questions/answers and walkthroughs and none of them outline specifically what I am asking, so any discussion on the topic is greatly appreciated!