Hacker News new | past | comments | ask | show | jobs | submit login

Same here. Docker is a collection of anti-patterns while LXC is pretty lean and we use it in production for long time withou issues.



A screwdriver seems like an anti-pattern when you are trying to hammer in a nail with it. Because of the buzz around it Docker suffers from people trying to use it to solve problems it wasn't intended to.

I use both Docker and LXC but for very different use cases. I find both to be great tools when used to solve the problems they were intended for.


Can you elaborate on the different use cases? I've seen a bunch of LXC/Docker comparisons, but they focused on features.


Lxc is a system container Docker is an application container.

Use lxc in place of a VM, where you might want to login or even have others login. It has the same problem as a regular system, snowflakes. Changes can be made that might cause an application to behave differently if there are multiple deployments or you have to rebuild.

Docker is for having a consistent application environment so your app behaves exactly the same every time it's deployed.

I use lxc and did before docker. It took a while for me to accept docker. It takes understanding the difference.


This does not make sense. There’s no such thing as a system containter. You can absolutely leverage lxc instead of docker if you want to.

The major difference is that docker gives you 1 process by container and has 1) nailed down a container definition fornat 2) the registry for images.

So Docker makes the whole container thing more accesible, but in the end both rely on the same kernel features + overlay filesystems.


A “system” container here means a container running an init so it can be multi process and operate like a lightweight vm.


The fact that there are so many base images including an init system and even Docker now includes a small init that you can activate with a command line switch might give an indication that many people are using Docker for "system containers".


if you’re looking at the kernel features used (namespaces, cgroups, etc) containers are multiprocess (even with docker you can go attach into the container and look at things).

This may be semantics, but the first process in the container is an “init” regardless if it’s a proper init or just a process.

As far as light-weight VMs: containers are supposed to be lightweight VMs (But defining lightweight can be challenging)


Docker is designed to be a 'application' container - 1 process per container.

LXC is designed to be a 'system' container - an entire OS except the Kernel per container.

People mis-use tools all the time - that doesn't change their original design or intended use.


let's agree to disagree on this one. I am not sure that system and application container are or should be different, but it's okay if we have a different opinion.


https://linuxcontainers.org

You might disagree, but the distinction is meaningful within the community.


Without giving us a hint of what those anti-patterns are, your comment is quite useless. There seems to be tacit agreement among most participants of this discussion that both Docker and LXC have their place, for different use cases. You seem to be saying something different. Could you elucidate?




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: