Building Shipyard - A Docker Development Environment for Windows and WSL
After moving from macOS to Windows, I needed a better way to manage local development environments with Docker, TLS, and .test domains. Shipyard grew out of that need: a small CLI that lets projects adopt a shared development stack without modifying the repository.
I recently moved from macOS to Windows as my primary operating system at work, for a couple of reasons. We have a couple of Windows-specific applications that I use often enough to make VMs inconvenient, and honestly, I fancied a change.
I've been using Laravel Herd for a long time, and I love the simplicity, however I haven't been solely a developer for a while, so I wanted to be able to "switch off" development-related resource overhead when I wasn't working on code.
WSL was the obvious direction, but Artisan serve is inconvenient when you're working on applications that need to talk to each other.
Laravel Sail runs Artisan serve under the hood, and isn't especially "good" Docker in my opinion, so I discounted that quickly.
I kept coming back to that .test TLD that's just so convenient. I also wanted local TLS. Several things I run expect HTTPS even in development, so not having it simply wasn’t an option.
So, my goals were clear:
- No changes to the repository
- Customisable Dockerfiles, and Docker Compose files
- Local TLS
- .test TLD
- Easy to use day-to-day
This is where Shipyard comes in.
Shipyard is a lightweight CLI that runs a shared Docker stack and allows projects to “adopt” it, giving each project consistent local domains, TLS, and services without requiring changes to the application repository.
"Adopting" a new application is as simple as running shipyard adopt path/to/project. You’re then given a couple of commands to run in PowerShell to generate the TLS certificate.
Then https://your-project.test in your browser will just work.
This isn't intended to be a tutorial (if you'd like that, let me know!), just a quick overview. The source code will be on Github in due course. Shipyard will be open source, released under the MIT licence.
Yes, I could absolutely have made a series of Dockerfiles, and Docker Compose files, and in fact, that's what Shipyard gives you, but wrapped in something just a little nicer.
The idea behind Shipyard is simple: the development infrastructure should live outside the application repository. Projects can adopt a shared stack rather than each repository carrying its own Docker setup.
Development environments are one of those things that quietly absorb a lot of time. Shipyard started simply as a way to reduce friction in my own workflow. If it turns out to be useful for others as well, that’s a nice bonus.