Live data from Hacker News

Ask HN: Is it just me or why does Docker suck so much?

news.ycombinator.com

41–50 of 85 posts

Re: Ask HN: Is it just me or why does Docker suck so much?

#41
post #27
post #14

Earlier quoted context omitted.

Regarding number two, you'll just link your containers together with docker. See https://docs.docker.com/userguide/dockerlinks/ It seems that most issues OP have is mostly because misunderstanding or lack of knowledge.

What if the mysql server isn't in a docker container or even on the same machine?

Then you should be (ideally) using a service discovery solution or (less ideally) wiring up with environment variables. This is (one reason) why CoreOS uses etcd.

Re: Ask HN: Is it just me or why does Docker suck so much?

#42
post #34

Earlier quoted context omitted.

To run unit tests which rely on certain hosts to resolve to 127.0.0.1.

> To run unit tests which rely on certain hosts to resolve to 127.0.0.1. If you are unit testing DNS infrastructure, shouldn't you mock DNS things?

I'm not unit testing DNS infrastructure. I'm unit testing an Apache module. I send requests to different virtual hosts on 127.0.0.1:80, and checking whether the responses are what I expect.

Re: Ask HN: Is it just me or why does Docker suck so much?

#43
post #10

I've been waiting for the hype to die down a bit and for the project to stabilise before properly playing with it but, from the outside looking in, I must admit I struggle to see how it's gaining as much attention as it is. I can see the advantage for dev boxes where a developer might want to setup a load of containers on their machine to emulate a staging or production environment. But I don't really understand why…

I've been playing around with docker, so I will lend my two cents. If kvm gold images work for you, then by all means use them!

What I like about docker: The layered filesystem [0] is easy to work with and seems pretty smart. I can easily tweak an image, push it to docker hub and pull it back down. Only the delta is being pushed and pulled, not the whole filesystem. This seems like a pretty big win to me! Your db server and redis instance can share the same base system image. This makes updates and redeploying the images much faster!

Also the containers are much lighter weight to run than a vm. You don't need a beefy machine to run a few containers. I'm under the impression that one can run 20-30 containers on a modern laptop, but haven't verified this for myself.

[0] http://docs.docker.com/terms/layer/

Re: Ask HN: Is it just me or why does Docker suck so much?

#44
I personally would say "It's just you."

Docker has been huge for us. We can run the same containers locally that we run in production. Dockerfiles are SIMPLE and easy for people to create and understand.

Fig has really made using docker for local dev rather pleasant.

Are there some hiccups here and there? Yes. The project is young and they are actively trying to smooth over a lot of issues and pain points.

I feel like most people who dislike docker have not actually tried it or used it. That could just be a wrong opinion though.

Re: Ask HN: Is it just me or why does Docker suck so much?

#45
post #23
post #13

Setting up a private repository is a PITA? It's one command: docker run -p 5000:5000 registry Want to back it with S3 or another storage provider? It's still one command: docker run -e SETTINGS_FLAVOR=s3 -e AWS_BUCKET=acme-docker -e STORAGE_PATH=/registry -e AWS_KEY=AKIAHSHB43HS3J92MXZ -e AWS_SECRET=xdDowwlK7TJajV1Y7EoOZrmuPEJlHYcNP2k4j49T -e SEARCH_BACKEND=sqlalchemy -p 5000:5000 registry What's so pain in the ass a…

did you just post your s3 secret key?

We should not be too harsh with people who inadvertently post their secret key. They may be very nice, well-meaning, smart people who, you know, make a mistake and post their key. Maybe it is in an environment file, and they post it to their public github. Could happen. Maybe they forgot and went to sleep, and found out their key got jacked. Maybe -- hypothetical here -- someone ran up $1000s of dollars producing bitcoins on this innocent person's account who made one mistake. One tiny mistake. You never know.

Re: Ask HN: Is it just me or why does Docker suck so much?

#46
post #8

Discussion about the issue is here: https://github.com/docker/docker/issues/2267 That said: With a DHCP server, you get this warning when you try to edit /etc/resolv.conf: "Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8) DO NOT EDIT THIS FILE BY HAND -- YOUR CHANGES WILL BE OVERWRITTEN" Docker works in a similar fashion to assign IPs so this shouldn't be surprising. http://askubuntu.com/q…

All the other alternatives pain in the ass to use?

Pardon me, but like op I found docker to be quite unusable, and LXC a breeze to use.

Why go with the bad abstraction when you can have the real thing? Lxc has everything you want, with zero obscuring "magic" which you don't need anyway.

LXC is definitely recommended. For max benefits you probably want to couple it with a fancy filesystem like btrfs, bit it's by no means required.

Re: Ask HN: Is it just me or why does Docker suck so much?

#47
Some problems I currently have with docker.

1. Dockerfiles are to static

You cannot start the docker build process with an variable (eg. a var that holds a specific branch to checkout) in your dockerfiles.

2. Managing the build process,starting and linking of multiple images/containers

I started with bash scripts then switched a tool called fig. Even though fig keeps things in a simple config file for whole setups I cannot use it because it does not wait for the DB container until it's ready to accept connections before starting a container that links to it. So I'm back writing bash scripts.

3. Replacing running containers

Restarted containers get a new IP, so all the linking does not work anymore. I had to setup a DNS server and wrap the restarting of containers in bash scripts again.

I had no big issues creating a private registry after the ssl certificate was created correctly.

Re: Ask HN: Is it just me or why does Docker suck so much?

#48
post #24

Earlier quoted context omitted.

That works if you have physical access to the machine/vm. What about EC2? Linode? Digital Ocean? etc.

Fair point. I guess for serious stuff I just find it bizarre that you'd want to run a load of containers in a vm (rather than just spooling up additional dropelts or linode instances). For non 'weekend project' stuff, surely it's cheaper and more efficient to lease a dedicated server and stick your own vms on that?

Isn't it just as much about deployment though? The thing about docker is that deploying your new app basically means stopping your running instance and starting a new one. You actually don't even NEED to stop the current running one if you have something above it that just knows which instances / ports to route traffic to.

I think docker is about ease of deployment. You still use the same server you just run a different command. As opposed to creating a new image and spinning up said image.

You can imagine roll back / migration is pretty easy in this case.

Re: Ask HN: Is it just me or why does Docker suck so much?

#49
post #38
post #24

Earlier quoted context omitted.

Fair point. I guess for serious stuff I just find it bizarre that you'd want to run a load of containers in a vm (rather than just spooling up additional dropelts or linode instances). For non 'weekend project' stuff, surely it's cheaper and more efficient to lease a dedicated server and stick your own vms on that?

At Localytics, we wouldn't need to lease a dedicated server. We'd need to lease dozens. And we'd need to have the ability to spin up new hardware to accomodate more load in a minute or two. You don't get that with physical hardware unless you want to overpay. We could overpay for depreciating plant assets or we could overpay for variable costs that we can more directly control. The latter makes sense to us.

Ok, that makes sense. For your workload (large and elastic), I guess I can see the advantage of using docker to quickly provision a newly created vm (assuming the vm's role is completely provided for by just that one container).

Re: Ask HN: Is it just me or why does Docker suck so much?

#50
post #13

Setting up a private repository is a PITA? It's one command: docker run -p 5000:5000 registry Want to back it with S3 or another storage provider? It's still one command: docker run -e SETTINGS_FLAVOR=s3 -e AWS_BUCKET=acme-docker -e STORAGE_PATH=/registry -e AWS_KEY=AKIAHSHB43HS3J92MXZ -e AWS_SECRET=xdDowwlK7TJajV1Y7EoOZrmuPEJlHYcNP2k4j49T -e SEARCH_BACKEND=sqlalchemy -p 5000:5000 registry What's so pain in the ass a…

Yes I have ran that command, I have docker registry running, then I wanted to clean that port and so I put nginx infront and let it proxypass... and have a onename alias for the host that serves the registry so its used by all the machines.

But then you see the hostname is confused for username by docker. Argh crap so it cant be clean, at least has to have fqdn. Or port number.

Its stuff like this man. Documentation should say it "we dont want you to use other registry than ours docker.io its possible but nah". Another issue is, how would you set to use private repo by default? Hm? And never hit docker.io?

Post reply on HN