* Docker is nice for consistent development and deployment environments, particularly when I'm on a macOS host and I'm doing userspace programming.
* Vagrant is nice for creating a completely hermetic development environment, both on macOS and Linux hosts. My particular use case has been kernelspace programming: it's nice to not have to worry about accidentally taking my host down. Docker can't provide that kind of isolation, since it's still running on the host (or host VM) kernel at the end of the day.
Containers are largely just not a great medium for interactive work, i.e. development. They're great for resident applications that use a single process run via a service account.
I've been using VS Code + its Remote-Containers extension + docker-compose (when needed) and it's absolutely brilliant compared to other options.
I will use Vagrant when I want to avoid Docker in Docker, but I try to stay away from it as much as I can (for local app development).
That said Vagrant is really useful for testing infra, stuff like clusters etc.
On some host operating systems. On others it's a similar speed.
Once WSL came into being we moved everything to docker containers and never looked back.
If you can use containers for local dev, great, but not everyone can or wants to migrate to containers. Vagrant still solves a very important use case.
But I've noticed that it seems like you can skip straight to using docker containers for development environments as well. I'm wondering what other people's experience here is with both or either software.
In my opinion, both still seem like relevant software. When I need an Ubuntu development environment on my Mac, I don't turn to Docker. I think of Vagrant right now, because that's what it was built for. Vagrant is a tool for managing virtual machines and development environments.[2]
[1]: https://www.virtualbox.org/manual/UserManual.html#basic-unat...
[2]: https://www.vagrantup.com/intro/vs/docker
Edit: Thank you for the excellent insights!