Simple Docker LAMP stack

I’ve been a vagrant user for years, using Virtual Box as the provider. This has allowed identical setups on my Mac, Windows and Linux boxes, which creates an unbroken workflow if I have to switch machines. But when I upgraded to the M1 Mac Mini I’m currently using, I realized the setup wasn’t going to work any more.

VirtualBox does not work on Apple Silicon, and Oracle has said that they have no plans to release an ARM compatible version of VirtualBox. So… goodbye Vagrant on Mac. So I started looking for alternatives. Sure, XAMPP works on both x86 and M1 macs, but XAMPP on Mac is a completely different beast from XAMPP on Windows. It wasn’t perfect.

So I looked at Docker again. I’ve used Docker containers in the past, but not consistently. DevilBox was quite nice, for example, but had way more stuff than I needed. I guess I found containers a little too complex to setup and use for the work I was doing. But necessity is the mother of software upgrades, as they say, so I took another look. Turns out, it’s not so complex, and the end result works equally well on Apple Silicon as it does on x86.

This is mostly aimed at students in the WDD program at the University of Winnipeg, but feel free to use it if you like.

I’ve created a single container containing two images: Apache/PHP and MySQL Server. It works on both Mac (m1 or Intel) and Windows.

Grab it on GitHub: