Tug: Use Docker for development
github.com
github.com
I quite like Vagrant myself but my primary complaint is that I seem to spend a lot of time waiting for VMs to start up and run a lot of bootstrap code.
You're linking to the wrong thing. This is the proper comparison to Tug: https://docs.vagrantup.com/v2/docker/index.html
Re your complaint: with the Docker provider, Vagrant only spins up _one_ VM (if you're not on Linux). After that, `vagrant up` just executes `docker` directly so there is no waiting around for bootstrapping. It even detects if you have Docker installed locally or not to decide whether it needs to run in the VM or not. And, if you're on Linux, it doesn't use a VM at all, unless you're on a kernel that doesn't support Docker, in which case it automatically/transparently starts the VM.
EDIT: Responding to David's comment below since it would go to deep: Vagrant is basically the same here. It doesn't require Dockerfiles, you can just spin up images.
Tug is a simple tool that I wrote to scratch a personal itch around working with dockerized applications and trying to optimize for startup speed and writing as absolutely little configuration as possible.
I'm hoping to get a few other people to try it out and let me know if it works for them and if it's useful, especially given the existence of so many other tools of this nature.
VirtualBox is not "preferred" as much as its the default, because its the easiest to acquire. For example, on Windows 8+, Hyper-V is actually the default for Vagrant because its built in to almost every installation of Windows (Vagrant checks).
Vagrant really just chooses whatever appears to be available on your system.
If you don't care about benefitting from Docker specifically, then it's worth evaluating Vagrant for environment devs, it's a good tool.
Please keep in mind that this is a very alpha project still under heavy development. If you try it I'd love to hear how it goes and whether or not it's useful for you (you can reach me at david@nitrous.io or find me on Freenode as ddollar).
If a line starts with "docker/" the rest is assumed to be a docker image tag.
I wouldn't describe tug as less powerful, it's less complicated from my usage of it. For each service I only need to write one line and tug will figure out (from the Dockerfile) what needs to be forwarded.
The mind blowing moment is when you're using boot2docker (or any case where Docker isn't local) and it still forwards the ports to your local (127.0.0.1) host.
That's easily achieved with a Vagrantfile for your Docker VM...
With tug any port you expose on the containers is brought locally to you instantly.
* Less verbose configuration, tries to assume sensible defaults
* Works with apps that do not yet themselves have a Dockerfile
I guess my question is, why did you guys choose to do that?
If you've got the time I'd love to hear more about your workflow at david@nitrous.io
I don't think entering a container is bad for development, in fact it's a frequent pattern (to run things like you describe rake etc.). With the release of docker exec this becomes easier too. I think of it kind of like bind-mounting a directory in the container to do code editing without having to rebuild- as long as you are using ADD for every stage afterwards that should be fully automated (QA, test, production) then you are in the clear.