News for hackers. Stuff that matters.
Re:How is Docker.io different from a normal virtual machine? by bobf on Thursday September 12, 2013 @11:51PM (#6378480)
Docker doesn't add a whole lot over what basic Linux containers (lxc and vserver) have offered for years. Having said that, the main benefit to Docker is a change in viewpoint from "virtual machine" to "application". Docker aims to make applications portably deployable to any Docker-machine. Since Docker uses lxc (aka Linux containers), it helps to understand a little how containers are different from other virtualization.

Conceptually, they are similar to Linux's chroots or FreeBSD's jails, which offer process isolation. Basically, they work with a lightweight virtual machine instead of a single process. Containers have lower overhead - they are virtualizing on the operating system level. Other virtualization technologies like Xen and KVM work on the CPU level, and provide a fully virtualized hardware setup to the virtual machine[s].

Re:How is Docker.io different from a normal virtual machine? by FreeBSD-user on Friday September 13, 2013 @02:38AM (#6379014)
To be honest I've never worked out why Docker gets so much press. If you use the Ezjail utility to configure and manage FreeBSD jails you have been able to do most of the things Docker does for years (stacked fs using unionfs, templates/flavours, snapshots, export/import etc) and this seems like a much simpler and more stable solution. The networking stuff is also easy using pf.
Re:How is Docker.io different from a normal virtual machine? by danieldk on Friday September 13, 2013 @04:03AM (#6379233)
There's also Solaris Containers, which leverages ZFS snapshots, etc.:

http://en.wikipedia.org/wiki/Solaris_Containers

Of course, Solaris is even more despised by some people since they changed hands.

I think Docker appeals more to people, because:

- It's on Linux, which is more popular than FreeBSD or Solaris.

- It's very easy to set up and configure.

- Integration with Puppet et al.

- The have great marketing :).

Re:How is Docker.io different from a normal virtual machine? by dmpk2k on Friday September 13, 2013 @06:20AM (#6379518)
Just a small reminder that you don't need to touch Solaris specifically. There's a heavily-developed OSS fork named illumos out there too. Some of illumos' distros are nicer than Solaris ever was.
Re:How is Docker.io different from a normal virtual machine? by kordless on Friday September 13, 2013 @01:16PM (#6381765)
All hail the whale.
Re:How is Docker.io different from a normal virtual machine? by justincormack on Friday September 13, 2013 @03:12AM (#6379111)
Because almost no one around here uses FreeBSD it seems.
Re:How is Docker.io different from a normal virtual machine? by jmspring on Friday September 13, 2013 @03:43AM (#6379184)
Some of us do, when appropriate.

Docker took a technology known to many that setup/admin/manage machines, added some fluff, made things simpler, and marketed the idea.

In a crowd that might spend more time thinking about nodejs and callbacks vs promises or how easily one can tip a rails app up on heroku, existing systems tools for things like jails/virtualization may either be over looked or not a concern.

For every docker, there are people (of which I may be one) that think , "big deal, it is just x". Meanwhile that thing is getting traction and popularity. It might not last, but it is around and making noise now.

Re:How is Docker.io different from a normal virtual machine? by Swizec on Friday September 13, 2013 @05:04AM (#6379334)
"added some fluff, made things simpler, and marketed the idea"

Well what on earth do you need a pre-assembled computer for? You just take some circuit boards and a soldering iron, then assemble everything over the weekend and you have a perfectly good computer. I don't understand why this Apple I thing is so popular, it's nothing special.

Far as I can tell, every successful piece of tech out there can be reduced to "Added some fluff, simplicity, and marketing to an already existing technology"

Re:How is Docker.io different from a normal virtual machine? by gurraman on Friday September 13, 2013 @07:54AM (#6379841)
They also created an operative system (sure, it builds on existing tech but they added a lot more than just fluff).
Re:How is Docker.io different from a normal virtual machine? by mtkd on Friday September 13, 2013 @03:59AM (#6379222)
It is a simple abstraction of something that many people find very complicated - or choose to not spend time understanding / configuring.

(You could say same about Github, Travis etc.)

Re:How is Docker.io different from a normal virtual machine? by lars512 on Friday September 13, 2013 @05:42AM (#6379428)
There's probably some fair value in making things simpler, not to mention value in marketing. If they can form a large community around it through their marketing, then the tooling will rapidly improve. So, the marketing can be a kind of self-fulfilling prophecy.
Re:How is Docker.io different from a normal virtual machine? by derefr on Friday September 13, 2013 @07:15AM (#6379721)
Honestly, I have no idea if the software I write runs on FreeBSD. I know it runs on Linux, and therefore I know I can package it with Docker.

And I think that's the crux of it--do you think anyone would use Heroku if its container environment were FreeBSD-based? I'm guessing not; nobody develops on FreeBSD, so they'd have to test on a separate FreeBSD VM before deploying.

Re:How is Docker.io different from a normal virtual machine? by justincormack on Friday September 13, 2013 @11:25AM (#6381074)
Lots of people seem to develop on Macs, so Linux is a VM to them. And if it runs on a Mac it probably runs on FreeBSD. Joyent seems to be managing with non-Linux containers too.
Re:How is Docker.io different from a normal virtual machine? by FreeBSD-user on Saturday September 14, 2013 @04:30AM (#6385052)
That's a shame, FreeBSD is actually a pretty impressive OS. You should give it a try, mono-cultures aren't a good thing.
Re:How is Docker.io different from a normal virtual machine? by DH61AG on Friday September 13, 2013 @03:12AM (#6379113)
Because Docker is platform agnostic and easy to use. There has always been similar solutions but none of them with such simple interface and setup.
Re:How is Docker.io different from a normal virtual machine? by seiji on Friday September 13, 2013 @12:30AM (#6378640)
Containers are not virtual.

Containers aren't emulating anything or translating anything. They let your partition out system and network resources as you see fit (or to protect users from abusing each other) without running kernels within kernels and other performance killing hokum.

Re:How is Docker.io different from a normal virtual machine? by seldo on Friday September 13, 2013 @01:18AM (#6378803)
Indeed. One way you can use Docker in production[1] is one container per machine: even when you're not using the containers to split resources, the ability to snapshot and move an application and all of its dependencies in a single, lightweight, easily deployed package is very exciting. And because there's no translation etc. happening, running a single container is pretty much identical, performance-wise, to running it directly on the machine[2].

[1] dotCloud don't actually yet recommend running Docker in production, but if you did...

[2] This was part of what Mailgun (part of Rackspace) said in their presentation at the Docker workshop in SF today.

Re:How is Docker.io different from a normal virtual machine? by jaytaylor on Friday September 13, 2013 @01:28AM (#6378827)
You can actually do the same thing with LXC containers; it is trivial to rsync a snapshot or compressed archive of a snapshot to another host machine and run it there.
Re:How is Docker.io different from a normal virtual machine? by pestaa on Friday September 13, 2013 @01:55AM (#6378893)
Why the downvote? Simple tools always work well. If you want process isolation on Linux, LXC + rsync might as well be the simplest route.
Re:How is Docker.io different from a normal virtual machine? by mritun on Friday September 13, 2013 @02:14AM (#6378950)
Docker is based on LXC containers. It bundles it's own management layer that replaces the "rsync" solution you propose.
Re:How is Docker.io different from a normal virtual machine? by pekk on Friday September 13, 2013 @12:01PM (#6381309)
The point of Docker is the standardized container/management interface. Of course you can write your own, but then it's not too standardized is it?
Re:How is Docker.io different from a normal virtual machine? by jaytaylor on Friday September 13, 2013 @05:52PM (#6383418)
What you describe is standardizing complexity where a simple solution is available. Naturally, when feasible, I prefer keeping things simple and straightforward enough that standardization is unnecessary.

Standardization for the sake of standardization is not defensible.

Re:How is Docker.io different from a normal virtual machine? by jaytaylor on Friday September 13, 2013 @01:58AM (#6378904)
Anything not pro-docker usually gets downvoted by shykes and his ring of cronies.
Re:How is Docker.io different from a normal virtual machine? by aegiso on Friday September 13, 2013 @02:22AM (#6378979)
There's definitely hype behind Docker, but this is a ridiculous accusation.
Re:How is Docker.io different from a normal virtual machine? by jaytaylor on Friday September 13, 2013 @02:55AM (#6379057)
People do crazy things for money.
Re:How is Docker.io different from a normal virtual machine? by pekk on Friday September 13, 2013 @12:06PM (#6381331)
You have rationalized away the people who disagree with you by making them into a conspiracy. I don't know about said ring of cronies, but I guarantee that many downvoters are not associated.
Re:How is Docker.io different from a normal virtual machine? by jaytaylor on Friday September 13, 2013 @05:41PM (#6383364)
My claim seems validated. Just look at both of my comments in this thread; they've both been downvoted deep into the negatives.
Re:How is Docker.io different from a normal virtual machine? by kbutler on Friday September 13, 2013 @06:36PM (#6383620)
My downvotes because the comments were disparaging and lacked proof. My only Docker affiliation is reading a bit about it lately. I had to search the page to see who shykes is.
Re:How is Docker.io different from a normal virtual machine? by darklajid on Friday September 13, 2013 @05:23AM (#6379383)
Regarding your first footnote:

Is there an explanation why 'in production' is actively discouraged? Is that a limitation of the underlying lxc stuff?

I ask, because the interesting parts of docker _for me_ seem to be focused on the setup, deployment - and not the runtime. So if I create a working image and want to use that in production, wouldn't docker become passive as soon as I run that thing?

What's the danger here?

Re:How is Docker.io different from a normal virtual machine? by pekk on Friday September 13, 2013 @12:08PM (#6381348)
I expect the danger is that someone will lose money and blame the developers for as-yet unforeseen issues which can only be smoked out after a few years of heavy use. But a specific danger would be interesting to hear.
Re:How is Docker.io different from a normal virtual machine? by shykes on Friday September 13, 2013 @02:12PM (#6382085)
Docker maintainer here. That's basically it. There's no specific danger that we're worried about - just engineering best practices.

As long as we're not comfortable operating Docker at large scale ourselves (we run quite a lot of containers in production at dotCloud), we won't recommend that others do it.

Re:How is Docker.io different from a normal virtual machine? by contingencies on Friday September 13, 2013 @05:30AM (#6379396)
Containers are not virtual.

They belong to a category of virtualization known as 'container-based virtualization' which implements virtualized perspectives of the system within the host kernel, effectively dividing the system in to multiple systems (from the perspective of the affected processes). That is unquestionably virtualization.

I believe a statement closer to what you were looking to express was containers are not running under a hypervisor.

LXC still creates a performance impact, depending upon which options are selected, with particular note for the various memory accounting options. However, that impact is far lower than a hypervisor. In addition, startup times are vastly reduced since the kernel bootstrap and hardware detection concerns are rendered unnecessary.

Re:How is Docker.io different from a normal virtual machine? by lrem on Friday September 13, 2013 @08:32AM (#6380004)
I don't know about LXC, but back in the day, the impact of linux-vserver was within bounds of measurement error. Since then I have been using it reflexively on any server I touch, even if it ends with only one container.
Re:How is Docker.io different from a normal virtual machine? by mtam on Friday September 13, 2013 @03:12AM (#6379112)
Yes, Docker builds on top Linux containers but they seem to be releasing some neat features that make containers easier to use, manage, and reuse. For example: The docker-cluster project, https://github.com/globocom/docker-cluster seems very interesting as it might allow you to abstract the host with a cluster/logical group. Having this abstraction is key if you are running docker on a non-virtualized (bare metal) host because it provides some level of fault-tolerance against hardware failures. Can you do that with Linux Containers?

Edit: I just realized that docker clusters is not being developed by the docker team

Re:How is Docker.io different from a normal virtual machine? by shykes on Friday September 13, 2013 @04:33AM (#6379271)
If you're interested in cool projects built on top of Docker, take a look at http://github.com/dockerforge, it has a nice list.
Re:How is Docker.io different from a normal virtual machine? by passfree on Friday September 13, 2013 @03:37PM (#6382613)
You can also have a look at VxDocker https://github.com/websecurify/node-vxdocker
Re:How is Docker.io different from a normal virtual machine? by rdtsc on Friday September 13, 2013 @10:20AM (#6380631)
Exactly a point that is important to make is that LXC VMs are bound to same kernel and architecture as host machine.

But then the "fix" is to have a farm of host machines of all supported configuration of kernel and architecture (mostly just Linux distributions). Migration and load balancing will be more rigid as can't move any machine to any host. Some hosts

What is not doable it seems is say supporting windows guests, older Linux kernels etc. That argues for a hybrid approach with a controller API on top that uses KVMs or Xen hypervisors alongside LXC

Re:How is Docker.io different from a normal virtual machine? by derefr on Friday September 13, 2013 @07:57PM (#6383992)
Why are you building your applications to need specific kernels/distributions? That sort of goes against the spirit of 12-factor apps -- if a particular kernel/OS is part of the app, put it in the app. (Thus, use a full VM.) Docker is for when that isn't the case.
Re:How is Docker.io different from a normal virtual machine? by rdtsc on Friday September 13, 2013 @08:35PM (#6384120)
Well because for one it was tested and developed on one distribution. Because one might have chosen to use system level packaging instead of copying code to /var/local or /opt. So it is taking advantage of transactional updates to the system, transitive dependencies, pre-post install scripts. The downside it being tied to a packaging system.

Also certifications. Government agencies for example will accept only certain OS-es have been certified. Sometimes it is simply because there are features on some distribution or kernels that aren't in others.

Re:How is Docker.io different from a normal virtual machine? by derefr on Friday September 13, 2013 @09:13PM (#6384215)
Basically, what you're saying is, Docker sucks at being a foreign porting target for things developed for some other system. Well, everything sucks at being a foreign porting target. Don't do that. Test and develop your app using Docker. Install your app into the container using Docker. These are the things Docker is for--it's a development aid, not some performance-boosting alternative to virtualization. You have to integrate it into your app's workflow; you can't just tack it on as some final "and then we also generate a Docker container version of our app" step at the end, or you lose every advantage Docker gives you.

Docker is made to, basically, develop apps the same way you develop them when using a PaaS like Heroku (or, more specifically, a PaaS like Dotcloud): have a frozen base+runtime image; compose a "slug" consisting of exactly the stuff in your build/ directory and layer it on top; and tell the target host to launch it. To upgrade, create a new slug, and rolling-restart your old instances into new instances.

Re:How is Docker.io different from a normal virtual machine? by rdtsc on Friday September 13, 2013 @09:33PM (#6384269)
I think you misunderstood. I never said Docker sucks. I said there are ways to handle various kernel+distro combinations with Docker just by having various hosts that runs those kernel+distro combinations, that was in defense of LXC.

I haven't used Docker yet, I am only familiar with LXC so far so I was commenting on that. If one does have a uniform or a restricted set of platforms that can also act as LXC hosts then well why not take it and run with it. It is more efficient and that might translate into performance and cost savings.