Hacker News new | ask | show | jobs
by amitdugar 4751 days ago
I am new to this.

Docker lets us use same set of configs so that we have uniform server setup everywhere right ? How is this different from Vagrant ? Or did I miss something ?

2 comments

They are complementary. Vagrant is a tool for configuring VMs for development.

Docker is a tool for packaging your code and all its dependencies into a portable lightweight container. You can deploy docker containers across VMs and physical machines, regardless of how they are configured. Some of your machines may be configured with Vagrant, some of them with Puppet, Chef, Salt or any number of home-made tools. But all of them can run your docker container exactly as you built it, byte for byte.

Interesting. Does this also mean you can run your container on both 64 and 32 bit platforms?
Yes, although only x86_64 is officially supported at the moment, that should change very soon.
Looks like it's built around KVM (Kernel Virtualization Modules), i.e. "containers", rather than full-blown virtual machine emulation like Xen or VirtualBox/Vagrant.

It appears to be a configuration management / deployment tool for KVM containers. New to me too, gonna dive in and check it out.

KVM is full machine emulation (i.e. hardware is emulated, and you can run different kernels inside the guests than you do on the host).

Docker uses LXC which is like BSD Jails, most of the advantages of VMs but you don't have to emulate a whole system, there's only one kernel atop which multiple containers/jails can run different software and have thorough isolation. Very fast and light-weight, but you can't run different OS kernels.

nitpicking: KVM stands for "Kernel Virtual Machine". It's an implementation of virtual machines, just like VirtualBox or VMWare. Containers are completely separate from KVM.
That's a great way to describe it. It's a "lightweight" VM that is created per process.