News for hackers. Stuff that matters.
Re:Docker interactive tutorial by csears on Friday August 16, 2013 @04:34PM (#6226608)
Regarding who is supposed to use it... If you like deploying your apps to a Platform-as-a-Service (PaaS) like Heroku, Google AppEngine, or DotCloud, but wanted to run it on your own infrastructure, then Docker could be for you!

It's designed to be a key building block for anyone who wants to create their own PaaS-like service or environment. Why would you need your own PaaS? You might have unique security requirements forcing you to run an app in-house, or you might not want to pay the high prices of a commercial PaaS if your app gets popular.

Re:Docker interactive tutorial by tootie on Friday August 16, 2013 @04:53PM (#6226683)
So I'm used to configuring stuff by hand, and now I see a lot of buzz around docker, vagrant, chef, puppet, salt and they seem like glorified shell scripts. Am I missing something?
Re:Docker interactive tutorial by jtreminio on Friday August 16, 2013 @05:31PM (#6226849)
Vagrant is a little bit different - it takes the process of booting up a new VM instance (think VirtualBox/VMWare) and automates much of the process of:

1. Choosing OS / flavor / architecture (Debian 7 x64),

2. Setting up networking (private network with its own IP address),

3. Setting up SSH access ($ vagrant ssh),

4. Kicking off provisioning (Chef/Puppet/Salt/Ansible/Bash)

With Vagrant, if you're playing around in your VM and accidently screw something up and can't recover [0], you simply "$ vagrant destroy" and "$ vagrant up" and you'll have a working VM again.

Couple Vagrant with Puppet, and if you destroy/up you'll have your VM go through the process of installing all software and settings and everything for you, meaning your full, working environment is back up and running within minutes, just as it was before you screwed it up.

[0] I experienced this several times when my apt-get stuff would screw up and I couldn't install/remove/purge anything. Google and #debian never let me recover.

Re:Docker interactive tutorial by cheeseprocedure on Friday August 16, 2013 @09:12PM (#6227787)
These tools let you focus on the bigger picture instead of the nitty-gritty.

Docker and Vagrant are convenient for building (and distributing) consistent environments on top of (potentially wildly) different software or hardware platforms. Docker has a ton of other tricks up its sleeve (one example is "layers:" http://docs.docker.io/en/latest/terms/layer/).

Chef/Puppet/Salt/et al. are configuration management tools which enable programmatic definition of infrastructure. The key point is: you define how the system should look, not the specific steps on how to get there. Abstraction layers (management of files/users/packages/services/etc.) provided by the CM tool shield you from a nightmare of permutations, corner cases, and platform-specific options; it'll just enforce a given configuration regardless of local changes.

Having a central source of truth for systems configuration is a gamechanger in itself; your configuration directives or applications can query (or update) your configuration management database, which enables some very cool automation with very little effort. Then there's the community: for any given stack, there's probably a well-documented, well-tested Chef cookbook or Puppet manifest to build it, instantly plugging you into a rich experience base.

Yes, one could script all of this from scratch, but I'm not sure why one would.

Re:Docker interactive tutorial by jpetazzo on Friday August 16, 2013 @05:14PM (#6226773)
It's basically what you get when you start your deployment toolchain as simple shell scripts, then make them evolve, add features, and at some point, rewrite from scratch with a "real" programming language. I don't know if that matches your definition of "glorified" though :-)
Re:Docker interactive tutorial by tootie on Monday August 19, 2013 @02:01PM (#6238624)
I'm reading this python example (http://docs.docker.io/en/latest/examples/python_web_app/) and it's a wrapper for running bash scripts with arcane syntax layered on top.
Re:Docker interactive tutorial by shykes on Friday August 16, 2013 @05:46PM (#6226906)
The big difference with just scripts is that you can "freeze" the state of your deployment with strong guarantees that 1) it will not change and 2) it will behave the same way across machines.

Another advantage of containers is that deployment can be made atomic: either container A is running, or container B. You can't end up with a half-finished upgrade which leaves your server in an undefined, broken state. That property becomes very important when you deploy to a large number of servers.