Live data from Hacker News

Ask HN: Why use Docker and what are the business cases for using it?

news.ycombinator.com

1–10 of 137 posts

Ask HN: Why use Docker and what are the business cases for using it?

#1
I recently did a very basic tutorial on Docker. Afterward, when talking to the tech lead of the project I am working on, he asked me "What are the business cases for using Docker, how could it save us money, how could it make us more efficient?" I told him I would do some research to find the best answers and figured I would turn to you all here at HackerNews for some advice.

Thanks in advance!

Just so you know, I currently work on a project at my company that uses AWS, Codeship and BitBucket for development and production. AWS and Elasticbeanstalk host our application, Codeship runs tests on changes to branches in BitBucket and then pushes the code that passes on certain branches to different AWS environments for Development or Production.

Re: Ask HN: Why use Docker and what are the business cases for using it?

#2
I talk about this a bit here:

https://www.youtube.com/watch?v=zVUPmmUU3yY

this was a year ago, so a little out of date. I now work for another company that is into Docker.

I also have various bits on my blog:

http://zwischenzugs.tk

check out the jenkins ones, for example:

http://zwischenzugs.tk/index.php/2014/11/08/taming-slaves-wi...

http://zwischenzugs.tk/index.php/2015/03/19/scale-your-jenki...

Re: Ask HN: Why use Docker and what are the business cases for using it?

#3
There are many ways of using Docker and obviously different companies could come up with their own business cases for adopting the technology. So let me focus on one scenario and we can talk about whether it makes sense for your environment.

Software engineering is often difficult because programmers have to deal with inconsistent environments for development and for production execution of their products. Due to mismatches between these environments, developers often found bugs that surface in one environment but not in another.

Hardware based virtualization (VMWare, HyperV, etc) helped with the inconsistency issue because it enabled developers to create dev/test environments that could later be replicated into production. However this category of virtualization requires more computational resources (esp. storage) than operating system virtualization like LXC used by Docker.

In addition to requiring less resources than hardware virtualization, Docker defined a convenient container specification format (Dockerfile) and a way to share these specifications (DockerHub). When used together, these Docker technologies accelerate the process of defining a consistent environment for both development and production in your application. Dockerfiles are easy to maintain and help reduce the need for a dedicated operations team for your application. In buzzword speak, your team can become more "DevOps".

Docker, by the virtue of relying on a thinner virtualization layer than hardware hypervisors like VMWare, also has higher performance for I/O intensive operations. When used on bare metal hardware, you going to be able to get better performance for many databases in Docker containers compared to databases running in a virtual machine guest.

So to recap, Docker can help you

- maintain consistent dev/test/prod environments

- use less resources than hardware virtualization

- free up the time your team spends on dev to ops handoffs

- improve your app I/O performance compared to running in a hardware virtualization based virtual machine guest

However if you are using AWS, note that Docker Container Service available from Amazon actually doesn't give you Docker on bare metal. That's because Docker Containers run in AWS virtual machine guests virtualized by Xen hypervisor. So with AWS you are paying a penalty in resources and performance when using Docker.

Re: Ask HN: Why use Docker and what are the business cases for using it?

#5

I talk about this a bit here: https://www.youtube.com/watch?v=zVUPmmUU3yY this was a year ago, so a little out of date. I now work for another company that is into Docker. I also have various bits on my blog: http://zwischenzugs.tk check out the jenkins ones, for example: http://zwischenzugs.tk/index.php/2014/11/08/taming-slaves-wi... http://zwischenzugs.tk/index.php/2015/03/19/scale-your-jenki...

In your Jenkins example, why use docker? Why not ask the devs to directly install Jenkins on their box?

Re: Ask HN: Why use Docker and what are the business cases for using it?

#6

I talk about this a bit here: https://www.youtube.com/watch?v=zVUPmmUU3yY this was a year ago, so a little out of date. I now work for another company that is into Docker. I also have various bits on my blog: http://zwischenzugs.tk check out the jenkins ones, for example: http://zwischenzugs.tk/index.php/2014/11/08/taming-slaves-wi... http://zwischenzugs.tk/index.php/2015/03/19/scale-your-jenki...

In your Jenkins example, why use docker? Why not ask the devs to directly install Jenkins on their box?

Because the builds would not be contained. There were many dependencies that needed to be installed on each box.

Using Docker meant that the slaves could be built from scratch as well.

See here: http://zwischenzugs.tk/index.php/2014/11/08/taming-slaves-wi...

Re: Ask HN: Why use Docker and what are the business cases for using it?

#7
Have you ever used provisioning software like Chef to prepare a server to run your software? Have you ever used that in conjunction with Vagrant in order to test out your provisioning and software deployment locally? Docker replaces (or can replace) all of that.

Re: Ask HN: Why use Docker and what are the business cases for using it?

#10
Maybe you have looked already and it wasn't useful to you but on the Docker website it has some pretty good marketing to explain its usefulness: https://www.docker.com/whatisdocker

Why Use Docker: "How does this help you build better software? When your app is in Docker containers, you don’t have to worry about setting up and maintaining different environments or different tooling for each language. Focus on creating new features, fixing issues and shipping software."

Business Case: "...With Docker, you can easily take copies of your live environment and run on any new endpoint running Docker..."

Post reply on HN