A Vagrant/Virtualbox development environment

Hey all, we recently got started working with kirby and have developed a Vagrant based dev environment that I think is
pretty nice.

I thought I’d share it with you all.

Comments, Improvements, and above all, Pull Requests are greatly appreciated.

What’s the point using vagrant when all you have to do is php -S localhost:4000? Compared to the latter, that’s a huge overhead imho…

For me the benefit is having the same environment for development as for production.

This avoids surprises when php versions aren’t the same or modules aren’t available,

It also eliminates the “works for me” bugs where one dev has a different environment than another.

Lastly it’s a three step install, regardless of host operating system.

If php’s internal server works for you, great!

… which would require everyone to modify their Vagrantfile first, right? Apart from imagick / gd, what big differrences are there to encounter in production? PHP version, well … upload everything, aaaand done!

For larger projects based on eg typo3 I get using Vagrant, but Kirby? Still surprised every time I read about it, but I’ll try it out anywhoozle :slight_smile:

The only reason i use Vagrant is because I work with several systems, not just Kirby. And i like a multi site setup. If I only worked with Kirby I would just use the built in stuff, or Valet. Much simpler. Laravels Homestead Vagrant box is my current favourite. Very easy to use.

I like the fact you have SSL working in your box though, I have struggled to get the going on Homestead.

You should also take into account that integrating third-party software like mailcatcher or various testing suits can be managed much easier that way. Also, if you are deploying to NGINX, that’s a whole other story, too.

1 Like