Merge branch 'master' into bump_0.6.4
diff --git a/.mailmap b/.mailmap
index adeac2d..2875a92 100644
--- a/.mailmap
+++ b/.mailmap
@@ -26,3 +26,15 @@
 Konstantin Pelykh <kpelykh@zettaset.com>
 David Sissitka <me@dsissitka.com>
 Nolan Darilek <nolan@thewordnerd.info>
+<mastahyeti@gmail.com> <mastahyeti@users.noreply.github.com>
+Benoit Chesneau <bchesneau@gmail.com>
+Jordan Arentsen <blissdev@gmail.com>
+Daniel Garcia <daniel@danielgarcia.info>
+Miguel Angel Fernández <elmendalerenda@gmail.com>
+Bhiraj Butala <abhiraj.butala@gmail.com>
+Faiz Khan <faizkhan00@gmail.com>
+Victor Lyuboslavsky <victor@victoreda.com>
+Jean-Baptiste Barth <jeanbaptiste.barth@gmail.com>
+Matthew Mueller <mattmuelle@gmail.com>
+<mosoni@ebay.com> <mohitsoni1989@gmail.com>
+Shih-Yuan Lee <fourdollars@gmail.com>
diff --git a/AUTHORS b/AUTHORS
index af0eb3b..9a22e88 100644
--- a/AUTHORS
+++ b/AUTHORS
@@ -5,64 +5,98 @@
 #
 Al Tobey <al@ooyala.com>
 Alex Gaynor <alex.gaynor@gmail.com>
+Alexander Larsson <alexl@redhat.com>
 Alexey Shamrin <shamrin@gmail.com>
 Andrea Luzzardi <aluzzardi@gmail.com>
+Andreas Savvides <andreas@editd.com>
 Andreas Tiefenthaler <at@an-ti.eu>
+Andrew Macgregor <andrew.macgregor@agworld.com.au>
 Andrew Munsell <andrew@wizardapps.net>
 Andrews Medina <andrewsmedina@gmail.com>
 Andy Rothfusz <github@metaliveblog.com>
 Andy Smith <github@anarkystic.com>
 Anthony Bishopric <git@anthonybishopric.com>
 Antony Messerli <amesserl@rackspace.com>
+Asbjørn Enge <asbjorn@hanafjedle.net>
 Barry Allard <barry.allard@gmail.com>
+Ben Toews <mastahyeti@gmail.com>
+Benoit Chesneau <bchesneau@gmail.com>
+Bhiraj Butala <abhiraj.butala@gmail.com>
+Bouke Haarsma <bouke@webatoom.nl>
 Brandon Liu <bdon@bdon.org>
+Brandon Philips <brandon@ifup.co>
 Brian McCallister <brianm@skife.org>
 Brian Olsen <brian@maven-group.org>
+Brian Shumate <brian@couchbase.com>
+Briehan Lombaard <briehan.lombaard@gmail.com>
 Bruno Bigras <bigras.bruno@gmail.com>
 Caleb Spare <cespare@gmail.com>
 Calen Pennington <cale@edx.org>
 Charles Hooper <charles.hooper@dotcloud.com>
 Christopher Currie <codemonkey+github@gmail.com>
+Colin Dunklau <colin.dunklau@gmail.com>
 Colin Rice <colin@daedrum.net>
+Dan Buch <d.buch@modcloth.com>
+Daniel Garcia <daniel@danielgarcia.info>
 Daniel Gasienica <daniel@gasienica.ch>
 Daniel Mizyrycki <daniel.mizyrycki@dotcloud.com>
+Daniel Nordberg <dnordberg@gmail.com>
 Daniel Robinson <gottagetmac@gmail.com>
 Daniel Von Fange <daniel@leancoder.com>
 Daniel YC Lin <dlin.tw@gmail.com>
 David Calavera <david.calavera@gmail.com>
 David Sissitka <me@dsissitka.com>
+Deni Bertovic <deni@kset.org>
 Dominik Honnef <dominik@honnef.co>
 Don Spaulding <donspauldingii@gmail.com>
 Dr Nic Williams <drnicwilliams@gmail.com>
+Dražen Lučanin <kermit666@gmail.com>
 Elias Probst <mail@eliasprobst.eu>
 Emily Rose <emily@contactvibe.com>
 Eric Hanchrow <ehanchrow@ine.com>
 Eric Myhre <hash@exultant.us>
 Erno Hopearuoho <erno.hopearuoho@gmail.com>
+Evan Phoenix <evan@fallingsnow.net>
 Evan Wies <evan@neomantra.net>
 ezbercih <cem.ezberci@gmail.com>
 Fabrizio Regini <freegenie@gmail.com>
+Faiz Khan <faizkhan00@gmail.com>
 Fareed Dudhia <fareeddudhia@googlemail.com>
 Flavio Castelli <fcastelli@suse.com>
 Francisco Souza <f@souza.cc>
 Frederick F. Kautz IV <fkautz@alumni.cmu.edu>
 Gabriel Monroy <gabriel@opdemand.com>
 Gareth Rushgrove <gareth@morethanseven.net>
+Greg Thornton <xdissent@me.com>
 Guillaume J. Charmes <guillaume.charmes@dotcloud.com>
+Guruprasad <lgp171188@gmail.com>
 Harley Laue <losinggeneration@gmail.com>
+Hector Castro <hectcastro@gmail.com>
 Hunter Blanks <hunter@twilio.com>
+Isao Jonas <isao.jonas@gmail.com>
+James Carr <james.r.carr@gmail.com>
+Jason McVetta <jason.mcvetta@gmail.com>
+Jean-Baptiste Barth <jeanbaptiste.barth@gmail.com>
 Jeff Lindsay <progrium@gmail.com>
 Jeremy Grosser <jeremy@synack.me>
+Jim Alateras <jima@comware.com.au>
+Jimmy Cuadra <jimmy@jimmycuadra.com>
+Joe Van Dyk <joe@tanga.com>
 Joffrey F <joffrey@dotcloud.com>
 Johan Euphrosine <proppy@google.com>
 John Costa <john.costa@gmail.com>
 Jon Wedaman <jweede@gmail.com>
 Jonas Pfenniger <jonas@pfenniger.name>
+Jonathan Mueller <j.mueller@apoveda.ch>
 Jonathan Rudenberg <jonathan@titanous.com>
+Joost Cassee <joost@cassee.net>
+Jordan Arentsen <blissdev@gmail.com>
 Joseph Anthony Pasquale Holsten <joseph@josephholsten.com>
 Julien Barbier <write0@gmail.com>
 Jérôme Petazzoni <jerome.petazzoni@dotcloud.com>
 Karan Lyons <karan@karanlyons.com>
+Karl Grzeszczak <karl@karlgrz.com>
+Kawsar Saiyeed <kawsar.saiyeed@projiris.com>
 Keli Hu <dev@keli.hu>
 Ken Cochrane <kencochrane@gmail.com>
 Kevin Clark <kevin.clark@gmail.com>
@@ -71,28 +105,45 @@
 Kimbro Staken <kstaken@kstaken.com>
 Kiran Gangadharan <kiran.daredevil@gmail.com>
 Konstantin Pelykh <kpelykh@zettaset.com>
+Kyle Conroy <kyle.j.conroy@gmail.com>
+Laurie Voss <github@seldo.com>
 Louis Opter <kalessin@kalessin.fr>
+Manuel Meurer <manuel@krautcomputing.com>
 Marco Hennings <marco.hennings@freiheit.com>
 Marcus Farkas <toothlessgear@finitebox.com>
+Marcus Ramberg <marcus@nordaaker.com>
 Mark McGranaghan <mmcgrana@gmail.com>
-Martin Redmond <mrtodo@gmail.com>
+Marko Mikulicic <mmikulicic@gmail.com>
+Markus Fix <lispmeister@gmail.com>
+Martin Redmond <martin@tinychat.com>
+Matt Apperson <me@mattapperson.com>
+Matt Bachmann <bachmann.matt@gmail.com>
+Matthew Mueller <mattmuelle@gmail.com>
 Maxim Treskin <zerthurd@gmail.com>
 meejah <meejah@meejah.ca>
 Michael Crosby <crosby.michael@gmail.com>
+Michael Gorsuch <gorsuch@github.com>
+Miguel Angel Fernández <elmendalerenda@gmail.com>
 Mike Gaffney <mike@uberu.com>
 Mikhail Sobolev <mss@mawhrin.net>
+Mohit Soni <mosoni@ebay.com>
+Morten Siebuhr <sbhr@sbhr.dk>
 Nan Monnand Deng <monnand@gmail.com>
 Nate Jones <nate@endot.org>
 Nelson Chen <crazysim@gmail.com>
 Niall O'Higgins <niallo@unworkable.org>
+Nick Payne <nick@kurai.co.uk>
 Nick Stenning <nick.stenning@digital.cabinet-office.gov.uk>
 Nick Stinemates <nick@stinemates.org>
 Nolan Darilek <nolan@thewordnerd.info>
 odk- <github@odkurzacz.org>
+Pascal Borreli <pascal@borreli.com>
 Paul Bowsher <pbowsher@globalpersonals.co.uk>
 Paul Hammond <paul@paulhammond.org>
 Phil Spitler <pspitler@gmail.com>
 Piotr Bogdan <ppbogdan@gmail.com>
+pysqz <randomq@126.com>
+Ramon van Alteren <ramon@vanalteren.nl>
 Renato Riccieri Santos Zannon <renato.riccieri@gmail.com>
 Rhys Hiltner <rhys@twitch.tv>
 Robert Obryk <robryk@gmail.com>
@@ -100,14 +151,21 @@
 Ryan Fowler <rwfowler@gmail.com>
 Sam Alba <sam.alba@gmail.com>
 Sam J Sharpe <sam.sharpe@digital.cabinet-office.gov.uk>
+Sean P. Kane <skane@newrelic.com>
 Shawn Siefkas <shawn.siefkas@meredith.com>
+Shih-Yuan Lee <fourdollars@gmail.com>
 Silas Sewell <silas@sewell.org>
 Solomon Hykes <solomon@dotcloud.com>
+Song Gao <song@gao.io>
+Sridatta Thatipamala <sthatipamala@gmail.com>
 Sridhar Ratnakumar <sridharr@activestate.com>
+Steeve Morin <steeve.morin@gmail.com>
 Stefan Praszalowicz <stefan@greplin.com>
 Thatcher Peskens <thatcher@dotcloud.com>
+Thermionix <bond711@gmail.com>
 Thijs Terlouw <thijsterlouw@gmail.com>
 Thomas Bikeev <thomas.bikeev@mac.com>
+Thomas Frössman <thomasf@jossystem.se>
 Thomas Hansen <thomas.hansen@gmail.com>
 Tianon Gravi <admwiggin@gmail.com>
 Tim Terhorst <mynamewastaken+git@gmail.com>
@@ -115,8 +173,16 @@
 Tobias Schmidt <ts@soundcloud.com>
 Tobias Schwab <tobias.schwab@dynport.de>
 Tom Hulihan <hulihan.tom159@gmail.com>
+Tommaso Visconti <tommaso.visconti@gmail.com>
+Tyler Brock <tyler.brock@gmail.com>
 unclejack <unclejacksons@gmail.com>
+Victor Coisne <victor.coisne@dotcloud.com>
+Victor Lyuboslavsky <victor@victoreda.com>
 Victor Vieux <victor.vieux@dotcloud.com>
+Vincent Bernat <bernat@luffy.cx>
 Vivek Agarwal <me@vivek.im>
+Vladimir Kirillov <proger@wilab.org.ua>
 Walter Stanish <walter@pratyeka.org>
+Wes Morgan <cap10morgan@gmail.com>
 Will Dietz <w@wdtz.org>
+Zaiste! <oh@zaiste.net>
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 0dfc3a8..f7e5d92 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -26,7 +26,7 @@
 * Registry: Implement login with private registry
 * Remote API: Bump to v1.5
 * Packaging: Break down hack/make.sh into small scripts, one per 'bundle': test, binary, ubuntu etc.
-* Documentation: General improvments
+* Documentation: General improvements
 - Runtime: UID and GID are now also applied to volumes
 - Runtime: `docker start` set error code upon error
 - Runtime: `docker run` set the same error code as the process started
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index d5438c3..43137c6 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -3,6 +3,10 @@
 Want to hack on Docker? Awesome! Here are instructions to get you started. They are probably not perfect, please let us know if anything feels
 wrong or incomplete.
 
+## Build Environment
+
+For instructions on setting up your development environment, please see our dedicated [dev environment setup docs](http://docs.docker.io/en/latest/contributing/devenvironment/).
+
 ## Contribution guidelines
 
 ### Pull requests are always welcome
@@ -55,8 +59,10 @@
 it! Take a look at existing tests for inspiration. Run the full test suite on
 your branch before submitting a pull request.
 
-Make sure you include relevant updates or additions to documentation when
-creating or modifying features.
+Update the documentation when creating or modifying features. Test
+your documentation changes for clarity, concision, and correctness, as
+well as a clean docmuent build. See ``docs/README.md`` for more
+information on building the docs and how docs get released.
 
 Write clean code. Universally formatted code promotes ease of writing, reading,
 and maintenance. Always run `go fmt` before committing your changes. Most
@@ -89,53 +95,17 @@
 regenerated occasionally from the git commit history, so a mismatch may result
 in your changes being overwritten.
 
+### Approval
 
-## Decision process
+Docker maintainers use LGTM (looks good to me) in comments on the code review
+to indicate acceptance.
 
-### How are decisions made?
+A change requires LGTMs from an absolute majority of the maintainers of each
+component affected. For example, if a change affects docs/ and registry/, it
+needs an absolute majority from the maintainers of docs/ AND, separately, an
+absolute majority of the maintainers of registry
 
-Short answer: with pull requests to the docker repository.
-
-Docker is an open-source project with an open design philosophy. This means that the repository is the source of truth for EVERY aspect of the project,
-including its philosophy, design, roadmap and APIs. *If it's part of the project, it's in the repo. It's in the repo, it's part of the project.*
-
-As a result, all decisions can be expressed as changes to the repository. An implementation change is a change to the source code. An API change is a change to
-the API specification. A philosophy change is a change to the philosophy manifesto. And so on.
-
-All decisions affecting docker, big and small, follow the same 3 steps:
-
-* Step 1: Open a pull request. Anyone can do this.
-
-* Step 2: Discuss the pull request. Anyone can do this.
-
-* Step 3: Accept or refuse a pull request. The relevant maintainer does this (see below "Who decides what?")
-
-
-### Who decides what?
-
-So all decisions are pull requests, and the relevant maintainer makes the decision by accepting or refusing the pull request.
-But how do we identify the relevant maintainer for a given pull request?
-
-Docker follows the timeless, highly efficient and totally unfair system known as [Benevolent dictator for life](http://en.wikipedia.org/wiki/Benevolent_Dictator_for_Life),
-with yours truly, Solomon Hykes, in the role of BDFL.
-This means that all decisions are made by default by me. Since making every decision myself would be highly unscalable, in practice decisions are spread across multiple maintainers.
-
-The relevant maintainer for a pull request is assigned in 3 steps:
-
-* Step 1: Determine the subdirectory affected by the pull request. This might be src/registry, docs/source/api, or any other part of the repo.
-
-* Step 2: Find the MAINTAINERS file which affects this directory. If the directory itself does not have a MAINTAINERS file, work your way up the the repo hierarchy until you find one.
-
-* Step 3: The first maintainer listed is the primary maintainer. The pull request is assigned to him. He may assign it to other listed maintainers, at his discretion.
-
-
-### I'm a maintainer, should I make pull requests too?
-
-Primary maintainers are not required to create pull requests when changing their own subdirectory, but secondary maintainers are.
-
-### Who assigns maintainers?
-
-Solomon.
+For more details see [MAINTAINERS.md](hack/MAINTAINERS.md)
 
 ### How can I become a maintainer?
 
@@ -146,15 +116,3 @@
 Don't forget: being a maintainer is a time investment. Make sure you will have time to make yourself available.
 You don't have to be a maintainer to make a difference on the project!
 
-### What are a maintainer's responsibility?
-
-It is every maintainer's responsibility to:
-
-* 1) Expose a clear roadmap for improving their component.
-* 2) Deliver prompt feedback and decisions on pull requests.
-* 3) Be available to anyone with questions, bug reports, criticism etc. on their component. This includes irc, github requests and the mailing list.
-* 4) Make sure their component respects the philosophy, design and roadmap of the project.
-
-### How is this process changed?
-
-Just like everything else: by making a pull request :)
diff --git a/Dockerfile b/Dockerfile
index 36054d2..67963c8 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -12,47 +12,58 @@
 #
 #
 # # Run the test suite:
-# docker run -privileged -lxc-conf=lxc.aa_profile=unconfined docker go test -v
+# docker run -privileged -lxc-conf=lxc.aa_profile=unconfined docker hack/make.sh test
 #
 # # Publish a release:
 # docker run -privileged -lxc-conf=lxc.aa_profile=unconfined \
-# -e AWS_S3_BUCKET=baz \
-# -e AWS_ACCESS_KEY=foo \
-# -e AWS_SECRET_KEY=bar \
-# -e GPG_PASSPHRASE=gloubiboulga \
-# -lxc-conf=lxc.aa_profile=unconfined -privileged docker hack/release.sh
-# 
+#  -e AWS_S3_BUCKET=baz \
+#  -e AWS_ACCESS_KEY=foo \
+#  -e AWS_SECRET_KEY=bar \
+#  -e GPG_PASSPHRASE=gloubiboulga \
+#  docker hack/release.sh
+#
 
 docker-version 0.6.1
 from	ubuntu:12.04
 maintainer	Solomon Hykes <solomon@dotcloud.com>
+
 # Build dependencies
 run	echo 'deb http://archive.ubuntu.com/ubuntu precise main universe' > /etc/apt/sources.list
 run	apt-get update
 run	apt-get install -y -q curl
 run	apt-get install -y -q git
 run	apt-get install -y -q mercurial
-# Install Go
-run	curl -s https://go.googlecode.com/files/go1.1.2.linux-amd64.tar.gz | tar -v -C /usr/local -xz
-env	PATH	/usr/local/go/bin:/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin:/bin:/sbin
-env	GOPATH	/go:/go/src/github.com/dotcloud/docker/vendor
+run	apt-get install -y -q build-essential
+
+# Install Go from source (for eventual cross-compiling)
 env	CGO_ENABLED 0
-run	cd /tmp && echo 'package main' > t.go && go test -a -i -v
+run	curl -s https://go.googlecode.com/files/go1.1.2.src.tar.gz | tar -v -C / -xz && mv /go /goroot
+run	cd /goroot/src && ./make.bash
+env GOROOT	/goroot
+env	PATH	$PATH:/goroot/bin
+env	GOPATH	/go:/go/src/github.com/dotcloud/docker/vendor
+
 # Ubuntu stuff
 run	apt-get install -y -q ruby1.9.3 rubygems libffi-dev
-run	gem install fpm
+run	gem install --no-rdoc --no-ri fpm
 run	apt-get install -y -q reprepro dpkg-sig
+
 # Install s3cmd 1.0.1 (earlier versions don't support env variables in the config)
 run	apt-get install -y -q python-pip
 run	pip install s3cmd
 run	pip install python-magic
 run	/bin/echo -e '[default]\naccess_key=$AWS_ACCESS_KEY\nsecret_key=$AWS_SECRET_KEY\n' > /.s3cfg
+
 # Runtime dependencies
 run	apt-get install -y -q iptables
 run	apt-get install -y -q lxc
+run	apt-get install -y -q aufs-tools
+
 volume	/var/lib/docker
 workdir	/go/src/github.com/dotcloud/docker
+
 # Wrap all commands in the "docker-in-docker" script to allow nested containers
 entrypoint ["hack/dind"]
+
 # Upload docker source
 add	.       /go/src/github.com/dotcloud/docker
diff --git a/FIXME b/FIXME
index 6e14a08..91c8d92 100644
--- a/FIXME
+++ b/FIXME
@@ -15,23 +15,16 @@
 * Run linter on codebase
 * Unify build commands and regular commands
 * Move source code into src/ subdir for clarity
-* Clean up the Makefile, it's a mess
 * docker build: on non-existent local path for ADD, don't show full absolute path on the host
-* mount into /dockerinit rather than /sbin/init
 * docker tag foo REPO:TAG
 * use size header for progress bar in pull
 * Clean up context upload in build!!!
 * Parallel pull
-* Ensure /proc/sys/net/ipv4/ip_forward is 1
-* Force DNS to public!
 * Always generate a resolv.conf per container, to avoid changing resolv.conf under thne container's feet
-* Save metadata with import/export
+* Save metadata with import/export (#1974)
 * Upgrade dockerd without stopping containers
-* bring back git revision info, looks like it was lost
-* Simple command to remove all untagged images
+* Simple command to remove all untagged images (`docker rmi $(docker images | awk '/^<none>/ { print $3 }')`)
 * Simple command to clean up containers for disk space
-* Caching after an ADD
-* entry point config
-* bring back git revision info, looks like it was lost
+* Caching after an ADD (#880)
 * Clean up the ProgressReader api, it's a PITA to use
 * Use netlink instead of iproute2/iptables (#925)
diff --git a/NOTICE b/NOTICE
index a11ff94..663a401 100644
--- a/NOTICE
+++ b/NOTICE
@@ -1,11 +1,43 @@
 Docker
 Copyright 2012-2013 dotCloud, inc.
 
-This product includes software developed at dotCloud, inc. (http://www.dotcloud.com).
+This product includes software developed at dotCloud,
+inc. (http://www.dotcloud.com).
 
-This product contains software (https://github.com/kr/pty) developed by Keith Rarick, licensed under the MIT License.
+This product contains software (https://github.com/kr/pty) developed
+by Keith Rarick, licensed under the MIT License.
 
-Transfers of Docker shall be in accordance with applicable export controls of any country and all other applicable
-legal requirements.  Docker shall not be distributed or downloaded to or in Cuba, Iran, North Korea, Sudan or Syria
-and shall not be distributed or downloaded to any person on the Denied Persons List administered by the U.S.
+The following is courtesy of our legal counsel:
+
+Transfers of Docker shall be in accordance with applicable export
+controls of any country and all other applicable legal requirements.
+Docker shall not be distributed or downloaded to or in Cuba, Iran,
+North Korea, Sudan or Syria and shall not be distributed or downloaded
+to any person on the Denied Persons List administered by the U.S.
 Department of Commerce.
+
+What does that mean? 
+Here is a further explanation from our legal counsel:
+
+Like all software products that utilize cryptography, the export and
+use of Docker is subject to the U.S. Commerce Department's Export
+Administration Regulations (EAR) because it uses or contains
+cryptography (see
+http://www.bis.doc.gov/index.php/policy-guidance/encryption).  Certain
+free and open source software projects have a lightweight set of
+requirements, which can generally be met by providing email notice to
+the appropriate U.S. government agencies that their source code is
+available on a publicly available repository and making the
+appropriate statements in the README.
+
+The restrictions of the EAR apply to certain denied locations
+(currently Iran, Sudan, Syria, North Korea, or Cuba) and those
+individuals on the Denied Persons List, which is available here:
+http://www.bis.doc.gov/index.php/policy-guidance/lists-of-parties-of-concern/denied-persons-list.
+If you are incorporating Docker into a new open source project, the
+EAR restrictions apply to your incorporation of Docker into your
+project in the same manner as other cryptography-enabled projects,
+such as OpenSSL, almost all Linux distributions, etc.
+
+For more information, see http://www.apache.org/dev/crypto.html and/or
+seek legal counsel.
diff --git a/README.md b/README.md
index a36bfba..10291c2 100644
--- a/README.md
+++ b/README.md
@@ -18,7 +18,7 @@
 accumulated over several years of large-scale operation and support of
 hundreds of thousands of applications and databases.
 
-![Docker L](docs/sources/static_files/dockerlogo-h.png "Docker")
+![Docker L](docs/theme/docker/static/img/dockerlogo-h.png "Docker")
 
 ## Better than VMs
 
@@ -190,6 +190,9 @@
 
 ### Legal
 
+*Brought to you courtesy of our legal counsel. For more context,
+please see the Notice document.*
+
 Transfers of Docker shall be in accordance with applicable export
 controls of any country and all other applicable legal requirements.
 Docker shall not be distributed or downloaded to or in Cuba, Iran,
diff --git a/VERSION b/VERSION
index 844f6a9..fe50cf9 100644
--- a/VERSION
+++ b/VERSION
@@ -1 +1 @@
-0.6.3
+0.6.3-dev
diff --git a/Vagrantfile b/Vagrantfile
index 85af128..93a2219 100644
--- a/Vagrantfile
+++ b/Vagrantfile
@@ -13,6 +13,8 @@
   config.vm.box = BOX_NAME
   config.vm.box_url = BOX_URI
 
+  config.ssh.forward_agent = true
+
   # Provision docker and new kernel if deployment was not done.
   # It is assumed Vagrant can successfully launch the provider instance.
   if Dir.glob("#{File.dirname(__FILE__)}/.vagrant/machines/default/*/id").empty?
@@ -37,6 +39,8 @@
         "echo 'Installation of VBox Guest Additions is proceeding in the background.'; " \
         "echo '\"vagrant reload\" can be used in about 2 minutes to activate the new guest additions.'; "
     end
+    # Add vagrant user to the docker group
+    pkg_cmd << "usermod -a -G docker vagrant; "
     # Activate new kernel
     pkg_cmd << "shutdown -r +1; "
     config.vm.provision :shell, :inline => pkg_cmd
@@ -76,6 +80,8 @@
   config.vm.provider :virtualbox do |vb|
     config.vm.box = BOX_NAME
     config.vm.box_url = BOX_URI
+    vb.customize ["modifyvm", :id, "--natdnshostresolver1", "on"]
+    vb.customize ["modifyvm", :id, "--natdnsproxy1", "on"]
   end
 end
 
diff --git a/api.go b/api.go
index f984b1c..ad30833 100644
--- a/api.go
+++ b/api.go
@@ -21,10 +21,12 @@
 	"strings"
 )
 
-const APIVERSION = 1.5
-const DEFAULTHTTPHOST = "127.0.0.1"
-const DEFAULTHTTPPORT = 4243
-const DEFAULTUNIXSOCKET = "/var/run/docker.sock"
+const (
+	APIVERSION        = 1.6
+	DEFAULTHTTPHOST   = "127.0.0.1"
+	DEFAULTHTTPPORT   = 4243
+	DEFAULTUNIXSOCKET = "/var/run/docker.sock"
+)
 
 type HttpApiFunc func(srv *Server, version float64, w http.ResponseWriter, r *http.Request, vars map[string]string) error
 
@@ -67,9 +69,12 @@
 		statusCode = http.StatusUnauthorized
 	} else if strings.Contains(err.Error(), "hasn't been activated") {
 		statusCode = http.StatusForbidden
-	}
-	utils.Debugf("[error %d] %s", statusCode, err)
-	http.Error(w, err.Error(), statusCode)
+	}	
+	
+	if err != nil {
+		utils.Errorf("HTTP Error: statusCode=%d %s", statusCode, err.Error())
+		http.Error(w, err.Error(), statusCode)		
+	}	
 }
 
 func writeJSON(w http.ResponseWriter, code int, v interface{}) error {
@@ -100,7 +105,7 @@
 func matchesContentType(contentType, expectedType string) bool {
 	mimetype, _, err := mime.ParseMediaType(contentType)
 	if err != nil {
-		utils.Debugf("Error parsing media type: %s error: %s", contentType, err.Error())
+		utils.Errorf("Error parsing media type: %s error: %s", contentType, err.Error())
 	}
 	return err == nil && mimetype == expectedType
 }
@@ -145,7 +150,7 @@
 	name := vars["name"]
 
 	if err := srv.ContainerExport(name, w); err != nil {
-		utils.Debugf("%s", err)
+		utils.Errorf("%s", err)
 		return err
 	}
 	return nil
@@ -190,7 +195,7 @@
 		_, err = wf.Write(b)
 		if err != nil {
 			// On error, evict the listener
-			utils.Debugf("%s", err)
+			utils.Errorf("%s", err)
 			srv.Lock()
 			delete(srv.listeners, r.RemoteAddr)
 			srv.Unlock()
@@ -344,8 +349,8 @@
 		return err
 	}
 	config := &Config{}
-	if err := json.NewDecoder(r.Body).Decode(config); err != nil {
-		utils.Debugf("%s", err)
+	if err := json.NewDecoder(r.Body).Decode(config); err != nil && err != io.EOF {
+		utils.Errorf("%s", err)
 	}
 	repo := r.Form.Get("repo")
 	tag := r.Form.Get("tag")
@@ -710,32 +715,43 @@
 	}
 	name := vars["name"]
 
-	if _, err := srv.ContainerInspect(name); err != nil {
+	c, err := srv.ContainerInspect(name)
+	if err != nil {
 		return err
 	}
 
-	in, out, err := hijackServer(w)
+	inStream, outStream, err := hijackServer(w)
 	if err != nil {
 		return err
 	}
 	defer func() {
-		if tcpc, ok := in.(*net.TCPConn); ok {
+		if tcpc, ok := inStream.(*net.TCPConn); ok {
 			tcpc.CloseWrite()
 		} else {
-			in.Close()
+			inStream.Close()
 		}
 	}()
 	defer func() {
-		if tcpc, ok := out.(*net.TCPConn); ok {
+		if tcpc, ok := outStream.(*net.TCPConn); ok {
 			tcpc.CloseWrite()
-		} else if closer, ok := out.(io.Closer); ok {
+		} else if closer, ok := outStream.(io.Closer); ok {
 			closer.Close()
 		}
 	}()
 
-	fmt.Fprintf(out, "HTTP/1.1 200 OK\r\nContent-Type: application/vnd.docker.raw-stream\r\n\r\n")
-	if err := srv.ContainerAttach(name, logs, stream, stdin, stdout, stderr, in, out); err != nil {
-		fmt.Fprintf(out, "Error: %s\n", err)
+	var errStream io.Writer
+
+	fmt.Fprintf(outStream, "HTTP/1.1 200 OK\r\nContent-Type: application/vnd.docker.raw-stream\r\n\r\n")
+
+	if !c.Config.Tty && version >= 1.6 {
+		errStream = utils.NewStdWriter(outStream, utils.Stderr)
+		outStream = utils.NewStdWriter(outStream, utils.Stdout)
+	} else {
+		errStream = outStream
+	}
+
+	if err := srv.ContainerAttach(name, logs, stream, stdin, stdout, stderr, inStream, outStream, errStream); err != nil {
+		fmt.Fprintf(outStream, "Error: %s\n", err)
 	}
 	return nil
 }
@@ -778,8 +794,8 @@
 	h := websocket.Handler(func(ws *websocket.Conn) {
 		defer ws.Close()
 
-		if err := srv.ContainerAttach(name, logs, stream, stdin, stdout, stderr, ws, ws); err != nil {
-			utils.Debugf("Error: %s", err)
+		if err := srv.ContainerAttach(name, logs, stream, stdin, stdout, stderr, ws, ws, ws); err != nil {
+			utils.Errorf("Error: %s", err)
 		}
 	})
 	h.ServeHTTP(w, r)
@@ -892,8 +908,7 @@
 	b := NewBuildFile(srv, utils.NewWriteFlusher(w), !suppressOutput, !noCache, rm)
 	id, err := b.Build(context)
 	if err != nil {
-		fmt.Fprintf(w, "Error build: %s\n", err)
-		return err
+		return fmt.Errorf("Error build: %s", err)
 	}
 	if repoName != "" {
 		srv.runtime.repositories.Set(repoName, tag, id, false)
@@ -925,7 +940,7 @@
 	}
 
 	if err := srv.ContainerCopy(name, copyData.Resource, w); err != nil {
-		utils.Debugf("%s", err.Error())
+		utils.Errorf("%s", err.Error())
 		return err
 	}
 	return nil
@@ -970,7 +985,7 @@
 		}
 
 		if err := handlerFunc(srv, version, w, r, mux.Vars(r)); err != nil {
-			utils.Debugf("Error: %s", err)
+			utils.Errorf("Error: %s", err)
 			httpError(w, err)
 		}
 	}
diff --git a/api_test.go b/api_test.go
index d24cf7c..fcb3bc8 100644
--- a/api_test.go
+++ b/api_test.go
@@ -5,6 +5,7 @@
 	"bufio"
 	"bytes"
 	"encoding/json"
+	"fmt"
 	"github.com/dotcloud/docker/utils"
 	"io"
 	"net"
@@ -12,6 +13,7 @@
 	"net/http/httptest"
 	"os"
 	"path"
+	"strings"
 	"testing"
 	"time"
 )
@@ -40,6 +42,25 @@
 	}
 }
 
+func TesthttpError(t *testing.T) {
+	r := httptest.NewRecorder()
+
+	httpError(r, fmt.Errorf("No such method"))
+	if r.Code != http.StatusNotFound {
+		t.Fatalf("Expected %d, got %d", http.StatusNotFound, r.Code)
+	}
+
+	httpError(r, fmt.Errorf("This accound hasn't been activated"))
+	if r.Code != http.StatusForbidden {
+		t.Fatalf("Expected %d, got %d", http.StatusForbidden, r.Code)
+	}
+
+	httpError(r, fmt.Errorf("Some error"))
+	if r.Code != http.StatusInternalServerError {
+		t.Fatalf("Expected %d, got %d", http.StatusInternalServerError, r.Code)
+	}
+}
+
 func TestGetVersion(t *testing.T) {
 	var err error
 	runtime := mkRuntime(t)
@@ -243,7 +264,11 @@
 		t.Fatalf("Error expected, received none")
 	}
 
-	httpError(r4, err)
+	if !strings.HasPrefix(err.Error(), "Bad parameter") {
+		t.Fatalf("Error should starts with \"Bad parameter\"")
+	}
+	http.Error(r4, err.Error(), http.StatusBadRequest)
+
 	if r4.Code != http.StatusBadRequest {
 		t.Fatalf("%d Bad Request expected, received %d\n", http.StatusBadRequest, r4.Code)
 	}
@@ -566,7 +591,6 @@
 
 	srv := &Server{runtime: runtime}
 
-
 	// Create a container and remove a file
 	container, err := runtime.Create(
 		&Config{
@@ -777,6 +801,8 @@
 		t.Fatal(err)
 	}
 
+	req.Header.Set("Content-Type", "application/json")
+
 	r := httptest.NewRecorder()
 	if err := postContainersStart(srv, APIVERSION, r, req, map[string]string{"name": container.ID}); err != nil {
 		t.Fatal(err)
@@ -952,7 +978,96 @@
 	})
 
 	setTimeout(t, "read/write assertion timed out", 2*time.Second, func() {
-		if err := assertPipe("hello\n", "hello", stdout, stdinPipe, 15); err != nil {
+		if err := assertPipe("hello\n", string([]byte{1, 0, 0, 0, 0, 0, 0, 6})+"hello", stdout, stdinPipe, 15); err != nil {
+			t.Fatal(err)
+		}
+	})
+
+	// Close pipes (client disconnects)
+	if err := closeWrap(stdin, stdinPipe, stdout, stdoutPipe); err != nil {
+		t.Fatal(err)
+	}
+
+	// Wait for attach to finish, the client disconnected, therefore, Attach finished his job
+	setTimeout(t, "Waiting for CmdAttach timed out", 10*time.Second, func() {
+		<-c1
+	})
+
+	// We closed stdin, expect /bin/cat to still be running
+	// Wait a little bit to make sure container.monitor() did his thing
+	err = container.WaitTimeout(500 * time.Millisecond)
+	if err == nil || !container.State.Running {
+		t.Fatalf("/bin/cat is not running after closing stdin")
+	}
+
+	// Try to avoid the timeout in destroy. Best effort, don't check error
+	cStdin, _ := container.StdinPipe()
+	cStdin.Close()
+	container.Wait()
+}
+
+func TestPostContainersAttachStderr(t *testing.T) {
+	runtime := mkRuntime(t)
+	defer nuke(runtime)
+
+	srv := &Server{runtime: runtime}
+
+	container, err := runtime.Create(
+		&Config{
+			Image:     GetTestImage(runtime).ID,
+			Cmd:       []string{"/bin/sh", "-c", "/bin/cat >&2"},
+			OpenStdin: true,
+		},
+	)
+	if err != nil {
+		t.Fatal(err)
+	}
+	defer runtime.Destroy(container)
+
+	// Start the process
+	hostConfig := &HostConfig{}
+	if err := container.Start(hostConfig); err != nil {
+		t.Fatal(err)
+	}
+
+	stdin, stdinPipe := io.Pipe()
+	stdout, stdoutPipe := io.Pipe()
+
+	// Try to avoid the timeout in destroy. Best effort, don't check error
+	defer func() {
+		closeWrap(stdin, stdinPipe, stdout, stdoutPipe)
+		container.Kill()
+	}()
+
+	// Attach to it
+	c1 := make(chan struct{})
+	go func() {
+		defer close(c1)
+
+		r := &hijackTester{
+			ResponseRecorder: httptest.NewRecorder(),
+			in:               stdin,
+			out:              stdoutPipe,
+		}
+
+		req, err := http.NewRequest("POST", "/containers/"+container.ID+"/attach?stream=1&stdin=1&stdout=1&stderr=1", bytes.NewReader([]byte{}))
+		if err != nil {
+			t.Fatal(err)
+		}
+
+		if err := postContainersAttach(srv, APIVERSION, r, req, map[string]string{"name": container.ID}); err != nil {
+			t.Fatal(err)
+		}
+	}()
+
+	// Acknowledge hijack
+	setTimeout(t, "hijack acknowledge timed out", 2*time.Second, func() {
+		stdout.Read([]byte{})
+		stdout.Read(make([]byte, 4096))
+	})
+
+	setTimeout(t, "read/write assertion timed out", 2*time.Second, func() {
+		if err := assertPipe("hello\n", string([]byte{2, 0, 0, 0, 0, 0, 0, 6})+"hello", stdout, stdinPipe, 15); err != nil {
 			t.Fatal(err)
 		}
 	})
diff --git a/auth/auth.go b/auth/auth.go
index aff6de6..58b5f92 100644
--- a/auth/auth.go
+++ b/auth/auth.go
@@ -91,11 +91,17 @@
 		}
 		authConfig := AuthConfig{}
 		origAuth := strings.Split(arr[0], " = ")
+		if len(origAuth) != 2 {
+			return &configFile, fmt.Errorf("Invalid Auth config file")
+		}
 		authConfig.Username, authConfig.Password, err = decodeAuth(origAuth[1])
 		if err != nil {
 			return &configFile, err
 		}
 		origEmail := strings.Split(arr[1], " = ")
+		if len(origEmail) != 2 {
+			return &configFile, fmt.Errorf("Invalid Auth config file")
+		}
 		authConfig.Email = origEmail[1]
 		authConfig.ServerAddress = IndexServerAddress()
 		configFile.Configs[IndexServerAddress()] = authConfig
@@ -239,7 +245,7 @@
 	// as there is only one auth entry which is fully qualified we need to start
 	// parsing and matching
 
-	swapProtocoll := func(url string) string {
+	swapProtocol := func(url string) string {
 		if strings.HasPrefix(url, "http:") {
 			return strings.Replace(url, "http:", "https:", 1)
 		}
@@ -253,9 +259,9 @@
 		if c, found := config.Configs[url]; found {
 			return c
 		}
-		registrySwappedProtocoll := swapProtocoll(url)
+		registrySwappedProtocol := swapProtocol(url)
 		// now try to match with the different protocol
-		if c, found := config.Configs[registrySwappedProtocoll]; found {
+		if c, found := config.Configs[registrySwappedProtocol]; found {
 			return c
 		}
 		return AuthConfig{}
diff --git a/auth/auth_test.go b/auth/auth_test.go
index 24a0666..01aecae 100644
--- a/auth/auth_test.go
+++ b/auth/auth_test.go
@@ -75,20 +75,31 @@
 	}
 }
 
-func TestSameAuthDataPostSave(t *testing.T) {
+func setupTempConfigFile() (*ConfigFile, error) {
 	root, err := ioutil.TempDir("", "docker-test")
 	if err != nil {
-		t.Fatal(err)
+		return nil, err
 	}
 	configFile := &ConfigFile{
 		rootPath: root,
-		Configs:  make(map[string]AuthConfig, 1),
+		Configs:  make(map[string]AuthConfig),
 	}
 
-	configFile.Configs["testIndex"] = AuthConfig{
-		Username: "docker-user",
-		Password: "docker-pass",
-		Email:    "docker@docker.io",
+	for _, registry := range []string{"testIndex", IndexServerAddress()} {
+		configFile.Configs[registry] = AuthConfig{
+			Username: "docker-user",
+			Password: "docker-pass",
+			Email:    "docker@docker.io",
+		}
+	}
+
+	return configFile, nil
+}
+
+func TestSameAuthDataPostSave(t *testing.T) {
+	configFile, err := setupTempConfigFile()
+	if err != nil {
+		t.Fatal(err)
 	}
 
 	err = SaveConfig(configFile)
@@ -110,3 +121,68 @@
 		t.Fail()
 	}
 }
+
+func TestResolveAuthConfigIndexServer(t *testing.T) {
+	configFile, err := setupTempConfigFile()
+	if err != nil {
+		t.Fatal(err)
+	}
+
+	for _, registry := range []string{"", IndexServerAddress()} {
+		resolved := configFile.ResolveAuthConfig(registry)
+		if resolved != configFile.Configs[IndexServerAddress()] {
+			t.Fail()
+		}
+	}
+}
+
+func TestResolveAuthConfigFullURL(t *testing.T) {
+	configFile, err := setupTempConfigFile()
+	if err != nil {
+		t.Fatal(err)
+	}
+
+	registryAuth := AuthConfig{
+		Username: "foo-user",
+		Password: "foo-pass",
+		Email:    "foo@example.com",
+	}
+	localAuth := AuthConfig{
+		Username: "bar-user",
+		Password: "bar-pass",
+		Email:    "bar@example.com",
+	}
+	configFile.Configs["https://registry.example.com/v1/"] = registryAuth
+	configFile.Configs["http://localhost:8000/v1/"] = localAuth
+
+	validRegistries := map[string][]string{
+		"https://registry.example.com/v1/": {
+			"https://registry.example.com/v1/",
+			"http://registry.example.com/v1/",
+			"registry.example.com",
+			"registry.example.com/v1/",
+		},
+		"http://localhost:8000/v1/": {
+			"https://localhost:8000/v1/",
+			"http://localhost:8000/v1/",
+			"localhost:8000",
+			"localhost:8000/v1/",
+		},
+	}
+
+	for configKey, registries := range validRegistries {
+		for _, registry := range registries {
+			var (
+				configured AuthConfig
+				ok         bool
+			)
+			resolved := configFile.ResolveAuthConfig(registry)
+			if configured, ok = configFile.Configs[configKey]; !ok {
+				t.Fail()
+			}
+			if resolved.Email != configured.Email {
+				t.Errorf("%s -> %q != %q\n", registry, resolved.Email, configured.Email)
+			}
+		}
+	}
+}
diff --git a/buildfile.go b/buildfile.go
index 7f2ea00..8231287 100644
--- a/buildfile.go
+++ b/buildfile.go
@@ -458,9 +458,8 @@
 var lineContinuation = regexp.MustCompile(`\s*\\\s*\n`)
 
 func (b *buildFile) Build(context io.Reader) (string, error) {
-	// FIXME: @creack any reason for using /tmp instead of ""?
 	// FIXME: @creack "name" is a terrible variable name
-	name, err := ioutil.TempDir("/tmp", "docker-build")
+	name, err := ioutil.TempDir("", "docker-build")
 	if err != nil {
 		return "", err
 	}
diff --git a/commands.go b/commands.go
index 556debd..7d33b81 100644
--- a/commands.go
+++ b/commands.go
@@ -303,7 +303,7 @@
 	}
 
 	cli.LoadConfigFile()
-	authconfig, ok := cli.configFile.Configs[auth.IndexServerAddress()]
+	authconfig, ok := cli.configFile.Configs[serverAddress]
 	if !ok {
 		authconfig = auth.AuthConfig{}
 	}
@@ -418,7 +418,7 @@
 	var out APIVersion
 	err = json.Unmarshal(body, &out)
 	if err != nil {
-		utils.Debugf("Error unmarshal: body: %s, err: %s\n", body, err)
+		utils.Errorf("Error unmarshal: body: %s, err: %s\n", body, err)
 		return err
 	}
 	if out.Version != "" {
@@ -1230,7 +1230,7 @@
 		return nil
 	}
 
-	if err := cli.hijack("POST", "/containers/"+cmd.Arg(0)+"/attach?logs=1&stdout=1&stderr=1", false, nil, cli.out); err != nil {
+	if err := cli.hijack("POST", "/containers/"+cmd.Arg(0)+"/attach?logs=1&stdout=1&stderr=1", false, nil, cli.out, cli.err); err != nil {
 		return err
 	}
 	return nil
@@ -1273,7 +1273,7 @@
 	v.Set("stdout", "1")
 	v.Set("stderr", "1")
 
-	if err := cli.hijack("POST", "/containers/"+cmd.Arg(0)+"/attach?"+v.Encode(), container.Config.Tty, cli.in, cli.out); err != nil {
+	if err := cli.hijack("POST", "/containers/"+cmd.Arg(0)+"/attach?"+v.Encode(), container.Config.Tty, cli.in, cli.out, cli.err); err != nil {
 		return err
 	}
 	return nil
@@ -1433,6 +1433,9 @@
 		return nil
 	}
 
+	flRm := cmd.Lookup("rm")
+	autoRemove, _ := strconv.ParseBool(flRm.Value.String())
+
 	var containerIDFile *os.File
 	if len(hostConfig.ContainerIDFile) > 0 {
 		if _, err := ioutil.ReadFile(hostConfig.ContainerIDFile); err == nil {
@@ -1530,14 +1533,14 @@
 	if config.AttachStdin || config.AttachStdout || config.AttachStderr {
 		if config.Tty {
 			if err := cli.monitorTtySize(runResult.ID); err != nil {
-				utils.Debugf("Error monitoring TTY size: %s\n", err)
+				utils.Errorf("Error monitoring TTY size: %s\n", err)
 			}
 		}
 
 		v := url.Values{}
 		v.Set("logs", "1")
 		v.Set("stream", "1")
-		var out io.Writer
+		var out, stderr io.Writer
 
 		if config.AttachStdin {
 			v.Set("stdin", "1")
@@ -1548,7 +1551,11 @@
 		}
 		if config.AttachStderr {
 			v.Set("stderr", "1")
-			out = cli.out
+			if config.Tty {
+				stderr = cli.out
+			} else {
+				stderr = cli.err
+			}
 		}
 
 		signals := make(chan os.Signal, 1)
@@ -1562,7 +1569,7 @@
 			}
 		}()
 
-		if err := cli.hijack("POST", "/containers/"+runResult.ID+"/attach?"+v.Encode(), config.Tty, cli.in, out); err != nil {
+		if err := cli.hijack("POST", "/containers/"+runResult.ID+"/attach?"+v.Encode(), config.Tty, cli.in, out, stderr); err != nil {
 			utils.Debugf("Error hijack: %s", err)
 			return err
 		}
@@ -1576,6 +1583,12 @@
 		if err != nil {
 			return err
 		}
+		if autoRemove {
+			_, _, err = cli.call("DELETE", "/containers/"+runResult.ID, nil)
+			if err != nil {
+				return err
+			}
+		}
 		if status != 0 {
 			return &utils.StatusError{Status: status}
 		}
@@ -1729,7 +1742,7 @@
 	return nil
 }
 
-func (cli *DockerCli) hijack(method, path string, setRawTerminal bool, in io.ReadCloser, out io.Writer) error {
+func (cli *DockerCli) hijack(method, path string, setRawTerminal bool, in io.ReadCloser, stdout, stderr io.Writer) error {
 
 	req, err := http.NewRequest(method, fmt.Sprintf("/v%g%s", APIVERSION, path), nil)
 	if err != nil {
@@ -1755,10 +1768,16 @@
 	rwc, br := clientconn.Hijack()
 	defer rwc.Close()
 
-	var receiveStdout (chan error)
-	if out != nil {
-		receiveStdout = utils.Go(func() error {
-			_, err := io.Copy(out, br)
+	var receiveStdout chan error
+
+	if stdout != nil {
+		receiveStdout = utils.Go(func() (err error) {
+			// When TTY is ON, use regular copy
+			if setRawTerminal {
+				_, err = io.Copy(stdout, br)
+			} else {
+				_, err = utils.StdCopy(stdout, stderr, br)
+			}
 			utils.Debugf("[hijack] End of stdout")
 			return err
 		})
@@ -1779,27 +1798,27 @@
 		}
 		if tcpc, ok := rwc.(*net.TCPConn); ok {
 			if err := tcpc.CloseWrite(); err != nil {
-				utils.Debugf("Couldn't send EOF: %s\n", err)
+				utils.Errorf("Couldn't send EOF: %s\n", err)
 			}
 		} else if unixc, ok := rwc.(*net.UnixConn); ok {
 			if err := unixc.CloseWrite(); err != nil {
-				utils.Debugf("Couldn't send EOF: %s\n", err)
+				utils.Errorf("Couldn't send EOF: %s\n", err)
 			}
 		}
 		// Discard errors due to pipe interruption
 		return nil
 	})
 
-	if out != nil {
+	if stdout != nil {
 		if err := <-receiveStdout; err != nil {
-			utils.Debugf("Error receiveStdout: %s", err)
+			utils.Errorf("Error receiveStdout: %s", err)
 			return err
 		}
 	}
 
 	if !cli.isTerminal {
 		if err := <-sendStdin; err != nil {
-			utils.Debugf("Error sendStdin: %s", err)
+			utils.Errorf("Error sendStdin: %s", err)
 			return err
 		}
 	}
@@ -1813,7 +1832,7 @@
 	}
 	ws, err := term.GetWinsize(cli.terminalFd)
 	if err != nil {
-		utils.Debugf("Error getting size: %s", err)
+		utils.Errorf("Error getting size: %s", err)
 		if ws == nil {
 			return 0, 0
 		}
@@ -1830,7 +1849,7 @@
 	v.Set("h", strconv.Itoa(height))
 	v.Set("w", strconv.Itoa(width))
 	if _, _, err := cli.call("POST", "/containers/"+id+"/resize?"+v.Encode(), nil); err != nil {
-		utils.Debugf("Error resize: %s", err)
+		utils.Errorf("Error resize: %s", err)
 	}
 }
 
diff --git a/commands_test.go b/commands_test.go
index dbd85be..aceb7a6 100644
--- a/commands_test.go
+++ b/commands_test.go
@@ -400,7 +400,7 @@
 	})
 
 	// wait for CmdRun to return
-	setTimeout(t, "Waiting for CmdRun timed out", 5*time.Second, func() {
+	setTimeout(t, "Waiting for CmdRun timed out", 15*time.Second, func() {
 		<-ch
 	})
 
@@ -458,7 +458,7 @@
 	})
 
 	// wait for CmdRun to return
-	setTimeout(t, "Waiting for CmdAttach timed out", 5*time.Second, func() {
+	setTimeout(t, "Waiting for CmdAttach timed out", 15*time.Second, func() {
 		<-ch
 	})
 
@@ -542,3 +542,41 @@
 	cStdin.Close()
 	container.Wait()
 }
+
+// Expected behaviour: container gets deleted automatically after exit
+func TestRunAutoRemove(t *testing.T) {
+	t.Skip("Fixme. Skipping test for now, race condition")
+	stdout, stdoutPipe := io.Pipe()
+	cli := NewDockerCli(nil, stdoutPipe, ioutil.Discard, testDaemonProto, testDaemonAddr)
+	defer cleanup(globalRuntime)
+
+	c := make(chan struct{})
+	go func() {
+		defer close(c)
+		if err := cli.CmdRun("-rm", unitTestImageID, "hostname"); err != nil {
+			t.Fatal(err)
+		}
+	}()
+
+	var temporaryContainerID string
+	setTimeout(t, "Reading command output time out", 2*time.Second, func() {
+		cmdOutput, err := bufio.NewReader(stdout).ReadString('\n')
+		if err != nil {
+			t.Fatal(err)
+		}
+		temporaryContainerID = cmdOutput
+		if err := closeWrap(stdout, stdoutPipe); err != nil {
+			t.Fatal(err)
+		}
+	})
+
+	setTimeout(t, "CmdRun timed out", 5*time.Second, func() {
+		<-c
+	})
+
+	time.Sleep(500 * time.Millisecond)
+
+	if len(globalRuntime.List()) > 0 {
+		t.Fatalf("failed to remove container automatically: container %s still exists", temporaryContainerID)
+	}
+}
diff --git a/container.go b/container.go
index 6bca3df..7d85aef 100644
--- a/container.go
+++ b/container.go
@@ -126,6 +126,7 @@
 	flContainerIDFile := cmd.String("cidfile", "", "Write the container ID to the file")
 	flNetwork := cmd.Bool("n", true, "Enable networking for this container")
 	flPrivileged := cmd.Bool("privileged", false, "Give extended privileges to this container")
+	flAutoRemove := cmd.Bool("rm", false, "Automatically remove the container when it exits (incompatible with -d)")
 
 	if capabilities != nil && *flMemory > 0 && !capabilities.MemoryLimit {
 		//fmt.Fprintf(stdout, "WARNING: Your kernel does not support memory limit capabilities. Limitation discarded.\n")
@@ -174,6 +175,10 @@
 		}
 	}
 
+	if *flDetach && *flAutoRemove {
+		return nil, nil, cmd, fmt.Errorf("Conflicting options: -rm and -d")
+	}
+
 	var binds []string
 
 	// add any bind targets to the list of container volumes
@@ -385,20 +390,20 @@
 	// Copy the PTYs to our broadcasters
 	go func() {
 		defer container.stdout.CloseWriters()
-		utils.Debugf("[startPty] Begin of stdout pipe")
+		utils.Debugf("startPty: begin of stdout pipe")
 		io.Copy(container.stdout, ptyMaster)
-		utils.Debugf("[startPty] End of stdout pipe")
+		utils.Debugf("startPty: end of stdout pipe")
 	}()
 
 	// stdin
 	if container.Config.OpenStdin {
 		container.cmd.Stdin = ptySlave
-		container.cmd.SysProcAttr = &syscall.SysProcAttr{Setctty: true, Setsid: true}
+		container.cmd.SysProcAttr.Setctty = true
 		go func() {
 			defer container.stdin.Close()
-			utils.Debugf("[startPty] Begin of stdin pipe")
+			utils.Debugf("startPty: begin of stdin pipe")
 			io.Copy(ptyMaster, container.stdin)
-			utils.Debugf("[startPty] End of stdin pipe")
+			utils.Debugf("startPty: end of stdin pipe")
 		}()
 	}
 	if err := container.cmd.Start(); err != nil {
@@ -418,9 +423,9 @@
 		}
 		go func() {
 			defer stdin.Close()
-			utils.Debugf("Begin of stdin pipe [start]")
+			utils.Debugf("start: begin of stdin pipe")
 			io.Copy(stdin, container.stdin)
-			utils.Debugf("End of stdin pipe [start]")
+			utils.Debugf("start: end of stdin pipe")
 		}()
 	}
 	return container.cmd.Start()
@@ -437,8 +442,8 @@
 			errors <- err
 		} else {
 			go func() {
-				utils.Debugf("[start] attach stdin\n")
-				defer utils.Debugf("[end] attach stdin\n")
+				utils.Debugf("attach: stdin: begin")
+				defer utils.Debugf("attach: stdin: end")
 				// No matter what, when stdin is closed (io.Copy unblock), close stdout and stderr
 				if container.Config.StdinOnce && !container.Config.Tty {
 					defer cStdin.Close()
@@ -456,7 +461,7 @@
 					_, err = io.Copy(cStdin, stdin)
 				}
 				if err != nil {
-					utils.Debugf("[error] attach stdin: %s\n", err)
+					utils.Errorf("attach: stdin: %s", err)
 				}
 				// Discard error, expecting pipe error
 				errors <- nil
@@ -470,20 +475,21 @@
 		} else {
 			cStdout = p
 			go func() {
-				utils.Debugf("[start] attach stdout\n")
-				defer utils.Debugf("[end]  attach stdout\n")
+				utils.Debugf("attach: stdout: begin")
+				defer utils.Debugf("attach: stdout: end")
 				// If we are in StdinOnce mode, then close stdin
-				if container.Config.StdinOnce {
-					if stdin != nil {
-						defer stdin.Close()
-					}
-					if stdinCloser != nil {
-						defer stdinCloser.Close()
-					}
+				if container.Config.StdinOnce && stdin != nil {
+					defer stdin.Close()
+				}
+				if stdinCloser != nil {
+					defer stdinCloser.Close()
 				}
 				_, err := io.Copy(stdout, cStdout)
+				if err == io.ErrClosedPipe {
+					err = nil
+				}
 				if err != nil {
-					utils.Debugf("[error] attach stdout: %s\n", err)
+					utils.Errorf("attach: stdout: %s", err)
 				}
 				errors <- err
 			}()
@@ -493,9 +499,8 @@
 			if stdinCloser != nil {
 				defer stdinCloser.Close()
 			}
-
 			if cStdout, err := container.StdoutPipe(); err != nil {
-				utils.Debugf("Error stdout pipe")
+				utils.Errorf("attach: stdout pipe: %s", err)
 			} else {
 				io.Copy(&utils.NopWriter{}, cStdout)
 			}
@@ -508,20 +513,21 @@
 		} else {
 			cStderr = p
 			go func() {
-				utils.Debugf("[start] attach stderr\n")
-				defer utils.Debugf("[end]  attach stderr\n")
+				utils.Debugf("attach: stderr: begin")
+				defer utils.Debugf("attach: stderr: end")
 				// If we are in StdinOnce mode, then close stdin
-				if container.Config.StdinOnce {
-					if stdin != nil {
-						defer stdin.Close()
-					}
-					if stdinCloser != nil {
-						defer stdinCloser.Close()
-					}
+				if container.Config.StdinOnce && stdin != nil {
+					defer stdin.Close()
+				}
+				if stdinCloser != nil {
+					defer stdinCloser.Close()
 				}
 				_, err := io.Copy(stderr, cStderr)
+				if err == io.ErrClosedPipe {
+					err = nil
+				}
 				if err != nil {
-					utils.Debugf("[error] attach stderr: %s\n", err)
+					utils.Errorf("attach: stderr: %s", err)
 				}
 				errors <- err
 			}()
@@ -533,7 +539,7 @@
 			}
 
 			if cStderr, err := container.StderrPipe(); err != nil {
-				utils.Debugf("Error stdout pipe")
+				utils.Errorf("attach: stdout pipe: %s", err)
 			} else {
 				io.Copy(&utils.NopWriter{}, cStderr)
 			}
@@ -547,24 +553,29 @@
 		if cStderr != nil {
 			defer cStderr.Close()
 		}
-		// FIXME: how do clean up the stdin goroutine without the unwanted side effect
+		// FIXME: how to clean up the stdin goroutine without the unwanted side effect
 		// of closing the passed stdin? Add an intermediary io.Pipe?
 		for i := 0; i < nJobs; i += 1 {
-			utils.Debugf("Waiting for job %d/%d\n", i+1, nJobs)
+			utils.Debugf("attach: waiting for job %d/%d", i+1, nJobs)
 			if err := <-errors; err != nil {
-				utils.Debugf("Job %d returned error %s. Aborting all jobs\n", i+1, err)
+				utils.Errorf("attach: job %d returned error %s, aborting all jobs", i+1, err)
 				return err
 			}
-			utils.Debugf("Job %d completed successfully\n", i+1)
+			utils.Debugf("attach: job %d completed successfully", i+1)
 		}
-		utils.Debugf("All jobs completed successfully\n")
+		utils.Debugf("attach: all jobs completed successfully")
 		return nil
 	})
 }
 
-func (container *Container) Start(hostConfig *HostConfig) error {
+func (container *Container) Start(hostConfig *HostConfig) (err error) {
 	container.State.Lock()
 	defer container.State.Unlock()
+	defer func() {
+		if err != nil {
+			container.cleanup()
+		}
+	}()
 
 	if hostConfig == nil { // in docker start of docker restart we want to reuse previous HostConfigFile
 		hostConfig, _ = container.ReadHostConfig()
@@ -800,7 +811,8 @@
 		return err
 	}
 
-	var err error
+	container.cmd.SysProcAttr = &syscall.SysProcAttr{Setsid: true}
+
 	if container.Config.Tty {
 		err = container.startPty()
 	} else {
@@ -818,7 +830,7 @@
 
 	container.ToDisk()
 	container.SaveHostConfig(hostConfig)
-	go container.monitor()
+	go container.monitor(hostConfig)
 	return nil
 }
 
@@ -846,9 +858,14 @@
 	return output, err
 }
 
-// StdinPipe() returns a pipe connected to the standard input of the container's
-// active process.
-//
+// Container.StdinPipe returns a WriteCloser which can be used to feed data
+// to the standard input of the container's active process.
+// Container.StdoutPipe and Container.StderrPipe each return a ReadCloser
+// which can be used to retrieve the standard output (and error) generated
+// by the container's active process. The output (and error) are actually
+// copied and delivered to all StdoutPipe and StderrPipe consumers, using
+// a kind of "broadcaster".
+
 func (container *Container) StdinPipe() (io.WriteCloser, error) {
 	return container.stdinPipe, nil
 }
@@ -926,7 +943,7 @@
 }
 
 func (container *Container) releaseNetwork() {
-	if container.Config.NetworkDisabled {
+	if container.Config.NetworkDisabled || container.network == nil {
 		return
 	}
 	container.network.Release()
@@ -948,22 +965,25 @@
 	}
 }
 
-func (container *Container) monitor() {
+func (container *Container) monitor(hostConfig *HostConfig) {
 	// Wait for the program to exit
-	utils.Debugf("Waiting for process")
 
-	// If the command does not exists, try to wait via lxc
+	// If the command does not exist, try to wait via lxc
+	// (This probably happens only for ghost containers, i.e. containers that were running when Docker started)
 	if container.cmd == nil {
+		utils.Debugf("monitor: waiting for container %s using waitLxc", container.ID)
 		if err := container.waitLxc(); err != nil {
-			utils.Debugf("%s: Process: %s", container.ID, err)
+			utils.Errorf("monitor: while waiting for container %s, waitLxc had a problem: %s", container.ID, err)
 		}
 	} else {
+		utils.Debugf("monitor: waiting for container %s using cmd.Wait", container.ID)
 		if err := container.cmd.Wait(); err != nil {
-			// Discard the error as any signals or non 0 returns will generate an error
-			utils.Debugf("%s: Process: %s", container.ID, err)
+			// Since non-zero exit status and signal terminations will cause err to be non-nil,
+			// we have to actually discard it. Still, log it anyway, just in case.
+			utils.Debugf("monitor: cmd.Wait reported exit status %s for container %s", err, container.ID)
 		}
 	}
-	utils.Debugf("Process finished")
+	utils.Debugf("monitor: container %s finished", container.ID)
 
 	exitCode := -1
 	if container.cmd != nil {
@@ -978,28 +998,7 @@
 	}
 
 	// Cleanup
-	container.releaseNetwork()
-	if container.Config.OpenStdin {
-		if err := container.stdin.Close(); err != nil {
-			utils.Debugf("%s: Error close stdin: %s", container.ID, err)
-		}
-	}
-	if err := container.stdout.CloseWriters(); err != nil {
-		utils.Debugf("%s: Error close stdout: %s", container.ID, err)
-	}
-	if err := container.stderr.CloseWriters(); err != nil {
-		utils.Debugf("%s: Error close stderr: %s", container.ID, err)
-	}
-
-	if container.ptyMaster != nil {
-		if err := container.ptyMaster.Close(); err != nil {
-			utils.Debugf("%s: Error closing Pty master: %s", container.ID, err)
-		}
-	}
-
-	if err := container.Unmount(); err != nil {
-		log.Printf("%v: Failed to umount filesystem: %v", container.ID, err)
-	}
+	container.cleanup()
 
 	// Re-create a brand new stdin pipe once the container exited
 	if container.Config.OpenStdin {
@@ -1020,6 +1019,31 @@
 	}
 }
 
+func (container *Container) cleanup() {
+	container.releaseNetwork()
+	if container.Config.OpenStdin {
+		if err := container.stdin.Close(); err != nil {
+			utils.Errorf("%s: Error close stdin: %s", container.ID, err)
+		}
+	}
+	if err := container.stdout.CloseWriters(); err != nil {
+		utils.Errorf("%s: Error close stdout: %s", container.ID, err)
+	}
+	if err := container.stderr.CloseWriters(); err != nil {
+		utils.Errorf("%s: Error close stderr: %s", container.ID, err)
+	}
+
+	if container.ptyMaster != nil {
+		if err := container.ptyMaster.Close(); err != nil {
+			utils.Errorf("%s: Error closing Pty master: %s", container.ID, err)
+		}
+	}
+
+	if err := container.Unmount(); err != nil {
+		log.Printf("%v: Failed to umount filesystem: %v", container.ID, err)
+	}
+}
+
 func (container *Container) kill() error {
 	if !container.State.Running {
 		return nil
diff --git a/contrib/Dockerfile.tmLanguage/Dockerfile.YAML-tmLanguage b/contrib/Dockerfile.tmLanguage/Dockerfile.YAML-tmLanguage
new file mode 100644
index 0000000..2323c40
--- /dev/null
+++ b/contrib/Dockerfile.tmLanguage/Dockerfile.YAML-tmLanguage
@@ -0,0 +1,23 @@
+# [PackageDev] target_format: plist, ext: tmLanguage
+---
+name: Dockerfile
+scopeName: source.dockerfile
+uuid: a39d8795-59d2-49af-aa00-fe74ee29576e
+
+patterns:
+# Keywords
+- name: keyword.control.dockerfile
+  match: ^\s*(FROM|MAINTAINER|RUN|CMD|EXPOSE|ENV|ADD)\s
+- name: keyword.operator.dockerfile
+  match: ^\s*(ENTRYPOINT|VOLUME|USER|WORKDIR)\s
+# String
+- name: string.quoted.double.dockerfile
+  begin: "\""
+  end: "\""
+  patterns:
+  - name: constant.character.escaped.dockerfile
+    match: \\.
+# Comment
+- name: comment.block.dockerfile
+  match: ^\s*#.*$
+...
\ No newline at end of file
diff --git a/contrib/Dockerfile.tmLanguage/Dockerfile.tmLanguage b/contrib/Dockerfile.tmLanguage/Dockerfile.tmLanguage
new file mode 100644
index 0000000..ce5bb5e
--- /dev/null
+++ b/contrib/Dockerfile.tmLanguage/Dockerfile.tmLanguage
@@ -0,0 +1,50 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+<plist version="1.0">
+<dict>
+	<key>name</key>
+	<string>Dockerfile</string>
+	<key>patterns</key>
+	<array>
+		<dict>
+			<key>match</key>
+			<string>^\s*(FROM|MAINTAINER|RUN|CMD|EXPOSE|ENV|ADD)\s</string>
+			<key>name</key>
+			<string>keyword.control.dockerfile</string>
+		</dict>
+		<dict>
+			<key>match</key>
+			<string>^\s*(ENTRYPOINT|VOLUME|USER|WORKDIR)\s</string>
+			<key>name</key>
+			<string>keyword.operator.dockerfile</string>
+		</dict>
+		<dict>
+			<key>begin</key>
+			<string>"</string>
+			<key>end</key>
+			<string>"</string>
+			<key>name</key>
+			<string>string.quoted.double.dockerfile</string>
+			<key>patterns</key>
+			<array>
+				<dict>
+					<key>match</key>
+					<string>\\.</string>
+					<key>name</key>
+					<string>constant.character.escaped.dockerfile</string>
+				</dict>
+			</array>
+		</dict>
+		<dict>
+			<key>match</key>
+			<string>^\s*#.*$</string>
+			<key>name</key>
+			<string>comment.block.dockerfile</string>
+		</dict>
+	</array>
+	<key>scopeName</key>
+	<string>source.dockerfile</string>
+	<key>uuid</key>
+	<string>a39d8795-59d2-49af-aa00-fe74ee29576e</string>
+</dict>
+</plist>
diff --git a/contrib/Dockerfile.tmLanguage/MAINTAINERS b/contrib/Dockerfile.tmLanguage/MAINTAINERS
new file mode 100644
index 0000000..965743d
--- /dev/null
+++ b/contrib/Dockerfile.tmLanguage/MAINTAINERS
@@ -0,0 +1 @@
+Asbjorn Enge <asbjorn@hanafjedle.net> (@asbjornenge)
diff --git a/contrib/Dockerfile.tmLanguage/README.md b/contrib/Dockerfile.tmLanguage/README.md
new file mode 100644
index 0000000..157b5c9
--- /dev/null
+++ b/contrib/Dockerfile.tmLanguage/README.md
@@ -0,0 +1,9 @@
+# Dockerfile.tmLanguage
+
+Pretty basic Dockerfile.tmLanguage for Sublime Text syntax highlighting.
+
+PR's with syntax updates, suggestions etc. are all very much appreciated!
+
+I'll get to making this installable via Package Control soon!
+
+enjoy.
diff --git a/contrib/MAINTAINERS b/contrib/MAINTAINERS
index e6aeeeb..18e05a3 100644
--- a/contrib/MAINTAINERS
+++ b/contrib/MAINTAINERS
@@ -1,2 +1 @@
-Kawsar Saiyeed <kawsar.saiyeed@projiris.com> (@KSid)
 Tianon Gravi <admwiggin@gmail.com> (@tianon)
diff --git a/contrib/docker.bash b/contrib/completion/bash/docker
old mode 100644
new mode 100755
similarity index 98%
rename from contrib/docker.bash
rename to contrib/completion/bash/docker
index aa9fb3d..5a91ab0
--- a/contrib/docker.bash
+++ b/contrib/completion/bash/docker
@@ -341,7 +341,7 @@
 
 _docker_push()
 {
-	return
+	__docker_image_repos
 }
 
 _docker_restart()
diff --git a/contrib/completion/zsh/_docker b/contrib/completion/zsh/_docker
new file mode 100755
index 0000000..92acdb1
--- /dev/null
+++ b/contrib/completion/zsh/_docker
@@ -0,0 +1,242 @@
+#compdef docker 
+#
+# zsh completion for docker (http://docker.io)
+#
+# version:  0.2.2
+# author:   Felix Riedel
+# license:  BSD License
+# github:   https://github.com/felixr/docker-zsh-completion
+#
+
+__parse_docker_list() {
+    sed -e '/^ID/d' -e 's/[ ]\{2,\}/|/g' -e 's/ \([hdwm]\)\(inutes\|ays\|ours\|eeks\)/\1/' | awk ' BEGIN {FS="|"} { printf("%s:%7s, %s\n", $1, $4, $2)}'
+}
+
+__docker_stoppedcontainers() {
+    local expl
+    declare -a stoppedcontainers 
+    stoppedcontainers=(${(f)"$(docker ps -a | grep --color=never 'Exit' |  __parse_docker_list )"})
+    _describe -t containers-stopped "Stopped Containers" stoppedcontainers 
+}
+
+__docker_runningcontainers() {
+    local expl
+    declare -a containers 
+
+    containers=(${(f)"$(docker ps | __parse_docker_list)"})
+    _describe -t containers-active "Running Containers" containers 
+}
+
+__docker_containers () {
+    __docker_stoppedcontainers 
+    __docker_runningcontainers
+}
+
+__docker_images () {
+    local expl
+    declare -a images
+    images=(${(f)"$(docker images | awk '(NR > 1){printf("%s\\:%s\n", $1,$2)}')"})
+    images=($images ${(f)"$(docker images | awk '(NR > 1){printf("%s:%-15s in %s\n", $3,$2,$1)}')"})
+    _describe -t docker-images "Images" images
+}
+
+__docker_tags() {
+    local expl
+    declare -a tags
+    tags=(${(f)"$(docker images | awk '(NR>1){print $2}'| sort | uniq)"})
+    _describe -t docker-tags "tags" tags
+}
+
+__docker_search() {
+    # declare -a dockersearch
+    local cache_policy
+    zstyle -s ":completion:${curcontext}:" cache-policy cache_policy
+    if [[ -z "$cache_policy" ]]; then
+        zstyle ":completion:${curcontext}:" cache-policy __docker_caching_policy 
+    fi
+
+    local searchterm cachename
+    searchterm="${words[$CURRENT]%/}"
+    cachename=_docker-search-$searchterm
+
+    local expl
+    local -a result 
+    if ( [[ ${(P)+cachename} -eq 0 ]] || _cache_invalid ${cachename#_} ) \
+        && ! _retrieve_cache ${cachename#_}; then
+        _message "Searching for ${searchterm}..."
+        result=(${(f)"$(docker search ${searchterm} | awk '(NR>2){print $1}')"})
+        _store_cache ${cachename#_} result
+    fi 
+    _wanted dockersearch expl 'Available images' compadd -a result 
+}
+
+__docker_caching_policy()
+{
+  # oldp=( "$1"(Nmh+24) )     # 24 hour
+  oldp=( "$1"(Nmh+1) )     # 24 hour
+  (( $#oldp ))
+}
+
+
+__docker_repositories () {
+    local expl
+    declare -a repos
+    repos=(${(f)"$(docker images | sed -e '1d' -e 's/[ ].*//' | sort | uniq)"})
+    _describe -t docker-repos "Repositories" repos
+}
+
+__docker_commands () {
+    # local -a  _docker_subcommands
+    local cache_policy
+
+    zstyle -s ":completion:${curcontext}:" cache-policy cache_policy
+    if [[ -z "$cache_policy" ]]; then
+        zstyle ":completion:${curcontext}:" cache-policy __docker_caching_policy 
+    fi
+
+    if ( [[ ${+_docker_subcommands} -eq 0 ]] || _cache_invalid docker_subcommands) \
+        && ! _retrieve_cache docker_subcommands; 
+    then
+        _docker_subcommands=(${${(f)"$(_call_program commands 
+        docker 2>&1 | sed -e '1,6d' -e '/^[ ]*$/d' -e 's/[ ]*\([^ ]\+\)\s*\([^ ].*\)/\1:\2/' )"}})
+        _docker_subcommands=($_docker_subcommands 'help:Show help for a command') 
+        _store_cache docker_subcommands _docker_subcommands
+    fi
+    _describe -t docker-commands "docker command" _docker_subcommands
+}
+
+__docker_subcommand () {
+    local -a _command_args
+    case "$words[1]" in
+        (attach|wait)
+            _arguments ':containers:__docker_runningcontainers'
+            ;;
+        (build)
+            _arguments \
+                '-t=-:repository:__docker_repositories' \
+                ':path or URL:_directories'
+            ;;
+        (commit)
+            _arguments \
+                ':container:__docker_containers' \
+                ':repository:__docker_repositories' \
+                ':tag: '
+            ;;
+        (diff|export|logs)
+            _arguments '*:containers:__docker_containers'
+            ;;
+        (history)
+            _arguments '*:images:__docker_images'
+            ;;
+        (images)
+            _arguments \
+                '-a[Show all images]' \
+                ':repository:__docker_repositories'
+            ;;
+        (inspect)
+            _arguments '*:containers:__docker_containers'
+            ;;
+        (history)
+            _arguments ':images:__docker_images'
+            ;;
+        (insert)
+            _arguments '1:containers:__docker_containers' \
+                       '2:URL:(http:// file://)' \
+                       '3:file:_files'
+            ;;
+        (kill)
+            _arguments '*:containers:__docker_runningcontainers'
+            ;;
+        (port)
+            _arguments '1:containers:__docker_runningcontainers'
+            ;;
+        (start)
+            _arguments '*:containers:__docker_stoppedcontainers'
+            ;;
+        (rm)
+            _arguments '-v[Remove the volumes associated to the container]' \
+                '*:containers:__docker_stoppedcontainers'
+            ;;
+        (rmi)
+            _arguments '-v[Remove the volumes associated to the container]' \
+                '*:images:__docker_images'
+            ;;
+        (top)
+            _arguments '1:containers:__docker_runningcontainers'
+            ;;
+        (restart|stop)
+            _arguments '-t=-[Number of seconds to try to stop for before killing the container]:seconds to before killing:(1 5 10 30 60)' \
+                '*:containers:__docker_runningcontainers'
+            ;;
+        (top)
+            _arguments ':containers:__docker_runningcontainers'
+            ;;
+        (ps)
+            _arguments '-a[Show all containers. Only running containers are shown by default]' \
+                '-h[Show help]' \
+                '-beforeId=-[Show only container created before Id, include non-running one]:containers:__docker_containers' \
+            '-n=-[Show n last created containers, include non-running one]:n:(1 5 10 25 50)'
+            ;;
+        (tag)
+            _arguments \
+                '-f[force]'\
+                ':image:__docker_images'\
+                ':repository:__docker_repositories' \
+                ':tag:__docker_tags'
+            ;;
+        (run)
+            _arguments \
+                '-a=-[Attach to stdin, stdout or stderr]:toggle:(true false)' \
+                '-c=-[CPU shares (relative weight)]:CPU shares: ' \
+                '-d[Detached mode: leave the container running in the background]' \
+                '*-dns=[Set custom dns servers]:dns server: ' \
+                '*-e=[Set environment variables]:environment variable: ' \
+                '-entrypoint=-[Overwrite the default entrypoint of the image]:entry point: ' \
+                '-h=-[Container host name]:hostname:_hosts' \
+                '-i[Keep stdin open even if not attached]' \
+                '-m=-[Memory limit (in bytes)]:limit: ' \
+                '*-p=-[Expose a container''s port to the host]:port:_ports' \
+                '-t=-[Allocate a pseudo-tty]:toggle:(true false)' \
+                '-u=-[Username or UID]:user:_users' \
+                '*-v=-[Bind mount a volume (e.g. from the host: -v /host:/container, from docker: -v /container)]:volume: '\
+                '-volumes-from=-[Mount volumes from the specified container]:volume: ' \
+                '(-):images:__docker_images' \
+                '(-):command: _command_names -e' \
+                '*::arguments: _normal'
+                ;;
+        (pull|search)
+            _arguments ':name:__docker_search'
+            ;;
+        (help)
+            _arguments ':subcommand:__docker_commands'
+            ;;
+        (*)
+            _message 'Unknown sub command'
+    esac
+
+}
+
+_docker () {
+    local curcontext="$curcontext" state line
+    typeset -A opt_args
+
+    _arguments -C \
+      '-H=-[tcp://host:port to bind/connect to]:socket: ' \
+         '(-): :->command' \
+         '(-)*:: :->option-or-argument' 
+
+    if (( CURRENT == 1 )); then
+
+    fi
+    case $state in 
+        (command)
+            __docker_commands
+            ;;
+        (option-or-argument)
+            curcontext=${curcontext%:*:*}:docker-$words[1]:
+            __docker_subcommand 
+            ;;
+    esac
+}
+
+_docker "$@"
diff --git a/contrib/install.sh b/contrib/install.sh
deleted file mode 100755
index 40e3aaa..0000000
--- a/contrib/install.sh
+++ /dev/null
@@ -1,61 +0,0 @@
-#!/bin/sh
-# This script is meant for quick & easy install via 'curl URL-OF-SCRIPT | sh'
-# Original version by Jeff Lindsay <progrium@gmail.com>
-# Revamped by Jerome Petazzoni <jerome@dotcloud.com>
-#
-# This script canonical location is https://get.docker.io/; to update it, run:
-# s3cmd put -m text/x-shellscript -P install.sh s3://get.docker.io/index
-
-echo "Ensuring basic dependencies are installed..."
-apt-get -qq update
-apt-get -qq install lxc wget
-
-echo "Looking in /proc/filesystems to see if we have AUFS support..."
-if grep -q aufs /proc/filesystems
-then
-    echo "Found."
-else
-    echo "Ahem, it looks like the current kernel does not support AUFS."
-    echo "Let's see if we can load the AUFS module with modprobe..."
-    if modprobe aufs
-    then
-        echo "Module loaded."
-    else
-        echo "Ahem, things didn't turn out as expected."
-        KPKG=linux-image-extra-$(uname -r)
-        echo "Trying to install $KPKG..."
-        if apt-get -qq install $KPKG
-        then
-            echo "Installed."
-        else
-            echo "Oops, we couldn't install the -extra kernel."
-            echo "Are you sure you are running a supported version of Ubuntu?"
-            echo "Proceeding anyway, but Docker will probably NOT WORK!"
-        fi
-    fi
-fi
-
-echo "Downloading docker binary to /usr/local/bin..."
-curl -s https://get.docker.io/builds/$(uname -s)/$(uname -m)/docker-latest \
-    > /usr/local/bin/docker
-chmod +x /usr/local/bin/docker
-
-if [ -f /etc/init/dockerd.conf ]
-then
-  echo "Upstart script already exists."
-else
-  echo "Creating /etc/init/dockerd.conf..."
-  cat >/etc/init/dockerd.conf <<EOF
-description "Docker daemon"
-start on filesystem and started lxc-net
-stop on runlevel [!2345]
-respawn
-exec /usr/local/bin/docker -d
-EOF
-fi
-
-echo "Starting dockerd..."
-start dockerd > /dev/null
-
-echo "Done."
-echo
diff --git a/contrib/mkimage-arch.sh b/contrib/mkimage-arch.sh
new file mode 100755
index 0000000..cdc3c27
--- /dev/null
+++ b/contrib/mkimage-arch.sh
@@ -0,0 +1,65 @@
+#!/bin/bash
+# Generate a minimal filesystem for archlinux and load it into the local
+# docker as "archlinux"
+# requires root
+set -e
+
+PACSTRAP=$(which pacstrap)
+[ "$PACSTRAP" ] || {
+    echo "Could not find pacstrap. Run pacman -S arch-install-scripts"
+    exit 1
+}
+EXPECT=$(which expect)
+[ "$EXPECT" ] || {
+    echo "Could not find expect. Run pacman -S expect"
+    exit 1
+}
+
+ROOTFS=~/rootfs-arch-$$-$RANDOM
+mkdir $ROOTFS
+
+#packages to ignore for space savings
+PKGIGNORE=linux,jfsutils,lvm2,cryptsetup,groff,man-db,man-pages,mdadm,pciutils,pcmciautils,reiserfsprogs,s-nail,xfsprogs
+ 
+expect -c "
+  set timeout 60
+  spawn pacstrap -c -d -G -i $ROOTFS base haveged --ignore $PKGIGNORE
+  expect {
+    \"Install anyway\" { send "n\\r"; exp_continue }
+    \"(default=all)\" { send "\\r"; exp_continue }
+    \"Proceed with installation?\" { send "\\r"; exp_continue }
+    \"skip the above package\" {send "y\\r"; exp_continue }
+    \"checking\" { exp_continue }
+    \"loading\" { exp_continue }
+    \"installing\" { exp_continue }
+  }"
+
+arch-chroot $ROOTFS /bin/sh -c "haveged -w 1024; pacman-key --init; pkill haveged; pacman -Rs --noconfirm haveged; pacman-key --populate archlinux"
+arch-chroot $ROOTFS /bin/sh -c "ln -s /usr/share/zoneinfo/UTC /etc/localtime"
+cat > $ROOTFS/etc/locale.gen <<DELIM
+en_US.UTF-8 UTF-8
+en_US ISO-8859-1
+DELIM
+arch-chroot $ROOTFS locale-gen
+arch-chroot $ROOTFS /bin/sh -c 'echo "Server = http://mirrors.kernel.org/archlinux/\$repo/os/\$arch" > /etc/pacman.d/mirrorlist'
+
+# udev doesn't work in containers, rebuild /dev
+DEV=${ROOTFS}/dev
+mv ${DEV} ${DEV}.old
+mkdir -p ${DEV}
+mknod -m 666 ${DEV}/null c 1 3
+mknod -m 666 ${DEV}/zero c 1 5
+mknod -m 666 ${DEV}/random c 1 8
+mknod -m 666 ${DEV}/urandom c 1 9
+mkdir -m 755 ${DEV}/pts
+mkdir -m 1777 ${DEV}/shm
+mknod -m 666 ${DEV}/tty c 5 0
+mknod -m 600 ${DEV}/console c 5 1
+mknod -m 666 ${DEV}/tty0 c 4 0
+mknod -m 666 ${DEV}/full c 1 7
+mknod -m 600 ${DEV}/initctl p
+mknod -m 666 ${DEV}/ptmx c 5 2
+
+tar -C $ROOTFS -c . | docker import - archlinux
+docker run -i -t archlinux echo Success.
+rm -rf $ROOTFS
diff --git a/contrib/mkimage-centos.sh b/contrib/mkimage-centos.sh
new file mode 100755
index 0000000..a3c3253
--- /dev/null
+++ b/contrib/mkimage-centos.sh
@@ -0,0 +1,15 @@
+#!/bin/bash
+# Create a CentOS base image for Docker
+# From unclejack https://github.com/dotcloud/docker/issues/290
+set -e
+
+MIRROR_URL="http://centos.netnitco.net/6.4/os/x86_64/"
+MIRROR_URL_UPDATES="http://centos.netnitco.net/6.4/updates/x86_64/"
+
+yum install -y febootstrap xz
+
+febootstrap -i bash -i coreutils -i tar -i bzip2 -i gzip -i vim-minimal -i wget -i patch -i diffutils -i iproute -i yum centos centos64  $MIRROR_URL -u $MIRROR_URL_UPDATES
+touch centos64/etc/resolv.conf
+touch centos64/sbin/init
+
+tar --numeric-owner -Jcpf centos-64.tar.xz -C centos64 .
diff --git a/contrib/mkimage-debian.sh b/contrib/mkimage-debian.sh
index 89349e4..c1abd4f 100755
--- a/contrib/mkimage-debian.sh
+++ b/contrib/mkimage-debian.sh
@@ -10,12 +10,18 @@
 include='iproute,iputils-ping'
 
 repo="$1"
-suite="${2:-$stableSuite}"
+suite="$2"
 mirror="${3:-}" # stick to the default debootstrap mirror if one is not provided
 
-if [ ! "$repo" ]; then
-	echo >&2 "usage: $0 repo [suite [mirror]]"
+if [ ! "$repo" ] || [ ! "$suite" ]; then
+	echo >&2 "usage: $0 repo suite [mirror]"
+	echo >&2
 	echo >&2 "   ie: $0 tianon/debian squeeze"
+	echo >&2 "       $0 tianon/debian squeeze http://ftp.uk.debian.org/debian/"
+	echo >&2
+	echo >&2 "   ie: $0 tianon/ubuntu precise"
+	echo >&2 "       $0 tianon/ubuntu precise http://mirrors.melbourne.co.uk/ubuntu/"
+	echo >&2
 	exit 1
 fi
 
@@ -32,22 +38,44 @@
 
 cd "$target"
 
-# create the image
-img=$(sudo tar -c . | docker import -)
+# prevent init scripts from running during install/update
+#  policy-rc.d (for most scripts)
+echo $'#!/bin/sh\nexit 101' | sudo tee usr/sbin/policy-rc.d > /dev/null
+sudo chmod +x usr/sbin/policy-rc.d
+#  initctl (for some pesky upstart scripts)
+sudo chroot . dpkg-divert --local --rename --add /sbin/initctl
+sudo ln -sf /bin/true sbin/initctl
+# see https://github.com/dotcloud/docker/issues/446#issuecomment-16953173
 
-# tag suite
-docker tag $img $repo $suite
+# shrink the image, since apt makes us fat (wheezy: ~157.5MB vs ~120MB)
+sudo chroot . apt-get clean
+
+# while we're at it, apt is unnecessarily slow inside containers
+#  this forces dpkg not to call sync() after package extraction and speeds up install
+#    the benefit is huge on spinning disks, and the penalty is nonexistent on SSD or decent server virtualization
+echo 'force-unsafe-io' | sudo tee etc/dpkg/dpkg.cfg.d/02apt-speedup > /dev/null
+#  we want to effectively run "apt-get clean" after every install to keep images small
+echo 'DPkg::Post-Invoke {"/bin/rm -f /var/cache/apt/archives/*.deb || true";};' | sudo tee etc/apt/apt.conf.d/no-cache > /dev/null
+
+# helpful undo lines for each the above tweaks (for lack of a better home to keep track of them):
+#  rm /usr/sbin/policy-rc.d
+#  rm /sbin/initctl; dpkg-divert --rename --remove /sbin/initctl
+#  rm /etc/dpkg/dpkg.cfg.d/02apt-speedup
+#  rm /etc/apt/apt.conf.d/no-cache
+
+# create the image (and tag $repo:$suite)
+sudo tar -c . | docker import - $repo $suite
 
 # test the image
 docker run -i -t $repo:$suite echo success
 
 if [ "$suite" = "$stableSuite" -o "$suite" = 'stable' ]; then
 	# tag latest
-	docker tag $img $repo latest
+	docker tag $repo:$suite $repo latest
 	
 	# tag the specific debian release version
 	ver=$(docker run $repo:$suite cat /etc/debian_version)
-	docker tag $img $repo $ver
+	docker tag $repo:$suite $repo $ver
 fi
 
 # cleanup
diff --git a/contrib/vim-syntax/LICENSE b/contrib/vim-syntax/LICENSE
new file mode 100644
index 0000000..e67cdab
--- /dev/null
+++ b/contrib/vim-syntax/LICENSE
@@ -0,0 +1,22 @@
+Copyright (c) 2013 Honza Pokorny
+All rights reserved.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+
+1. Redistributions of source code must retain the above copyright
+   notice, this list of conditions and the following disclaimer.
+2. Redistributions in binary form must reproduce the above copyright
+   notice, this list of conditions and the following disclaimer in the
+   documentation and/or other materials provided with the distribution.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
+ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
diff --git a/contrib/vim-syntax/README.md b/contrib/vim-syntax/README.md
new file mode 100644
index 0000000..b782466
--- /dev/null
+++ b/contrib/vim-syntax/README.md
@@ -0,0 +1,23 @@
+dockerfile.vim
+==============
+
+Syntax highlighting for Dockerfiles
+
+Installation
+------------
+
+Via pathogen, the usual way...
+
+Features
+--------
+
+The syntax highlighting includes:
+
+* The directives (e.g. `FROM`)
+* Strings
+* Comments
+
+License
+-------
+
+BSD, short and sweet
diff --git a/contrib/vim-syntax/doc/dockerfile.txt b/contrib/vim-syntax/doc/dockerfile.txt
new file mode 100644
index 0000000..37cc7be
--- /dev/null
+++ b/contrib/vim-syntax/doc/dockerfile.txt
@@ -0,0 +1,18 @@
+*dockerfile.txt*  Syntax highlighting for Dockerfiles
+
+Author: Honza Pokorny <http://honza.ca>
+License: BSD
+
+INSTALLATION                                                     *installation*
+
+Drop it on your Pathogen path and you're all set.
+
+FEATURES                                                             *features*
+
+The syntax highlighting includes:
+
+* The directives (e.g. FROM)
+* Strings
+* Comments
+
+ vim:tw=78:et:ft=help:norl:
diff --git a/contrib/vim-syntax/ftdetect/dockerfile.vim b/contrib/vim-syntax/ftdetect/dockerfile.vim
new file mode 100644
index 0000000..83281d3
--- /dev/null
+++ b/contrib/vim-syntax/ftdetect/dockerfile.vim
@@ -0,0 +1 @@
+au BufNewFile,BufRead Dockerfile set filetype=dockerfile
diff --git a/contrib/vim-syntax/syntax/dockerfile.vim b/contrib/vim-syntax/syntax/dockerfile.vim
new file mode 100644
index 0000000..90e0651
--- /dev/null
+++ b/contrib/vim-syntax/syntax/dockerfile.vim
@@ -0,0 +1,22 @@
+" dockerfile.vim - Syntax highlighting for Dockerfiles
+" Maintainer:   Honza Pokorny <http://honza.ca>
+" Version:      0.5
+
+
+if exists("b:current_syntax")
+    finish
+endif
+
+let b:current_syntax = "dockerfile"
+
+syntax case ignore
+
+syntax match dockerfileKeyword /\v^\s*(FROM|MAINTAINER|RUN|CMD|EXPOSE|ENV|ADD)\s/
+syntax match dockerfileKeyword /\v^\s*(ENTRYPOINT|VOLUME|USER|WORKDIR)\s/
+highlight link dockerfileKeyword Keyword
+
+syntax region dockerfileString start=/\v"/ skip=/\v\\./ end=/\v"/
+highlight link dockerfileString String
+
+syntax match dockerfileComment "\v^\s*#.*$"
+highlight link dockerfileComment Comment
diff --git a/docker/docker.go b/docker/docker.go
index a0021f3..750d63c 100644
--- a/docker/docker.go
+++ b/docker/docker.go
@@ -29,7 +29,7 @@
 	flVersion := flag.Bool("v", false, "Print version information and quit")
 	flDaemon := flag.Bool("d", false, "Daemon mode")
 	flDebug := flag.Bool("D", false, "Debug mode")
-	flAutoRestart := flag.Bool("r", false, "Restart previously running containers")
+	flAutoRestart := flag.Bool("r", true, "Restart previously running containers")
 	bridgeName := flag.String("b", "", "Attach containers to a pre-existing network bridge. Use 'none' to disable container networking")
 	pidfile := flag.String("p", "/var/run/docker.pid", "File containing process PID")
 	flGraphPath := flag.String("g", "/var/lib/docker", "Path to graph storage base dir.")
diff --git a/docs/README.md b/docs/README.md
index d53b867..02572ee 100644
--- a/docs/README.md
+++ b/docs/README.md
@@ -1,38 +1,93 @@
 Docker Documentation
 ====================
 
-Documentation
--------------
-This is your definite place to contribute to the docker documentation. After each push to master the documentation
-is automatically generated and made available on [docs.docker.io](http://docs.docker.io)
+Overview
+--------
 
-Each of the .rst files under sources reflects a page on the documentation. 
+The source for Docker documentation is here under ``sources/`` in the
+form of .rst files. These files use
+[reStructuredText](http://docutils.sourceforge.net/rst.html)
+formatting with [Sphinx](http://sphinx-doc.org/) extensions for
+structure, cross-linking and indexing.
 
-Installation
-------------
+The HTML files are built and hosted on
+[readthedocs.org](https://readthedocs.org/projects/docker/), appearing
+via proxy on https://docs.docker.io. The HTML files update
+automatically after each change to the master or release branch of the
+[docker files on GitHub](https://github.com/dotcloud/docker) thanks to
+post-commit hooks. The "release" branch maps to the "latest"
+documentation and the "master" branch maps to the "master"
+documentation. 
 
-* Work in your own fork of the code, we accept pull requests.
+**Warning**: The "master" documentation may include features not yet
+part of any official docker release. "Master" docs should be used only
+for understanding bleeding-edge development and "latest" should be
+used for the latest official release.
+
+If you need to manually trigger a build of an existing branch, then
+you can do that through the [readthedocs
+interface](https://readthedocs.org/builds/docker/). If you would like
+to add new build targets, including new branches or tags, then you
+must contact one of the existing maintainers and get your
+readthedocs.org account added to the maintainers list, or just file an
+issue on GitHub describing the branch/tag and why it needs to be added
+to the docs, and one of the maintainers will add it for you.
+
+Getting Started
+---------------
+
+To edit and test the docs, you'll need to install the Sphinx tool and
+its dependencies. There are two main ways to install this tool:
+
+Native Installation
+...................
+
 * Install sphinx: `pip install sphinx`
-    * Mac OS X: `[sudo] pip-2.7 install sphinx`)
+    * Mac OS X: `[sudo] pip-2.7 install sphinx`
 * Install sphinx httpdomain contrib package: `pip install sphinxcontrib-httpdomain`
     * Mac OS X: `[sudo] pip-2.7 install sphinxcontrib-httpdomain`
 * If pip is not available you can probably install it using your favorite package manager as **python-pip**
 
+Alternative Installation: Docker Container
+..........................................
+
+If you're running ``docker`` on your development machine then you may
+find it easier and cleaner to use the Dockerfile. This installs Sphinx
+in a container, adds the local ``docs/`` directory and builds the HTML
+docs inside the container, even starting a simple HTTP server on port
+8000 so that you can connect and see your changes. Just run ``docker
+build .`` and run the resulting image. This is the equivalent to
+``make clean server`` since each container starts clean.
+
 Usage
 -----
-* Change the `.rst` files with your favorite editor to your liking.
-* Run `make docs` to clean up old files and generate new ones.
-* Your static website can now be found in the `_build` directory.
-* To preview what you have generated run `make server` and open http://localhost:8000/ in your favorite browser.
+* Follow the contribution guidelines (``../CONTRIBUTING.md``)
+* Work in your own fork of the code, we accept pull requests.
+* Change the ``.rst`` files with your favorite editor -- try to keep the
+  lines short and respect RST and Sphinx conventions. 
+* Run ``make clean docs`` to clean up old files and generate new ones,
+  or just ``make docs`` to update after small changes.
+* Your static website can now be found in the ``_build`` directory.
+* To preview what you have generated run ``make server`` and open
+  http://localhost:8000/ in your favorite browser.
+
+``make clean docs`` must complete without any warnings or errors.
 
 Working using GitHub's file editor
 ----------------------------------
-Alternatively, for small changes and typo's you might want to use GitHub's built in file editor. It allows
-you to preview your changes right online. Just be careful not to create many commits.
+
+Alternatively, for small changes and typos you might want to use
+GitHub's built in file editor. It allows you to preview your changes
+right online (though there can be some differences between GitHub
+markdown and Sphinx RST). Just be careful not to create many commits.
 
 Images
 ------
-When you need to add images, try to make them as small as possible (e.g. as gif).
+
+When you need to add images, try to make them as small as possible
+(e.g. as gif). Usually images should go in the same directory as the
+.rst file which references them, or in a subdirectory if one already
+exists.
 
 Notes
 -----
@@ -41,7 +96,7 @@
 
 Guides on using sphinx
 ----------------------
-* To make links to certain pages create a link target like so:
+* To make links to certain sections create a link target like so:
 
   ```
     .. _hello_world:
@@ -52,7 +107,10 @@
     This is.. (etc.)
   ```
 
-  The ``_hello_world:`` will make it possible to link to this position (page and marker) from all other pages.
+  The ``_hello_world:`` will make it possible to link to this position
+  (page and section heading) from all other pages. See the [Sphinx
+  docs](http://sphinx-doc.org/markup/inline.html#role-ref) for more
+  information and examples.
 
 * Notes, warnings and alarms
 
@@ -68,13 +126,17 @@
 
 * Code examples
 
-  Start without $, so it's easy to copy and paste.
+  * Start without $, so it's easy to copy and paste.
+  * Use "sudo" with docker to ensure that your command is runnable
+    even if they haven't [used the *docker*
+    group](http://docs.docker.io/en/latest/use/basics/#why-sudo).
 
 Manpages
 --------
 
-* To make the manpages, simply run 'make man'. Please note there is a bug in spinx 1.1.3 which makes this fail.
-Upgrade to the latest version of sphinx.
-* Then preview the manpage by running `man _build/man/docker.1`, where _build/man/docker.1 is the path to the generated
-manfile
-* The manpages are also autogenerated by our hosted readthedocs here: http://docs-docker.dotcloud.com/projects/docker/downloads/
+* To make the manpages, run ``make man``. Please note there is a bug
+  in spinx 1.1.3 which makes this fail.  Upgrade to the latest version
+  of Sphinx.
+* Then preview the manpage by running ``man _build/man/docker.1``,
+  where ``_build/man/docker.1`` is the path to the generated manfile
+
diff --git a/docs/sources/api/docker_remote_api.rst b/docs/sources/api/docker_remote_api.rst
index 2dd7731..86cacd1 100644
--- a/docs/sources/api/docker_remote_api.rst
+++ b/docs/sources/api/docker_remote_api.rst
@@ -9,7 +9,6 @@
 Docker Remote API
 =================
 
-.. contents:: Table of Contents
 
 1. Brief introduction
 =====================
@@ -27,16 +26,41 @@
 2. Versions
 ===========
 
-The current version of the API is 1.5
+The current version of the API is 1.6
 
 Calling /images/<name>/insert is the same as calling
-/v1.5/images/<name>/insert 
+/v1.6/images/<name>/insert
 
 You can still call an old version of the api using
 /v1.0/images/<name>/insert
 
+v1.6
+****
+
+Full Documentation
+------------------
+
+:doc:`docker_remote_api_v1.6`
+
+What's new
+----------
+
+.. http:post:: /containers/(id)/attach
+
+   **New!** You can now split stderr from stdout. This is done by prefixing
+   a header to each transmition. See :http:post:`/containers/(id)/attach`.
+   The WebSocket attach is unchanged.
+   Note that attach calls on the previous API version didn't change. Stdout and
+   stderr are merged.
+
+
+v1.5
+****
+
+Full Documentation
+------------------
+
 :doc:`docker_remote_api_v1.5`
-*****************************
 
 What's new
 ----------
@@ -57,8 +81,13 @@
    dicts each containing `PublicPort`, `PrivatePort` and `Type` describing a
    port mapping.
 
+v1.4
+****
+
+Full Documentation
+------------------
+
 :doc:`docker_remote_api_v1.4`
-*****************************
 
 What's new
 ----------
@@ -75,11 +104,16 @@
 
    **New!** Image's name added in the events
 
-:doc:`docker_remote_api_v1.3`
-*****************************
+v1.3
+****
 
 docker v0.5.0 51f6c4a_
 
+Full Documentation
+------------------
+
+:doc:`docker_remote_api_v1.3`
+
 What's new
 ----------
 
@@ -112,11 +146,16 @@
 - You can now pass host-specific configuration (e.g. bind mounts) in
   the POST body for start calls
 
-:doc:`docker_remote_api_v1.2`
-*****************************
+v1.2
+****
 
 docker v0.4.2 2e7649b_
 
+Full Documentation
+------------------
+
+:doc:`docker_remote_api_v1.2`
+
 What's new
 ----------
 
@@ -142,11 +181,16 @@
   deleted/untagged.
 
 
-:doc:`docker_remote_api_v1.1`
-*****************************
+v1.1
+****
 
 docker v0.4.0 a8ae398_
 
+Full Documentation
+------------------
+
+:doc:`docker_remote_api_v1.1`
+
 What's new
 ----------
 
@@ -166,12 +210,16 @@
 	   {"error":"Invalid..."}
 	   ...
 
-
-:doc:`docker_remote_api_v1.0`
-*****************************
+v1.0
+****
 
 docker v0.3.4 8d73740_
 
+Full Documentation
+------------------
+
+:doc:`docker_remote_api_v1.0`
+
 What's new
 ----------
 
@@ -182,36 +230,3 @@
 .. _8d73740: https://github.com/dotcloud/docker/commit/8d73740343778651c09160cde9661f5f387b36f4
 .. _2e7649b: https://github.com/dotcloud/docker/commit/2e7649beda7c820793bd46766cbc2cfeace7b168
 .. _51f6c4a: https://github.com/dotcloud/docker/commit/51f6c4a7372450d164c61e0054daf0223ddbd909
-
-==================================
-Docker Remote API Client Libraries
-==================================
-
-These libraries have not been tested by the Docker Maintainers for
-compatibility. Please file issues with the library owners.  If you
-find more library implementations, please list them in Docker doc bugs
-and we will add the libraries here.
-
-+----------------------+----------------+--------------------------------------------+
-| Language/Framework   | Name           | Repository                                 |
-+======================+================+============================================+
-| Python               | docker-py      | https://github.com/dotcloud/docker-py      |
-+----------------------+----------------+--------------------------------------------+
-| Ruby                 | docker-client  | https://github.com/geku/docker-client      |
-+----------------------+----------------+--------------------------------------------+
-| Ruby                 | docker-api     | https://github.com/swipely/docker-api      |
-+----------------------+----------------+--------------------------------------------+
-| Javascript (NodeJS)  | docker.io      | https://github.com/appersonlabs/docker.io  |
-|                      |                | Install via NPM: `npm install docker.io`   |
-+----------------------+----------------+--------------------------------------------+
-| Javascript           | docker-js      | https://github.com/dgoujard/docker-js      |
-+----------------------+----------------+--------------------------------------------+
-| Javascript (Angular) | dockerui       | https://github.com/crosbymichael/dockerui  |
-| **WebUI**            |                |                                            |
-+----------------------+----------------+--------------------------------------------+
-| Java                 | docker-java    | https://github.com/kpelykh/docker-java     |
-+----------------------+----------------+--------------------------------------------+
-| Erlang               | erldocker      | https://github.com/proger/erldocker        |
-+----------------------+----------------+--------------------------------------------+
-| Go                   | go-dockerclient| https://github.com/fsouza/go-dockerclient  |
-+----------------------+----------------+--------------------------------------------+
diff --git a/docs/sources/api/docker_remote_api_v1.5.rst b/docs/sources/api/docker_remote_api_v1.5.rst
index 2581059..9c8fa8c 100644
--- a/docs/sources/api/docker_remote_api_v1.5.rst
+++ b/docs/sources/api/docker_remote_api_v1.5.rst
@@ -28,543 +28,525 @@
 
 .. http:get:: /containers/json
 
-	List containers
+  List containers
 
-	**Example request**:
+  **Example request**:
 
-	.. sourcecode:: http
+  .. sourcecode:: http
 
-	   GET /containers/json?all=1&before=8dfafdbc3a40&size=1 HTTP/1.1
-	   
-	**Example response**:
+    GET /containers/json?all=1&before=8dfafdbc3a40&size=1 HTTP/1.1
 
-	.. sourcecode:: http
+  **Example response**:
 
-	   HTTP/1.1 200 OK
-	   Content-Type: application/json
-	   
-	   [
-		{
-			"Id": "8dfafdbc3a40",
-			"Image": "ubuntu:latest",
-			"Command": "echo 1",
-			"Created": 1367854155,
-			"Status": "Exit 0",
-			"Ports":[{"PrivatePort": 2222, "PublicPort": 3333, "Type": "tcp"}],
-			"SizeRw":12288,
-			"SizeRootFs":0
-		},
-		{
-			"Id": "9cd87474be90",
-			"Image": "ubuntu:latest",
-			"Command": "echo 222222",
-			"Created": 1367854155,
-			"Status": "Exit 0",
-			"Ports":[],
-			"SizeRw":12288,
-			"SizeRootFs":0
-		},
-		{
-			"Id": "3176a2479c92",
-			"Image": "centos:latest",
-			"Command": "echo 3333333333333333",
-			"Created": 1367854154,
-			"Status": "Exit 0",
-			"Ports":[],
-			"SizeRw":12288,
-			"SizeRootFs":0
-		},
-		{
-			"Id": "4cb07b47f9fb",
-			"Image": "fedora:latest",
-			"Command": "echo 444444444444444444444444444444444",
-			"Created": 1367854152,
-			"Status": "Exit 0",
-			"Ports":[],
-			"SizeRw":12288,
-			"SizeRootFs":0
-		}
-	   ]
- 
-	:query all: 1/True/true or 0/False/false, Show all containers. Only running containers are shown by default
-	:query limit: Show ``limit`` last created containers, include non-running ones.
-	:query since: Show only containers created since Id, include non-running ones.
-	:query before: Show only containers created before Id, include non-running ones.
-	:query size: 1/True/true or 0/False/false, Show the containers sizes
-	:statuscode 200: no error
-	:statuscode 400: bad parameter
-	:statuscode 500: server error
+  .. sourcecode:: http
 
+    HTTP/1.1 200 OK
+    Content-Type: application/json
+
+    [
+      {
+        "Id": "8dfafdbc3a40",
+        "Image": "ubuntu:latest",
+        "Command": "echo 1",
+        "Created": 1367854155,
+        "Status": "Exit 0",
+        "Ports":[{"PrivatePort": 2222, "PublicPort": 3333, "Type": "tcp"}],
+        "SizeRw":12288,
+        "SizeRootFs":0
+      },
+      {
+        "Id": "9cd87474be90",
+        "Image": "ubuntu:latest",
+        "Command": "echo 222222",
+        "Created": 1367854155,
+        "Status": "Exit 0",
+        "Ports":[],
+        "SizeRw":12288,
+        "SizeRootFs":0
+      },
+      {
+        "Id": "3176a2479c92",
+        "Image": "centos:latest",
+        "Command": "echo 3333333333333333",
+        "Created": 1367854154,
+        "Status": "Exit 0",
+        "Ports":[],
+        "SizeRw":12288,
+        "SizeRootFs":0
+      },
+      {
+        "Id": "4cb07b47f9fb",
+        "Image": "fedora:latest",
+        "Command": "echo 444444444444444444444444444444444",
+        "Created": 1367854152,
+        "Status": "Exit 0",
+        "Ports":[],
+        "SizeRw":12288,
+        "SizeRootFs":0
+      }
+    ]
+
+  :query all: 1/True/true or 0/False/false, Show all containers. Only running containers are shown by default
+  :query limit: Show ``limit`` last created containers, include non-running ones.
+  :query since: Show only containers created since Id, include non-running ones.
+  :query before: Show only containers created before Id, include non-running ones.
+  :query size: 1/True/true or 0/False/false, Show the containers sizes
+  :statuscode 200: no error
+  :statuscode 400: bad parameter
+  :statuscode 500: server error
 
 Create a container
 ******************
 
 .. http:post:: /containers/create
 
-	Create a container
+  Create a container
 
-	**Example request**:
+  **Example request**:
 
-	.. sourcecode:: http
+  .. sourcecode:: http
 
-	   POST /containers/create HTTP/1.1
-	   Content-Type: application/json
+    POST /containers/create HTTP/1.1
+    Content-Type: application/json
 
-	   {
-		"Hostname":"",
-		"User":"",
-		"Memory":0,
-		"MemorySwap":0,
-		"AttachStdin":false,
-		"AttachStdout":true,
-		"AttachStderr":true,
-		"PortSpecs":null,
-		"Privileged": false,
-		"Tty":false,
-		"OpenStdin":false,
-		"StdinOnce":false,
-		"Env":null,
-		"Cmd":[
-			"date"
-		],
-		"Dns":null,
-		"Image":"ubuntu",
-		"Volumes":{},
-		"VolumesFrom":"",
-		"WorkingDir":""
+    {
+      "Hostname":"",
+      "User":"",
+      "Memory":0,
+      "MemorySwap":0,
+      "AttachStdin":false,
+      "AttachStdout":true,
+      "AttachStderr":true,
+      "PortSpecs":null,
+      "Privileged": false,
+      "Tty":false,
+      "OpenStdin":false,
+      "StdinOnce":false,
+      "Env":null,
+      "Cmd":[
+        "date"
+      ],
+      "Dns":null,
+      "Image":"ubuntu",
+      "Volumes":{},
+      "VolumesFrom":"",
+      "WorkingDir":""
+    }
 
-	   }
-	   
-	**Example response**:
+  **Example response**:
 
-	.. sourcecode:: http
+  .. sourcecode:: http
 
-	   HTTP/1.1 201 OK
-	   Content-Type: application/json
+    HTTP/1.1 201 OK
+    Content-Type: application/json
 
-	   {
-		"Id":"e90e34656806"
-		"Warnings":[]
-	   }
-	
-	:jsonparam config: the container's configuration
-	:statuscode 201: no error
-	:statuscode 404: no such container
-	:statuscode 406: impossible to attach (container not running)
-	:statuscode 500: server error
+    {
+      "Id":"e90e34656806"
+      "Warnings":[]
+    }
 
+  :jsonparam config: the container's configuration
+  :statuscode 201: no error
+  :statuscode 404: no such container
+  :statuscode 406: impossible to attach (container not running)
+  :statuscode 500: server error
 
 Inspect a container
 *******************
 
 .. http:get:: /containers/(id)/json
 
-	Return low-level information on the container ``id``
+  Return low-level information on the container ``id``
 
-	**Example request**:
+  **Example request**:
 
-	.. sourcecode:: http
+  .. sourcecode:: http
 
-	   GET /containers/4fa6e0f0c678/json HTTP/1.1
-	   
-	**Example response**:
+    GET /containers/4fa6e0f0c678/json HTTP/1.1
 
-	.. sourcecode:: http
+  **Example response**:
 
-	   HTTP/1.1 200 OK
-	   Content-Type: application/json
+  .. sourcecode:: http
 
-	   {
-			"Id": "4fa6e0f0c6786287e131c3852c58a2e01cc697a68231826813597e4994f1d6e2",
-			"Created": "2013-05-07T14:51:42.041847+02:00",
-			"Path": "date",
-			"Args": [],
-			"Config": {
-				"Hostname": "4fa6e0f0c678",
-				"User": "",
-				"Memory": 0,
-				"MemorySwap": 0,
-				"AttachStdin": false,
-				"AttachStdout": true,
-				"AttachStderr": true,
-				"PortSpecs": null,
-				"Tty": false,
-				"OpenStdin": false,
-				"StdinOnce": false,
-				"Env": null,
-				"Cmd": [
-					"date"
-				],
-				"Dns": null,
-				"Image": "ubuntu",
-				"Volumes": {},
-				"VolumesFrom": "",
-				"WorkingDir":""
+    HTTP/1.1 200 OK
+    Content-Type: application/json
 
-			},
-			"State": {
-				"Running": false,
-				"Pid": 0,
-				"ExitCode": 0,
-				"StartedAt": "2013-05-07T14:51:42.087658+02:01360",
-				"Ghost": false
-			},
-			"Image": "b750fe79269d2ec9a3c593ef05b4332b1d1a02a62b4accb2c21d589ff2f5f2dc",
-			"NetworkSettings": {
-				"IpAddress": "",
-				"IpPrefixLen": 0,
-				"Gateway": "",
-				"Bridge": "",
-				"PortMapping": null
-			},
-			"SysInitPath": "/home/kitty/go/src/github.com/dotcloud/docker/bin/docker",
-			"ResolvConfPath": "/etc/resolv.conf",
-			"Volumes": {}
-	   }
+    {
+      "Id": "4fa6e0f0c6786287e131c3852c58a2e01cc697a68231826813597e4994f1d6e2",
+      "Created": "2013-05-07T14:51:42.041847+02:00",
+      "Path": "date",
+      "Args": [],
+      "Config": {
+        "Hostname": "4fa6e0f0c678",
+        "User": "",
+        "Memory": 0,
+        "MemorySwap": 0,
+        "AttachStdin": false,
+        "AttachStdout": true,
+        "AttachStderr": true,
+        "PortSpecs": null,
+        "Tty": false,
+        "OpenStdin": false,
+        "StdinOnce": false,
+        "Env": null,
+        "Cmd": [
+          "date"
+        ],
+        "Dns": null,
+        "Image": "ubuntu",
+        "Volumes": {},
+        "VolumesFrom": "",
+        "WorkingDir":""
+      },
+      "State": {
+        "Running": false,
+        "Pid": 0,
+        "ExitCode": 0,
+        "StartedAt": "2013-05-07T14:51:42.087658+02:01360",
+        "Ghost": false
+      },
+      "Image": "b750fe79269d2ec9a3c593ef05b4332b1d1a02a62b4accb2c21d589ff2f5f2dc",
+      "NetworkSettings": {
+        "IpAddress": "",
+        "IpPrefixLen": 0,
+        "Gateway": "",
+        "Bridge": "",
+        "PortMapping": null
+      },
+      "SysInitPath": "/home/kitty/go/src/github.com/dotcloud/docker/bin/docker",
+      "ResolvConfPath": "/etc/resolv.conf",
+      "Volumes": {}
+    }
 
-	:statuscode 200: no error
-	:statuscode 404: no such container
-	:statuscode 500: server error
-
+  :statuscode 200: no error
+  :statuscode 404: no such container
+  :statuscode 500: server error
 
 List processes running inside a container
 *****************************************
 
 .. http:get:: /containers/(id)/top
 
-	List processes running inside the container ``id``
+  List processes running inside the container ``id``
 
-	**Example request**:
+  **Example request**:
 
-	.. sourcecode:: http
+  .. sourcecode:: http
 
-	   GET /containers/4fa6e0f0c678/top HTTP/1.1
+    GET /containers/4fa6e0f0c678/top HTTP/1.1
 
-	**Example response**:
+  **Example response**:
 
-	.. sourcecode:: http
+  .. sourcecode:: http
 
-	   HTTP/1.1 200 OK
-	   Content-Type: application/json
+    HTTP/1.1 200 OK
+    Content-Type: application/json
 
-	   {
-		"Titles":[
-			"USER",
-			"PID",
-			"%CPU",
-			"%MEM",
-			"VSZ",
-			"RSS",
-			"TTY",
-			"STAT",
-			"START",
-			"TIME",
-			"COMMAND"
-			],
-		"Processes":[
-			["root","20147","0.0","0.1","18060","1864","pts/4","S","10:06","0:00","bash"],
-			["root","20271","0.0","0.0","4312","352","pts/4","S+","10:07","0:00","sleep","10"]
-		]
-	   }
+    {
+      "Titles":[
+        "USER",
+        "PID",
+        "%CPU",
+        "%MEM",
+        "VSZ",
+        "RSS",
+        "TTY",
+        "STAT",
+        "START",
+        "TIME",
+        "COMMAND"
+      ],
+      "Processes":[
+        ["root","20147","0.0","0.1","18060","1864","pts/4","S","10:06","0:00","bash"],
+        ["root","20271","0.0","0.0","4312","352","pts/4","S+","10:07","0:00","sleep","10"]
+      ]
+    }
 
-	:query ps_args: ps arguments to use (eg. aux)
-	:statuscode 200: no error
-	:statuscode 404: no such container
-	:statuscode 500: server error
-
+  :query ps_args: ps arguments to use (eg. aux)
+  :statuscode 200: no error
+  :statuscode 404: no such container
+  :statuscode 500: server error
 
 Inspect changes on a container's filesystem
 *******************************************
 
 .. http:get:: /containers/(id)/changes
 
-	Inspect changes on container ``id`` 's filesystem
+  Inspect changes on container ``id`` 's filesystem
 
-	**Example request**:
+  **Example request**:
 
-	.. sourcecode:: http
+  .. sourcecode:: http
 
-	   GET /containers/4fa6e0f0c678/changes HTTP/1.1
+    GET /containers/4fa6e0f0c678/changes HTTP/1.1
 
-	   
-	**Example response**:
+  **Example response**:
 
-	.. sourcecode:: http
+  .. sourcecode:: http
 
-	   HTTP/1.1 200 OK
-	   Content-Type: application/json
-	   
-	   [
-		{
-			"Path":"/dev",
-			"Kind":0
-		},
-		{
-			"Path":"/dev/kmsg",
-			"Kind":1
-		},
-		{
-			"Path":"/test",
-			"Kind":1
-		}
-	   ]
+    HTTP/1.1 200 OK
+    Content-Type: application/json
 
-	:statuscode 200: no error
-	:statuscode 404: no such container
-	:statuscode 500: server error
+    [
+      {
+        "Path":"/dev",
+        "Kind":0
+      },
+      {
+        "Path":"/dev/kmsg",
+        "Kind":1
+      },
+      {
+        "Path":"/test",
+        "Kind":1
+      }
+    ]
 
+  :statuscode 200: no error
+  :statuscode 404: no such container
+  :statuscode 500: server error
 
 Export a container
 ******************
 
 .. http:get:: /containers/(id)/export
 
-	Export the contents of container ``id``
+  Export the contents of container ``id``
 
-	**Example request**:
+  **Example request**:
 
-	.. sourcecode:: http
+  .. sourcecode:: http
 
-	   GET /containers/4fa6e0f0c678/export HTTP/1.1
+    GET /containers/4fa6e0f0c678/export HTTP/1.1
 
-	   
-	**Example response**:
+  **Example response**:
 
-	.. sourcecode:: http
+  .. sourcecode:: http
 
-	   HTTP/1.1 200 OK
-	   Content-Type: application/octet-stream
-	   
-	   {{ STREAM }}
+    HTTP/1.1 200 OK
+    Content-Type: application/octet-stream
 
-	:statuscode 200: no error
-	:statuscode 404: no such container
-	:statuscode 500: server error
+    {{ STREAM }}
 
+  :statuscode 200: no error
+  :statuscode 404: no such container
+  :statuscode 500: server error
 
 Start a container
 *****************
 
 .. http:post:: /containers/(id)/start
 
-        Start the container ``id``
+  Start the container ``id``
 
-        **Example request**:
+  **Example request**:
 
-        .. sourcecode:: http
+  .. sourcecode:: http
 
-           POST /containers/(id)/start HTTP/1.1
-           Content-Type: application/json
+    POST /containers/(id)/start HTTP/1.1
+    Content-Type: application/json
 
-           {
-                "Binds":["/tmp:/tmp"],
-                "LxcConf":[{"Key":"lxc.utsname","Value":"docker"}]
-           }
+    {
+      "Binds":["/tmp:/tmp"],
+      "LxcConf":[{"Key":"lxc.utsname","Value":"docker"}]
+    }
 
-        **Example response**:
+  **Example response**:
 
-        .. sourcecode:: http
+  .. sourcecode:: http
 
-           HTTP/1.1 204 No Content
-           Content-Type: text/plain
+    HTTP/1.1 204 No Content
+    Content-Type: text/plain
 
-        :jsonparam hostConfig: the container's host configuration (optional)
-        :statuscode 204: no error
-        :statuscode 404: no such container
-        :statuscode 500: server error
-
+  :jsonparam hostConfig: the container's host configuration (optional)
+  :statuscode 204: no error
+  :statuscode 404: no such container
+  :statuscode 500: server error
 
 Stop a container
 ****************
 
 .. http:post:: /containers/(id)/stop
 
-	Stop the container ``id``
+  Stop the container ``id``
 
-	**Example request**:
+  **Example request**:
 
-	.. sourcecode:: http
+  .. sourcecode:: http
 
-	   POST /containers/e90e34656806/stop?t=5 HTTP/1.1
-	   
-	**Example response**:
+    POST /containers/e90e34656806/stop?t=5 HTTP/1.1
 
-	.. sourcecode:: http
+  **Example response**:
 
-	   HTTP/1.1 204 OK
-	   	
-	:query t: number of seconds to wait before killing the container
-	:statuscode 204: no error
-	:statuscode 404: no such container
-	:statuscode 500: server error
+  .. sourcecode:: http
 
+    HTTP/1.1 204 OK
+
+  :query t: number of seconds to wait before killing the container
+  :statuscode 204: no error
+  :statuscode 404: no such container
+  :statuscode 500: server error
 
 Restart a container
 *******************
 
 .. http:post:: /containers/(id)/restart
 
-	Restart the container ``id``
+  Restart the container ``id``
 
-	**Example request**:
+  **Example request**:
 
-	.. sourcecode:: http
+  .. sourcecode:: http
 
-	   POST /containers/e90e34656806/restart?t=5 HTTP/1.1
-	   
-	**Example response**:
+    POST /containers/e90e34656806/restart?t=5 HTTP/1.1
 
-	.. sourcecode:: http
+  **Example response**:
 
-	   HTTP/1.1 204 OK
-	   	
-	:query t: number of seconds to wait before killing the container
-	:statuscode 204: no error
-	:statuscode 404: no such container
-	:statuscode 500: server error
+  .. sourcecode:: http
 
+    HTTP/1.1 204 OK
+
+  :query t: number of seconds to wait before killing the container
+  :statuscode 204: no error
+  :statuscode 404: no such container
+  :statuscode 500: server error
 
 Kill a container
 ****************
 
 .. http:post:: /containers/(id)/kill
 
-	Kill the container ``id``
+  Kill the container ``id``
 
-	**Example request**:
+  **Example request**:
 
-	.. sourcecode:: http
+  .. sourcecode:: http
 
-	   POST /containers/e90e34656806/kill HTTP/1.1
-	   
-	**Example response**:
+    POST /containers/e90e34656806/kill HTTP/1.1
 
-	.. sourcecode:: http
+  **Example response**:
 
-	   HTTP/1.1 204 OK
-	   	
-	:statuscode 204: no error
-	:statuscode 404: no such container
-	:statuscode 500: server error
+  .. sourcecode:: http
 
+    HTTP/1.1 204 OK
+
+  :statuscode 204: no error
+  :statuscode 404: no such container
+  :statuscode 500: server error
 
 Attach to a container
 *********************
 
 .. http:post:: /containers/(id)/attach
 
-	Attach to the container ``id``
+  Attach to the container ``id``
 
-	**Example request**:
+  **Example request**:
 
-	.. sourcecode:: http
+  .. sourcecode:: http
 
-	   POST /containers/16253994b7c4/attach?logs=1&stream=0&stdout=1 HTTP/1.1
-	   
-	**Example response**:
+    POST /containers/16253994b7c4/attach?logs=1&stream=0&stdout=1 HTTP/1.1
 
-	.. sourcecode:: http
+  **Example response**:
 
-	   HTTP/1.1 200 OK
-	   Content-Type: application/vnd.docker.raw-stream
+  .. sourcecode:: http
 
-	   {{ STREAM }}
-	   	
-	:query logs: 1/True/true or 0/False/false, return logs. Default false
-	:query stream: 1/True/true or 0/False/false, return stream. Default false
-	:query stdin: 1/True/true or 0/False/false, if stream=true, attach to stdin. Default false
-	:query stdout: 1/True/true or 0/False/false, if logs=true, return stdout log, if stream=true, attach to stdout. Default false
-	:query stderr: 1/True/true or 0/False/false, if logs=true, return stderr log, if stream=true, attach to stderr. Default false
-	:statuscode 200: no error
-	:statuscode 400: bad parameter
-	:statuscode 404: no such container
-	:statuscode 500: server error
+    HTTP/1.1 200 OK
+    Content-Type: application/vnd.docker.raw-stream
 
+    {{ STREAM }}
+
+  :query logs: 1/True/true or 0/False/false, return logs. Default false
+  :query stream: 1/True/true or 0/False/false, return stream. Default false
+  :query stdin: 1/True/true or 0/False/false, if stream=true, attach to stdin. Default false
+  :query stdout: 1/True/true or 0/False/false, if logs=true, return stdout log, if stream=true, attach to stdout. Default false
+  :query stderr: 1/True/true or 0/False/false, if logs=true, return stderr log, if stream=true, attach to stderr. Default false
+  :statuscode 200: no error
+  :statuscode 400: bad parameter
+  :statuscode 404: no such container
+  :statuscode 500: server error
 
 Wait a container
 ****************
 
 .. http:post:: /containers/(id)/wait
 
-	Block until container ``id`` stops, then returns the exit code
+  Block until container ``id`` stops, then returns the exit code
 
-	**Example request**:
+  **Example request**:
 
-	.. sourcecode:: http
+  .. sourcecode:: http
 
-	   POST /containers/16253994b7c4/wait HTTP/1.1
-	   
-	**Example response**:
+    POST /containers/16253994b7c4/wait HTTP/1.1
 
-	.. sourcecode:: http
+  **Example response**:
 
-	   HTTP/1.1 200 OK
-	   Content-Type: application/json
+  .. sourcecode:: http
 
-	   {"StatusCode":0}
-	   	
-	:statuscode 200: no error
-	:statuscode 404: no such container
-	:statuscode 500: server error
+    HTTP/1.1 200 OK
+    Content-Type: application/json
 
+    {"StatusCode":0}
+
+  :statuscode 200: no error
+  :statuscode 404: no such container
+  :statuscode 500: server error
 
 Remove a container
 *******************
 
 .. http:delete:: /containers/(id)
 
-	Remove the container ``id`` from the filesystem
+  Remove the container ``id`` from the filesystem
 
-	**Example request**:
+  **Example request**:
 
-        .. sourcecode:: http
+  .. sourcecode:: http
 
-           DELETE /containers/16253994b7c4?v=1 HTTP/1.1
+    DELETE /containers/16253994b7c4?v=1 HTTP/1.1
 
-        **Example response**:
+  **Example response**:
 
-        .. sourcecode:: http
+  .. sourcecode:: http
 
-	   HTTP/1.1 204 OK
+    HTTP/1.1 204 OK
 
-	:query v: 1/True/true or 0/False/false, Remove the volumes associated to the container. Default false
-        :statuscode 204: no error
-	:statuscode 400: bad parameter
-        :statuscode 404: no such container
-        :statuscode 500: server error
-
+  :query v: 1/True/true or 0/False/false, Remove the volumes associated to the container. Default false
+  :statuscode 204: no error
+  :statuscode 400: bad parameter
+  :statuscode 404: no such container
+  :statuscode 500: server error
 
 Copy files or folders from a container
 **************************************
 
 .. http:post:: /containers/(id)/copy
 
-	Copy files or folders of container ``id``
+  Copy files or folders of container ``id``
 
-	**Example request**:
+  **Example request**:
 
-	.. sourcecode:: http
+  .. sourcecode:: http
 
-	   POST /containers/4fa6e0f0c678/copy HTTP/1.1
-	   Content-Type: application/json
+    POST /containers/4fa6e0f0c678/copy HTTP/1.1
+    Content-Type: application/json
 
-	   {
-		"Resource":"test.txt"
-	   }
+    {
+      "Resource":"test.txt"
+    }
 
-	**Example response**:
+  **Example response**:
 
-	.. sourcecode:: http
+  .. sourcecode:: http
 
-	   HTTP/1.1 200 OK
-	   Content-Type: application/octet-stream
-	   
-	   {{ STREAM }}
+    HTTP/1.1 200 OK
+    Content-Type: application/octet-stream
 
-	:statuscode 200: no error
-	:statuscode 404: no such container
-	:statuscode 500: server error
+    {{ STREAM }}
 
+  :statuscode 200: no error
+  :statuscode 404: no such container
+  :statuscode 500: server error
 
 2.2 Images
 ----------
@@ -574,370 +556,360 @@
 
 .. http:get:: /images/(format)
 
-	List images ``format`` could be json or viz (json default)
+  List images ``format`` could be json or viz (json default)
 
-	**Example request**:
+  **Example request**:
 
-	.. sourcecode:: http
+  .. sourcecode:: http
 
-	   GET /images/json?all=0 HTTP/1.1
+    GET /images/json?all=0 HTTP/1.1
 
-	**Example response**:
+  **Example response**:
 
-	.. sourcecode:: http
+  .. sourcecode:: http
 
-	   HTTP/1.1 200 OK
-	   Content-Type: application/json
-	   
-	   [
-		{
-			"Repository":"ubuntu",
-			"Tag":"precise",
-			"Id":"b750fe79269d",
-			"Created":1364102658,
-			"Size":24653,
-			"VirtualSize":180116135
-		},
-		{
-			"Repository":"ubuntu",
-			"Tag":"12.04",
-			"Id":"b750fe79269d",
-			"Created":1364102658,
-			"Size":24653,
-			"VirtualSize":180116135
-		}
-	   ]
+    HTTP/1.1 200 OK
+    Content-Type: application/json
 
+    [
+      {
+        "Repository":"ubuntu",
+        "Tag":"precise",
+        "Id":"b750fe79269d",
+        "Created":1364102658,
+        "Size":24653,
+        "VirtualSize":180116135
+      },
+      {
+        "Repository":"ubuntu",
+        "Tag":"12.04",
+        "Id":"b750fe79269d",
+        "Created":1364102658,
+        "Size":24653,
+        "VirtualSize":180116135
+      }
+    ]
 
-	**Example request**:
+  **Example request**:
 
-	.. sourcecode:: http
+  .. sourcecode:: http
 
-	   GET /images/viz HTTP/1.1
+    GET /images/viz HTTP/1.1
 
-	**Example response**:
+  **Example response**:
 
-	.. sourcecode:: http
+  .. sourcecode:: http
 
-	   HTTP/1.1 200 OK
-	   Content-Type: text/plain
+    HTTP/1.1 200 OK
+    Content-Type: text/plain
 
-	   digraph docker {
-	   "d82cbacda43a" -> "074be284591f"
-	   "1496068ca813" -> "08306dc45919"
-	   "08306dc45919" -> "0e7893146ac2"
-	   "b750fe79269d" -> "1496068ca813"
-	   base -> "27cf78414709" [style=invis]
-	   "f71189fff3de" -> "9a33b36209ed"
-	   "27cf78414709" -> "b750fe79269d"
-	   "0e7893146ac2" -> "d6434d954665"
-	   "d6434d954665" -> "d82cbacda43a"
-	   base -> "e9aa60c60128" [style=invis]
-	   "074be284591f" -> "f71189fff3de"
-	   "b750fe79269d" [label="b750fe79269d\nubuntu",shape=box,fillcolor="paleturquoise",style="filled,rounded"];
-	   "e9aa60c60128" [label="e9aa60c60128\ncentos",shape=box,fillcolor="paleturquoise",style="filled,rounded"];
-	   "9a33b36209ed" [label="9a33b36209ed\nfedora",shape=box,fillcolor="paleturquoise",style="filled,rounded"];
-	   base [style=invisible]
-	   }
- 
-	:query all: 1/True/true or 0/False/false, Show all containers. Only running containers are shown by default
-	:statuscode 200: no error
-	:statuscode 400: bad parameter
-	:statuscode 500: server error
+    digraph docker {
+    "d82cbacda43a" -> "074be284591f"
+    "1496068ca813" -> "08306dc45919"
+    "08306dc45919" -> "0e7893146ac2"
+    "b750fe79269d" -> "1496068ca813"
+    base -> "27cf78414709" [style=invis]
+    "f71189fff3de" -> "9a33b36209ed"
+    "27cf78414709" -> "b750fe79269d"
+    "0e7893146ac2" -> "d6434d954665"
+    "d6434d954665" -> "d82cbacda43a"
+    base -> "e9aa60c60128" [style=invis]
+    "074be284591f" -> "f71189fff3de"
+    "b750fe79269d" [label="b750fe79269d\nubuntu",shape=box,fillcolor="paleturquoise",style="filled,rounded"];
+    "e9aa60c60128" [label="e9aa60c60128\ncentos",shape=box,fillcolor="paleturquoise",style="filled,rounded"];
+    "9a33b36209ed" [label="9a33b36209ed\nfedora",shape=box,fillcolor="paleturquoise",style="filled,rounded"];
+    base [style=invisible]
+    }
 
+  :query all: 1/True/true or 0/False/false, Show all containers. Only running containers are shown by default
+  :statuscode 200: no error
+  :statuscode 400: bad parameter
+  :statuscode 500: server error
 
 Create an image
 ***************
 
 .. http:post:: /images/create
 
-	Create an image, either by pull it from the registry or by importing it
+  Create an image, either by pull it from the registry or by importing it
 
-	**Example request**:
+  **Example request**:
 
-        .. sourcecode:: http
+  .. sourcecode:: http
 
-           POST /images/create?fromImage=ubuntu HTTP/1.1
+    POST /images/create?fromImage=ubuntu HTTP/1.1
 
-        **Example response**:
+  **Example response**:
 
-        .. sourcecode:: http
+  .. sourcecode:: http
 
-           HTTP/1.1 200 OK
-	   Content-Type: application/json
+    HTTP/1.1 200 OK
+    Content-Type: application/json
 
-	   {"status":"Pulling..."}
-	   {"status":"Pulling", "progress":"1/? (n/a)"}
-	   {"error":"Invalid..."}
-	   ...
+    {"status":"Pulling..."}
+    {"status":"Pulling", "progress":"1/? (n/a)"}
+    {"error":"Invalid..."}
+    ...
 
-	When using this endpoint to pull an image from the registry,
-	the ``X-Registry-Auth`` header can be used to include a
-	base64-encoded AuthConfig object.
+  When using this endpoint to pull an image from the registry,
+  the ``X-Registry-Auth`` header can be used to include a
+  base64-encoded AuthConfig object.
 
-        :query fromImage: name of the image to pull
-	:query fromSrc: source to import, - means stdin
-        :query repo: repository
-	:query tag: tag
-	:query registry: the registry to pull from
-        :statuscode 200: no error
-        :statuscode 500: server error
-
+  :query fromImage: name of the image to pull
+  :query fromSrc: source to import, - means stdin
+  :query repo: repository
+  :query tag: tag
+  :query registry: the registry to pull from
+  :statuscode 200: no error
+  :statuscode 500: server error
 
 Insert a file in an image
 *************************
 
 .. http:post:: /images/(name)/insert
 
-	Insert a file from ``url`` in the image ``name`` at ``path``
+  Insert a file from ``url`` in the image ``name`` at ``path``
 
-	**Example request**:
+  **Example request**:
 
-        .. sourcecode:: http
+  .. sourcecode:: http
 
-           POST /images/test/insert?path=/usr&url=myurl HTTP/1.1
+    POST /images/test/insert?path=/usr&url=myurl HTTP/1.1
 
-	**Example response**:
+  **Example response**:
 
-        .. sourcecode:: http
+  .. sourcecode:: http
 
-           HTTP/1.1 200 OK
-	   Content-Type: application/json
+    HTTP/1.1 200 OK
+    Content-Type: application/json
 
-	   {"status":"Inserting..."}
-	   {"status":"Inserting", "progress":"1/? (n/a)"}
-	   {"error":"Invalid..."}
-	   ...
+    {"status":"Inserting..."}
+    {"status":"Inserting", "progress":"1/? (n/a)"}
+    {"error":"Invalid..."}
+    ...
 
-	:statuscode 200: no error
-        :statuscode 500: server error
-
+  :statuscode 200: no error
+  :statuscode 500: server error
 
 Inspect an image
 ****************
 
 .. http:get:: /images/(name)/json
 
-	Return low-level information on the image ``name``
+  Return low-level information on the image ``name``
 
-	**Example request**:
+  **Example request**:
 
-	.. sourcecode:: http
+  .. sourcecode:: http
 
-	   GET /images/centos/json HTTP/1.1
+    GET /images/centos/json HTTP/1.1
 
-	**Example response**:
+  **Example response**:
 
-        .. sourcecode:: http
+  .. sourcecode:: http
 
-           HTTP/1.1 200 OK
-	   Content-Type: application/json
+    HTTP/1.1 200 OK
+    Content-Type: application/json
 
-	   {
-		"id":"b750fe79269d2ec9a3c593ef05b4332b1d1a02a62b4accb2c21d589ff2f5f2dc",
-		"parent":"27cf784147099545",
-		"created":"2013-03-23T22:24:18.818426-07:00",
-		"container":"3d67245a8d72ecf13f33dffac9f79dcdf70f75acb84d308770391510e0c23ad0",
-		"container_config":
-			{
-				"Hostname":"",
-				"User":"",
-				"Memory":0,
-				"MemorySwap":0,
-				"AttachStdin":false,
-				"AttachStdout":false,
-				"AttachStderr":false,
-				"PortSpecs":null,
-				"Tty":true,
-				"OpenStdin":true,
-				"StdinOnce":false,
-				"Env":null,
-				"Cmd": ["/bin/bash"]
-				,"Dns":null,
-				"Image":"centos",
-				"Volumes":null,
-				"VolumesFrom":"",
-				"WorkingDir":""
-			},
-		"Size": 6824592
-	   }
+    {
+      "id":"b750fe79269d2ec9a3c593ef05b4332b1d1a02a62b4accb2c21d589ff2f5f2dc",
+      "parent":"27cf784147099545",
+      "created":"2013-03-23T22:24:18.818426-07:00",
+      "container":"3d67245a8d72ecf13f33dffac9f79dcdf70f75acb84d308770391510e0c23ad0",
+      "container_config":
+        {
+          "Hostname":"",
+          "User":"",
+          "Memory":0,
+          "MemorySwap":0,
+          "AttachStdin":false,
+          "AttachStdout":false,
+          "AttachStderr":false,
+          "PortSpecs":null,
+          "Tty":true,
+          "OpenStdin":true,
+          "StdinOnce":false,
+          "Env":null,
+          "Cmd": ["/bin/bash"]
+          ,"Dns":null,
+          "Image":"centos",
+          "Volumes":null,
+          "VolumesFrom":"",
+          "WorkingDir":""
+        },
+      "Size": 6824592
+    }
 
-	:statuscode 200: no error
-	:statuscode 404: no such image
-        :statuscode 500: server error
-
+  :statuscode 200: no error
+  :statuscode 404: no such image
+  :statuscode 500: server error
 
 Get the history of an image
 ***************************
 
 .. http:get:: /images/(name)/history
 
-        Return the history of the image ``name``
+  Return the history of the image ``name``
 
-        **Example request**:
+  **Example request**:
 
-        .. sourcecode:: http
+  .. sourcecode:: http
 
-           GET /images/fedora/history HTTP/1.1
+    GET /images/fedora/history HTTP/1.1
 
-        **Example response**:
+  **Example response**:
 
-        .. sourcecode:: http
+  .. sourcecode:: http
 
-           HTTP/1.1 200 OK
-	   Content-Type: application/json
+    HTTP/1.1 200 OK
+    Content-Type: application/json
 
-	   [
-		{
-			"Id":"b750fe79269d",
-			"Created":1364102658,
-			"CreatedBy":"/bin/bash"
-		},
-		{
-			"Id":"27cf78414709",
-			"Created":1364068391,
-			"CreatedBy":""
-		}
-	   ]
+    [
+      {
+        "Id":"b750fe79269d",
+        "Created":1364102658,
+        "CreatedBy":"/bin/bash"
+      },
+      {
+        "Id":"27cf78414709",
+        "Created":1364068391,
+        "CreatedBy":""
+      }
+    ]
 
-        :statuscode 200: no error
-        :statuscode 404: no such image
-        :statuscode 500: server error
-
+  :statuscode 200: no error
+  :statuscode 404: no such image
+  :statuscode 500: server error
 
 Push an image on the registry
 *****************************
 
 .. http:post:: /images/(name)/push
 
-   Push the image ``name`` on the registry
+  Push the image ``name`` on the registry
 
-   **Example request**:
+  **Example request**:
 
-   .. sourcecode:: http
+  .. sourcecode:: http
 
-      POST /images/test/push HTTP/1.1
+    POST /images/test/push HTTP/1.1
 
-   **Example response**:
+  **Example response**:
 
-   .. sourcecode:: http
+  .. sourcecode:: http
 
     HTTP/1.1 200 OK
     Content-Type: application/json
 
-   {"status":"Pushing..."}
-   {"status":"Pushing", "progress":"1/? (n/a)"}
-   {"error":"Invalid..."}
-   ...
+    {"status":"Pushing..."}
+    {"status":"Pushing", "progress":"1/? (n/a)"}
+    {"error":"Invalid..."}
+    ...
 
-	The ``X-Registry-Auth`` header can be used to include a
-	base64-encoded AuthConfig object.
+  The ``X-Registry-Auth`` header can be used to include a
+  base64-encoded AuthConfig object.
 
-   :query registry: the registry you wan to push, optional
-   :statuscode 200: no error
-        :statuscode 404: no such image
-        :statuscode 500: server error
-
+  :query registry: the registry you wan to push, optional
+  :statuscode 200: no error
+  :statuscode 404: no such image
+  :statuscode 500: server error
 
 Tag an image into a repository
 ******************************
 
 .. http:post:: /images/(name)/tag
 
-	Tag the image ``name`` into a repository
+  Tag the image ``name`` into a repository
 
-        **Example request**:
+  **Example request**:
 
-        .. sourcecode:: http
-			
-	   POST /images/test/tag?repo=myrepo&force=0 HTTP/1.1
+  .. sourcecode:: http
 
-	**Example response**:
+    POST /images/test/tag?repo=myrepo&force=0 HTTP/1.1
 
-        .. sourcecode:: http
+  **Example response**:
 
-           HTTP/1.1 200 OK
+  .. sourcecode:: http
 
-	:query repo: The repository to tag in
-	:query force: 1/True/true or 0/False/false, default false
-	:statuscode 200: no error
-	:statuscode 400: bad parameter
-	:statuscode 404: no such image
-	:statuscode 409: conflict
-        :statuscode 500: server error
+    HTTP/1.1 200 OK
 
+  :query repo: The repository to tag in
+  :query force: 1/True/true or 0/False/false, default false
+  :statuscode 200: no error
+  :statuscode 400: bad parameter
+  :statuscode 404: no such image
+  :statuscode 409: conflict
+  :statuscode 500: server error
 
 Remove an image
 ***************
 
 .. http:delete:: /images/(name)
 
-	Remove the image ``name`` from the filesystem 
-	
-	**Example request**:
+  Remove the image ``name`` from the filesystem 
 
-	.. sourcecode:: http
+  **Example request**:
 
-	   DELETE /images/test HTTP/1.1
+  .. sourcecode:: http
 
-	**Example response**:
+    DELETE /images/test HTTP/1.1
 
-        .. sourcecode:: http
+  **Example response**:
 
-	   HTTP/1.1 200 OK
-	   Content-type: application/json
+  .. sourcecode:: http
 
-	   [
-	    {"Untagged":"3e2f21a89f"},
-	    {"Deleted":"3e2f21a89f"},
-	    {"Deleted":"53b4f83ac9"}
-	   ]
+    HTTP/1.1 200 OK
+    Content-type: application/json
 
-	:statuscode 200: no error
-        :statuscode 404: no such image
-	:statuscode 409: conflict
-        :statuscode 500: server error
+    [
+      {"Untagged":"3e2f21a89f"},
+      {"Deleted":"3e2f21a89f"},
+      {"Deleted":"53b4f83ac9"}
+    ]
 
+  :statuscode 200: no error
+  :statuscode 404: no such image
+  :statuscode 409: conflict
+  :statuscode 500: server error
 
 Search images
 *************
 
 .. http:get:: /images/search
 
-	Search for an image in the docker index
-	
-	**Example request**:
+  Search for an image in the docker index
 
-        .. sourcecode:: http
+  **Example request**:
 
-           GET /images/search?term=sshd HTTP/1.1
+  .. sourcecode:: http
 
-	**Example response**:
+    GET /images/search?term=sshd HTTP/1.1
 
-	.. sourcecode:: http
+  **Example response**:
 
-	   HTTP/1.1 200 OK
-	   Content-Type: application/json
-	   
-	   [
-		{
-			"Name":"cespare/sshd",
-			"Description":""
-		},
-		{
-			"Name":"johnfuller/sshd",
-			"Description":""
-		},
-		{
-			"Name":"dhrp/mongodb-sshd",
-			"Description":""
-		}
-	   ]
+  .. sourcecode:: http
 
-	   :query term: term to search
-	   :statuscode 200: no error
-	   :statuscode 500: server error
+    HTTP/1.1 200 OK
+    Content-Type: application/json
 
+    [
+      {
+        "Name":"cespare/sshd",
+        "Description":""
+      },
+      {
+        "Name":"johnfuller/sshd",
+        "Description":""
+      },
+      {
+        "Name":"dhrp/mongodb-sshd",
+        "Description":""
+      }
+    ]
+
+  :query term: term to search
+  :statuscode 200: no error
+  :statuscode 500: server error
 
 2.3 Misc
 --------
@@ -947,199 +919,192 @@
 
 .. http:post:: /build
 
-   Build an image from Dockerfile via stdin
+  Build an image from Dockerfile via stdin
 
-   **Example request**:
+  **Example request**:
 
-   .. sourcecode:: http
+  .. sourcecode:: http
 
-      POST /build HTTP/1.1
+    POST /build HTTP/1.1
 
-      {{ STREAM }}
+    {{ STREAM }}
 
-   **Example response**:
+  **Example response**:
 
-   .. sourcecode:: http
+  .. sourcecode:: http
 
-      HTTP/1.1 200 OK
+    HTTP/1.1 200 OK
 
-      {{ STREAM }}
+    {{ STREAM }}
 
+  The stream must be a tar archive compressed with one of the following algorithms:
+  identity (no compression), gzip, bzip2, xz. The archive must include a file called
+  `Dockerfile` at its root. It may include any number of other files, which will be
+  accessible in the build context (See the ADD build command).
 
-       The stream must be a tar archive compressed with one of the following algorithms:
-       identity (no compression), gzip, bzip2, xz. The archive must include a file called
-       `Dockerfile` at its root. It may include any number of other files, which will be
-       accessible in the build context (See the ADD build command).
+  The Content-type header should be set to "application/tar".
 
-       The Content-type header should be set to "application/tar".
-
-	:query t: repository name (and optionally a tag) to be applied to the resulting image in case of success
-	:query q: suppress verbose build output
-    :query nocache: do not use the cache when building the image
-    :query rm: remove intermediate containers after a successful build
-	:statuscode 200: no error
-    :statuscode 500: server error
-
+  :query t: repository name (and optionally a tag) to be applied to the resulting image in case of success
+  :query q: suppress verbose build output
+  :query nocache: do not use the cache when building the image
+  :query rm: remove intermediate containers after a successful build
+  :statuscode 200: no error
+  :statuscode 500: server error
 
 Check auth configuration
 ************************
 
 .. http:post:: /auth
 
-        Get the default username and email
+  Get the default username and email
 
-        **Example request**:
+  **Example request**:
 
-        .. sourcecode:: http
+  .. sourcecode:: http
 
-           POST /auth HTTP/1.1
-	   Content-Type: application/json
+    POST /auth HTTP/1.1
+    Content-Type: application/json
 
-	   {
-		"username":"hannibal",
-		"password:"xxxx",
-		"email":"hannibal@a-team.com",
-		"serveraddress":"https://index.docker.io/v1/"
-	   }
+    {
+      "username":"hannibal",
+      "password:"xxxx",
+      "email":"hannibal@a-team.com",
+      "serveraddress":"https://index.docker.io/v1/"
+    }
 
-        **Example response**:
+  **Example response**:
 
-        .. sourcecode:: http
+  .. sourcecode:: http
 
-           HTTP/1.1 200 OK
+    HTTP/1.1 200 OK
 
-        :statuscode 200: no error
-        :statuscode 204: no error
-        :statuscode 500: server error
-
+  :statuscode 200: no error
+  :statuscode 204: no error
+  :statuscode 500: server error
 
 Display system-wide information
 *******************************
 
 .. http:get:: /info
 
-	Display system-wide information
-	
-	**Example request**:
+  Display system-wide information
 
-        .. sourcecode:: http
+  **Example request**:
 
-           GET /info HTTP/1.1
+  .. sourcecode:: http
 
-        **Example response**:
+    GET /info HTTP/1.1
 
-        .. sourcecode:: http
+  **Example response**:
 
-           HTTP/1.1 200 OK
-	   Content-Type: application/json
+  .. sourcecode:: http
 
-	   {
-		"Containers":11,
-		"Images":16,
-		"Debug":false,
-		"NFd": 11,
-		"NGoroutines":21,
-		"MemoryLimit":true,
-		"SwapLimit":false,
-		"IPv4Forwarding":true
-	   }
+    HTTP/1.1 200 OK
+    Content-Type: application/json
 
-        :statuscode 200: no error
-        :statuscode 500: server error
+    {
+      "Containers":11,
+      "Images":16,
+      "Debug":false,
+      "NFd": 11,
+      "NGoroutines":21,
+      "MemoryLimit":true,
+      "SwapLimit":false,
+      "IPv4Forwarding":true
+    }
 
+  :statuscode 200: no error
+  :statuscode 500: server error
 
 Show the docker version information
 ***********************************
 
 .. http:get:: /version
 
-	Show the docker version information
+  Show the docker version information
 
-	**Example request**:
+  **Example request**:
 
-        .. sourcecode:: http
+  .. sourcecode:: http
 
-           GET /version HTTP/1.1
+    GET /version HTTP/1.1
 
-        **Example response**:
+  **Example response**:
 
-        .. sourcecode:: http
+  .. sourcecode:: http
 
-           HTTP/1.1 200 OK
-	   Content-Type: application/json
+    HTTP/1.1 200 OK
+    Content-Type: application/json
 
-	   {
-		"Version":"0.2.2",
-		"GitCommit":"5a2a5cc+CHANGES",
-		"GoVersion":"go1.0.3"
-	   }
+    {
+      "Version":"0.2.2",
+      "GitCommit":"5a2a5cc+CHANGES",
+      "GoVersion":"go1.0.3"
+    }
 
-        :statuscode 200: no error
-	:statuscode 500: server error
-
+  :statuscode 200: no error
+  :statuscode 500: server error
 
 Create a new image from a container's changes
 *********************************************
 
 .. http:post:: /commit
 
-    Create a new image from a container's changes
+  Create a new image from a container's changes
 
-    **Example request**:
+  **Example request**:
 
-    .. sourcecode:: http
+  .. sourcecode:: http
 
-        POST /commit?container=44c004db4b17&m=message&repo=myrepo HTTP/1.1
+    POST /commit?container=44c004db4b17&m=message&repo=myrepo HTTP/1.1
 
-    **Example response**:
+  **Example response**:
 
-    .. sourcecode:: http
+  .. sourcecode:: http
 
-        HTTP/1.1 201 OK
-	    Content-Type: application/vnd.docker.raw-stream
+    HTTP/1.1 201 OK
+    Content-Type: application/vnd.docker.raw-stream
 
-        {"Id":"596069db4bf5"}
+    {"Id":"596069db4bf5"}
 
-    :query container: source container
-    :query repo: repository
-    :query tag: tag
-    :query m: commit message
-    :query author: author (eg. "John Hannibal Smith <hannibal@a-team.com>")
-    :query run: config automatically applied when the image is run. (ex: {"Cmd": ["cat", "/world"], "PortSpecs":["22"]})
-    :statuscode 201: no error
-    :statuscode 404: no such container
-    :statuscode 500: server error
-
+  :query container: source container
+  :query repo: repository
+  :query tag: tag
+  :query m: commit message
+  :query author: author (eg. "John Hannibal Smith <hannibal@a-team.com>")
+  :query run: config automatically applied when the image is run. (ex: {"Cmd": ["cat", "/world"], "PortSpecs":["22"]})
+  :statuscode 201: no error
+  :statuscode 404: no such container
+  :statuscode 500: server error
 
 Monitor Docker's events
 ***********************
 
 .. http:get:: /events
 
-	Get events from docker, either in real time via streaming, or via polling (using `since`)
+  Get events from docker, either in real time via streaming, or via polling (using `since`)
 
-	**Example request**:
+  **Example request**:
 
-	.. sourcecode:: http
+  .. sourcecode:: http
 
-           POST /events?since=1374067924
+    POST /events?since=1374067924
 
-        **Example response**:
+  **Example response**:
 
-        .. sourcecode:: http
+  .. sourcecode:: http
 
-           HTTP/1.1 200 OK
-	   Content-Type: application/json
+    HTTP/1.1 200 OK
+    Content-Type: application/json
 
-	   {"status":"create","id":"dfdf82bd3881","from":"ubuntu:latest","time":1374067924}
-	   {"status":"start","id":"dfdf82bd3881","from":"ubuntu:latest","time":1374067924}
-	   {"status":"stop","id":"dfdf82bd3881","from":"ubuntu:latest","time":1374067966}
-	   {"status":"destroy","id":"dfdf82bd3881","from":"ubuntu:latest","time":1374067970}
+    {"status":"create","id":"dfdf82bd3881","from":"ubuntu:latest","time":1374067924}
+    {"status":"start","id":"dfdf82bd3881","from":"ubuntu:latest","time":1374067924}
+    {"status":"stop","id":"dfdf82bd3881","from":"ubuntu:latest","time":1374067966}
+    {"status":"destroy","id":"dfdf82bd3881","from":"ubuntu:latest","time":1374067970}
 
-	:query since: timestamp used for polling
-        :statuscode 200: no error
-        :statuscode 500: server error
-
+  :query since: timestamp used for polling
+  :statuscode 200: no error
+  :statuscode 500: server error
 
 3. Going further
 ================
@@ -1151,14 +1116,13 @@
 
 * Create the container
 * If the status code is 404, it means the image doesn't exists:
-        * Try to pull it
-        * Then retry to create the container
+  * Try to pull it
+  * Then retry to create the container
 * Start the container
 * If you are not in detached mode:
-        * Attach to the container, using logs=1 (to have stdout and stderr from the container's start) and stream=1
+  * Attach to the container, using logs=1 (to have stdout and stderr from the container's start) and stream=1
 * If in detached mode or only stdin is attached:
-	* Display the container's id
-
+  * Display the container's id
 
 3.2 Hijacking
 -------------
@@ -1172,5 +1136,4 @@
 
 .. code-block:: bash
 
-   docker -d -H="192.168.1.9:4243" -api-enable-cors
-
+ docker -d -H="192.168.1.9:4243" -api-enable-cors
diff --git a/docs/sources/api/docker_remote_api_v1.6.rst b/docs/sources/api/docker_remote_api_v1.6.rst
new file mode 100644
index 0000000..d84d5e8
--- /dev/null
+++ b/docs/sources/api/docker_remote_api_v1.6.rst
@@ -0,0 +1,1218 @@
+:title: Remote API v1.6
+:description: API Documentation for Docker
+:keywords: API, Docker, rcli, REST, documentation
+
+:orphan:
+
+======================
+Docker Remote API v1.6
+======================
+
+.. contents:: Table of Contents
+
+1. Brief introduction
+=====================
+
+- The Remote API is replacing rcli
+- Default port in the docker daemon is 4243
+- The API tends to be REST, but for some complex commands, like attach or pull, the HTTP connection is hijacked to transport stdout stdin and stderr
+
+2. Endpoints
+============
+
+2.1 Containers
+--------------
+
+List containers
+***************
+
+.. http:get:: /containers/json
+
+	List containers
+
+	**Example request**:
+
+	.. sourcecode:: http
+
+	   GET /containers/json?all=1&before=8dfafdbc3a40&size=1 HTTP/1.1
+	   
+	**Example response**:
+
+	.. sourcecode:: http
+
+	   HTTP/1.1 200 OK
+	   Content-Type: application/json
+	   
+	   [
+		{
+			"Id": "8dfafdbc3a40",
+			"Image": "base:latest",
+			"Command": "echo 1",
+			"Created": 1367854155,
+			"Status": "Exit 0",
+			"Ports":[{"PrivatePort": 2222, "PublicPort": 3333, "Type": "tcp"}],
+			"SizeRw":12288,
+			"SizeRootFs":0
+		},
+		{
+			"Id": "9cd87474be90",
+			"Image": "base:latest",
+			"Command": "echo 222222",
+			"Created": 1367854155,
+			"Status": "Exit 0",
+			"Ports":[],
+			"SizeRw":12288,
+			"SizeRootFs":0
+		},
+		{
+			"Id": "3176a2479c92",
+			"Image": "base:latest",
+			"Command": "echo 3333333333333333",
+			"Created": 1367854154,
+			"Status": "Exit 0",
+			"Ports":[],
+			"SizeRw":12288,
+			"SizeRootFs":0
+		},
+		{
+			"Id": "4cb07b47f9fb",
+			"Image": "base:latest",
+			"Command": "echo 444444444444444444444444444444444",
+			"Created": 1367854152,
+			"Status": "Exit 0",
+			"Ports":[],
+			"SizeRw":12288,
+			"SizeRootFs":0
+		}
+	   ]
+ 
+	:query all: 1/True/true or 0/False/false, Show all containers. Only running containers are shown by default
+	:query limit: Show ``limit`` last created containers, include non-running ones.
+	:query since: Show only containers created since Id, include non-running ones.
+	:query before: Show only containers created before Id, include non-running ones.
+	:query size: 1/True/true or 0/False/false, Show the containers sizes
+	:statuscode 200: no error
+	:statuscode 400: bad parameter
+	:statuscode 500: server error
+
+
+Create a container
+******************
+
+.. http:post:: /containers/create
+
+	Create a container
+
+	**Example request**:
+
+	.. sourcecode:: http
+
+	   POST /containers/create HTTP/1.1
+	   Content-Type: application/json
+
+	   {
+		"Hostname":"",
+		"User":"",
+		"Memory":0,
+		"MemorySwap":0,
+		"AttachStdin":false,
+		"AttachStdout":true,
+		"AttachStderr":true,
+		"PortSpecs":null,
+		"Privileged": false,
+		"Tty":false,
+		"OpenStdin":false,
+		"StdinOnce":false,
+		"Env":null,
+		"Cmd":[
+			"date"
+		],
+		"Dns":null,
+		"Image":"base",
+		"Volumes":{},
+		"VolumesFrom":"",
+		"WorkingDir":""
+
+	   }
+	   
+	**Example response**:
+
+	.. sourcecode:: http
+
+	   HTTP/1.1 201 OK
+	   Content-Type: application/json
+
+	   {
+		"Id":"e90e34656806"
+		"Warnings":[]
+	   }
+	
+	:jsonparam config: the container's configuration
+	:statuscode 201: no error
+	:statuscode 404: no such container
+	:statuscode 406: impossible to attach (container not running)
+	:statuscode 500: server error
+
+
+Inspect a container
+*******************
+
+.. http:get:: /containers/(id)/json
+
+	Return low-level information on the container ``id``
+
+	**Example request**:
+
+	.. sourcecode:: http
+
+	   GET /containers/4fa6e0f0c678/json HTTP/1.1
+	   
+	**Example response**:
+
+	.. sourcecode:: http
+
+	   HTTP/1.1 200 OK
+	   Content-Type: application/json
+
+	   {
+			"Id": "4fa6e0f0c6786287e131c3852c58a2e01cc697a68231826813597e4994f1d6e2",
+			"Created": "2013-05-07T14:51:42.041847+02:00",
+			"Path": "date",
+			"Args": [],
+			"Config": {
+				"Hostname": "4fa6e0f0c678",
+				"User": "",
+				"Memory": 0,
+				"MemorySwap": 0,
+				"AttachStdin": false,
+				"AttachStdout": true,
+				"AttachStderr": true,
+				"PortSpecs": null,
+				"Tty": false,
+				"OpenStdin": false,
+				"StdinOnce": false,
+				"Env": null,
+				"Cmd": [
+					"date"
+				],
+				"Dns": null,
+				"Image": "base",
+				"Volumes": {},
+				"VolumesFrom": "",
+				"WorkingDir":""
+
+			},
+			"State": {
+				"Running": false,
+				"Pid": 0,
+				"ExitCode": 0,
+				"StartedAt": "2013-05-07T14:51:42.087658+02:01360",
+				"Ghost": false
+			},
+			"Image": "b750fe79269d2ec9a3c593ef05b4332b1d1a02a62b4accb2c21d589ff2f5f2dc",
+			"NetworkSettings": {
+				"IpAddress": "",
+				"IpPrefixLen": 0,
+				"Gateway": "",
+				"Bridge": "",
+				"PortMapping": null
+			},
+			"SysInitPath": "/home/kitty/go/src/github.com/dotcloud/docker/bin/docker",
+			"ResolvConfPath": "/etc/resolv.conf",
+			"Volumes": {}
+	   }
+
+	:statuscode 200: no error
+	:statuscode 404: no such container
+	:statuscode 500: server error
+
+
+List processes running inside a container
+*****************************************
+
+.. http:get:: /containers/(id)/top
+
+	List processes running inside the container ``id``
+
+	**Example request**:
+
+	.. sourcecode:: http
+
+	   GET /containers/4fa6e0f0c678/top HTTP/1.1
+
+	**Example response**:
+
+	.. sourcecode:: http
+
+	   HTTP/1.1 200 OK
+	   Content-Type: application/json
+
+	   {
+		"Titles":[
+			"USER",
+			"PID",
+			"%CPU",
+			"%MEM",
+			"VSZ",
+			"RSS",
+			"TTY",
+			"STAT",
+			"START",
+			"TIME",
+			"COMMAND"
+			],
+		"Processes":[
+			["root","20147","0.0","0.1","18060","1864","pts/4","S","10:06","0:00","bash"],
+			["root","20271","0.0","0.0","4312","352","pts/4","S+","10:07","0:00","sleep","10"]
+		]
+	   }
+
+	:query ps_args: ps arguments to use (eg. aux)
+	:statuscode 200: no error
+	:statuscode 404: no such container
+	:statuscode 500: server error
+
+
+Inspect changes on a container's filesystem
+*******************************************
+
+.. http:get:: /containers/(id)/changes
+
+	Inspect changes on container ``id`` 's filesystem
+
+	**Example request**:
+
+	.. sourcecode:: http
+
+	   GET /containers/4fa6e0f0c678/changes HTTP/1.1
+
+	   
+	**Example response**:
+
+	.. sourcecode:: http
+
+	   HTTP/1.1 200 OK
+	   Content-Type: application/json
+	   
+	   [
+		{
+			"Path":"/dev",
+			"Kind":0
+		},
+		{
+			"Path":"/dev/kmsg",
+			"Kind":1
+		},
+		{
+			"Path":"/test",
+			"Kind":1
+		}
+	   ]
+
+	:statuscode 200: no error
+	:statuscode 404: no such container
+	:statuscode 500: server error
+
+
+Export a container
+******************
+
+.. http:get:: /containers/(id)/export
+
+	Export the contents of container ``id``
+
+	**Example request**:
+
+	.. sourcecode:: http
+
+	   GET /containers/4fa6e0f0c678/export HTTP/1.1
+
+	   
+	**Example response**:
+
+	.. sourcecode:: http
+
+	   HTTP/1.1 200 OK
+	   Content-Type: application/octet-stream
+	   
+	   {{ STREAM }}
+
+	:statuscode 200: no error
+	:statuscode 404: no such container
+	:statuscode 500: server error
+
+
+Start a container
+*****************
+
+.. http:post:: /containers/(id)/start
+
+        Start the container ``id``
+
+        **Example request**:
+
+        .. sourcecode:: http
+
+           POST /containers/(id)/start HTTP/1.1
+           Content-Type: application/json
+
+           {
+                "Binds":["/tmp:/tmp"],
+                "LxcConf":{"lxc.utsname":"docker"}
+           }
+
+        **Example response**:
+
+        .. sourcecode:: http
+
+           HTTP/1.1 204 No Content
+           Content-Type: text/plain
+
+        :jsonparam hostConfig: the container's host configuration (optional)
+        :statuscode 204: no error
+        :statuscode 404: no such container
+        :statuscode 500: server error
+
+
+Stop a container
+****************
+
+.. http:post:: /containers/(id)/stop
+
+	Stop the container ``id``
+
+	**Example request**:
+
+	.. sourcecode:: http
+
+	   POST /containers/e90e34656806/stop?t=5 HTTP/1.1
+	   
+	**Example response**:
+
+	.. sourcecode:: http
+
+	   HTTP/1.1 204 OK
+	   	
+	:query t: number of seconds to wait before killing the container
+	:statuscode 204: no error
+	:statuscode 404: no such container
+	:statuscode 500: server error
+
+
+Restart a container
+*******************
+
+.. http:post:: /containers/(id)/restart
+
+	Restart the container ``id``
+
+	**Example request**:
+
+	.. sourcecode:: http
+
+	   POST /containers/e90e34656806/restart?t=5 HTTP/1.1
+	   
+	**Example response**:
+
+	.. sourcecode:: http
+
+	   HTTP/1.1 204 OK
+	   	
+	:query t: number of seconds to wait before killing the container
+	:statuscode 204: no error
+	:statuscode 404: no such container
+	:statuscode 500: server error
+
+
+Kill a container
+****************
+
+.. http:post:: /containers/(id)/kill
+
+	Kill the container ``id``
+
+	**Example request**:
+
+	.. sourcecode:: http
+
+	   POST /containers/e90e34656806/kill HTTP/1.1
+	   
+	**Example response**:
+
+	.. sourcecode:: http
+
+	   HTTP/1.1 204 OK
+	   	
+	:statuscode 204: no error
+	:statuscode 404: no such container
+	:statuscode 500: server error
+
+
+Attach to a container
+*********************
+
+.. http:post:: /containers/(id)/attach
+
+	Attach to the container ``id``
+
+	**Example request**:
+
+	.. sourcecode:: http
+
+	   POST /containers/16253994b7c4/attach?logs=1&stream=0&stdout=1 HTTP/1.1
+	   
+	**Example response**:
+
+	.. sourcecode:: http
+
+	   HTTP/1.1 200 OK
+	   Content-Type: application/vnd.docker.raw-stream
+
+	   {{ STREAM }}
+	   	
+	:query logs: 1/True/true or 0/False/false, return logs. Default false
+	:query stream: 1/True/true or 0/False/false, return stream. Default false
+	:query stdin: 1/True/true or 0/False/false, if stream=true, attach to stdin. Default false
+	:query stdout: 1/True/true or 0/False/false, if logs=true, return stdout log, if stream=true, attach to stdout. Default false
+	:query stderr: 1/True/true or 0/False/false, if logs=true, return stderr log, if stream=true, attach to stderr. Default false
+	:statuscode 200: no error
+	:statuscode 400: bad parameter
+	:statuscode 404: no such container
+	:statuscode 500: server error
+
+	**Stream details**:
+
+	When using the TTY setting is enabled in
+	:http:post:`/containers/create`, the stream is the raw data
+	from the process PTY and client's stdin.  When the TTY is
+	disabled, then the stream is multiplexed to separate stdout
+	and stderr.
+
+	The format is a **Header** and a **Payload** (frame).
+
+	**HEADER**
+
+	The header will contain the information on which stream write
+	the stream (stdout or stderr). It also contain the size of
+	the associated frame encoded on the last 4 bytes (uint32).
+
+	It is encoded on the first 8 bytes like this::
+
+	    header := [8]byte{STREAM_TYPE, 0, 0, 0, SIZE1, SIZE2, SIZE3, SIZE4}
+
+	``STREAM_TYPE`` can be:
+
+	- 0: stdin (will be writen on stdout)
+	- 1: stdout
+	- 2: stderr
+
+	``SIZE1, SIZE2, SIZE3, SIZE4`` are the 4 bytes of the uint32 size encoded as big endian.
+
+	**PAYLOAD**
+
+	The payload is the raw stream.
+
+	**IMPLEMENTATION**
+
+	The simplest way to implement the Attach protocol is the following:
+
+	1) Read 8 bytes
+	2) chose stdout or stderr depending on the first byte
+	3) Extract the frame size from the last 4 byets
+	4) Read the extracted size and output it on the correct output
+	5) Goto 1)
+
+
+
+Wait a container
+****************
+
+.. http:post:: /containers/(id)/wait
+
+	Block until container ``id`` stops, then returns the exit code
+
+	**Example request**:
+
+	.. sourcecode:: http
+
+	   POST /containers/16253994b7c4/wait HTTP/1.1
+	   
+	**Example response**:
+
+	.. sourcecode:: http
+
+	   HTTP/1.1 200 OK
+	   Content-Type: application/json
+
+	   {"StatusCode":0}
+	   	
+	:statuscode 200: no error
+	:statuscode 404: no such container
+	:statuscode 500: server error
+
+
+Remove a container
+*******************
+
+.. http:delete:: /containers/(id)
+
+	Remove the container ``id`` from the filesystem
+
+	**Example request**:
+
+        .. sourcecode:: http
+
+           DELETE /containers/16253994b7c4?v=1 HTTP/1.1
+
+        **Example response**:
+
+        .. sourcecode:: http
+
+	   HTTP/1.1 204 OK
+
+	:query v: 1/True/true or 0/False/false, Remove the volumes associated to the container. Default false
+        :statuscode 204: no error
+	:statuscode 400: bad parameter
+        :statuscode 404: no such container
+        :statuscode 500: server error
+
+
+Copy files or folders from a container
+**************************************
+
+.. http:post:: /containers/(id)/copy
+
+	Copy files or folders of container ``id``
+
+	**Example request**:
+
+	.. sourcecode:: http
+
+	   POST /containers/4fa6e0f0c678/copy HTTP/1.1
+	   Content-Type: application/json
+
+	   {
+		"Resource":"test.txt"
+	   }
+
+	**Example response**:
+
+	.. sourcecode:: http
+
+	   HTTP/1.1 200 OK
+	   Content-Type: application/octet-stream
+	   
+	   {{ STREAM }}
+
+	:statuscode 200: no error
+	:statuscode 404: no such container
+	:statuscode 500: server error
+
+
+2.2 Images
+----------
+
+List Images
+***********
+
+.. http:get:: /images/(format)
+
+	List images ``format`` could be json or viz (json default)
+
+	**Example request**:
+
+	.. sourcecode:: http
+
+	   GET /images/json?all=0 HTTP/1.1
+
+	**Example response**:
+
+	.. sourcecode:: http
+
+	   HTTP/1.1 200 OK
+	   Content-Type: application/json
+	   
+	   [
+		{
+			"Repository":"base",
+			"Tag":"ubuntu-12.10",
+			"Id":"b750fe79269d",
+			"Created":1364102658,
+			"Size":24653,
+			"VirtualSize":180116135
+		},
+		{
+			"Repository":"base",
+			"Tag":"ubuntu-quantal",
+			"Id":"b750fe79269d",
+			"Created":1364102658,
+			"Size":24653,
+			"VirtualSize":180116135
+		}
+	   ]
+
+
+	**Example request**:
+
+	.. sourcecode:: http
+
+	   GET /images/viz HTTP/1.1
+
+	**Example response**:
+
+	.. sourcecode:: http
+
+	   HTTP/1.1 200 OK
+	   Content-Type: text/plain
+
+	   digraph docker {
+	   "d82cbacda43a" -> "074be284591f"
+	   "1496068ca813" -> "08306dc45919"
+	   "08306dc45919" -> "0e7893146ac2"
+	   "b750fe79269d" -> "1496068ca813"
+	   base -> "27cf78414709" [style=invis]
+	   "f71189fff3de" -> "9a33b36209ed"
+	   "27cf78414709" -> "b750fe79269d"
+	   "0e7893146ac2" -> "d6434d954665"
+	   "d6434d954665" -> "d82cbacda43a"
+	   base -> "e9aa60c60128" [style=invis]
+	   "074be284591f" -> "f71189fff3de"
+	   "b750fe79269d" [label="b750fe79269d\nbase",shape=box,fillcolor="paleturquoise",style="filled,rounded"];
+	   "e9aa60c60128" [label="e9aa60c60128\nbase2",shape=box,fillcolor="paleturquoise",style="filled,rounded"];
+	   "9a33b36209ed" [label="9a33b36209ed\ntest",shape=box,fillcolor="paleturquoise",style="filled,rounded"];
+	   base [style=invisible]
+	   }
+ 
+	:query all: 1/True/true or 0/False/false, Show all containers. Only running containers are shown by default
+	:statuscode 200: no error
+	:statuscode 400: bad parameter
+	:statuscode 500: server error
+
+
+Create an image
+***************
+
+.. http:post:: /images/create
+
+	Create an image, either by pull it from the registry or by importing it
+
+	**Example request**:
+
+        .. sourcecode:: http
+
+           POST /images/create?fromImage=base HTTP/1.1
+
+        **Example response**:
+
+        .. sourcecode:: http
+
+           HTTP/1.1 200 OK
+	   Content-Type: application/json
+
+	   {"status":"Pulling..."}
+	   {"status":"Pulling", "progress":"1/? (n/a)"}
+	   {"error":"Invalid..."}
+	   ...
+
+	When using this endpoint to pull an image from the registry,
+	the ``X-Registry-Auth`` header can be used to include a
+	base64-encoded AuthConfig object.
+
+        :query fromImage: name of the image to pull
+	:query fromSrc: source to import, - means stdin
+        :query repo: repository
+	:query tag: tag
+	:query registry: the registry to pull from
+        :statuscode 200: no error
+        :statuscode 500: server error
+
+
+Insert a file in an image
+*************************
+
+.. http:post:: /images/(name)/insert
+
+	Insert a file from ``url`` in the image ``name`` at ``path``
+
+	**Example request**:
+
+        .. sourcecode:: http
+
+           POST /images/test/insert?path=/usr&url=myurl HTTP/1.1
+
+	**Example response**:
+
+        .. sourcecode:: http
+
+           HTTP/1.1 200 OK
+	   Content-Type: application/json
+
+	   {"status":"Inserting..."}
+	   {"status":"Inserting", "progress":"1/? (n/a)"}
+	   {"error":"Invalid..."}
+	   ...
+
+	:statuscode 200: no error
+        :statuscode 500: server error
+
+
+Inspect an image
+****************
+
+.. http:get:: /images/(name)/json
+
+	Return low-level information on the image ``name``
+
+	**Example request**:
+
+	.. sourcecode:: http
+
+	   GET /images/base/json HTTP/1.1
+
+	**Example response**:
+
+        .. sourcecode:: http
+
+           HTTP/1.1 200 OK
+	   Content-Type: application/json
+
+	   {
+		"id":"b750fe79269d2ec9a3c593ef05b4332b1d1a02a62b4accb2c21d589ff2f5f2dc",
+		"parent":"27cf784147099545",
+		"created":"2013-03-23T22:24:18.818426-07:00",
+		"container":"3d67245a8d72ecf13f33dffac9f79dcdf70f75acb84d308770391510e0c23ad0",
+		"container_config":
+			{
+				"Hostname":"",
+				"User":"",
+				"Memory":0,
+				"MemorySwap":0,
+				"AttachStdin":false,
+				"AttachStdout":false,
+				"AttachStderr":false,
+				"PortSpecs":null,
+				"Tty":true,
+				"OpenStdin":true,
+				"StdinOnce":false,
+				"Env":null,
+				"Cmd": ["/bin/bash"]
+				,"Dns":null,
+				"Image":"base",
+				"Volumes":null,
+				"VolumesFrom":"",
+				"WorkingDir":""
+			},
+		"Size": 6824592
+	   }
+
+	:statuscode 200: no error
+	:statuscode 404: no such image
+        :statuscode 500: server error
+
+
+Get the history of an image
+***************************
+
+.. http:get:: /images/(name)/history
+
+        Return the history of the image ``name``
+
+        **Example request**:
+
+        .. sourcecode:: http
+
+           GET /images/base/history HTTP/1.1
+
+        **Example response**:
+
+        .. sourcecode:: http
+
+           HTTP/1.1 200 OK
+	   Content-Type: application/json
+
+	   [
+		{
+			"Id":"b750fe79269d",
+			"Created":1364102658,
+			"CreatedBy":"/bin/bash"
+		},
+		{
+			"Id":"27cf78414709",
+			"Created":1364068391,
+			"CreatedBy":""
+		}
+	   ]
+
+        :statuscode 200: no error
+        :statuscode 404: no such image
+        :statuscode 500: server error
+
+
+Push an image on the registry
+*****************************
+
+.. http:post:: /images/(name)/push
+
+   Push the image ``name`` on the registry
+
+   **Example request**:
+
+   .. sourcecode:: http
+
+      POST /images/test/push HTTP/1.1
+
+   **Example response**:
+
+   .. sourcecode:: http
+
+    HTTP/1.1 200 OK
+    Content-Type: application/json
+
+   {"status":"Pushing..."}
+   {"status":"Pushing", "progress":"1/? (n/a)"}
+   {"error":"Invalid..."}
+   ...
+
+	The ``X-Registry-Auth`` header can be used to include a
+	base64-encoded AuthConfig object.
+
+   :query registry: the registry you wan to push, optional
+   :statuscode 200: no error
+        :statuscode 404: no such image
+        :statuscode 500: server error
+
+
+Tag an image into a repository
+******************************
+
+.. http:post:: /images/(name)/tag
+
+	Tag the image ``name`` into a repository
+
+        **Example request**:
+
+        .. sourcecode:: http
+			
+	   POST /images/test/tag?repo=myrepo&force=0 HTTP/1.1
+
+	**Example response**:
+
+        .. sourcecode:: http
+
+           HTTP/1.1 200 OK
+
+	:query repo: The repository to tag in
+	:query force: 1/True/true or 0/False/false, default false
+	:statuscode 200: no error
+	:statuscode 400: bad parameter
+	:statuscode 404: no such image
+	:statuscode 409: conflict
+        :statuscode 500: server error
+
+
+Remove an image
+***************
+
+.. http:delete:: /images/(name)
+
+	Remove the image ``name`` from the filesystem 
+	
+	**Example request**:
+
+	.. sourcecode:: http
+
+	   DELETE /images/test HTTP/1.1
+
+	**Example response**:
+
+        .. sourcecode:: http
+
+	   HTTP/1.1 200 OK
+	   Content-type: application/json
+
+	   [
+	    {"Untagged":"3e2f21a89f"},
+	    {"Deleted":"3e2f21a89f"},
+	    {"Deleted":"53b4f83ac9"}
+	   ]
+
+	:statuscode 200: no error
+        :statuscode 404: no such image
+	:statuscode 409: conflict
+        :statuscode 500: server error
+
+
+Search images
+*************
+
+.. http:get:: /images/search
+
+	Search for an image in the docker index
+	
+	**Example request**:
+
+        .. sourcecode:: http
+
+           GET /images/search?term=sshd HTTP/1.1
+
+	**Example response**:
+
+	.. sourcecode:: http
+
+	   HTTP/1.1 200 OK
+	   Content-Type: application/json
+	   
+	   [
+		{
+			"Name":"cespare/sshd",
+			"Description":""
+		},
+		{
+			"Name":"johnfuller/sshd",
+			"Description":""
+		},
+		{
+			"Name":"dhrp/mongodb-sshd",
+			"Description":""
+		}
+	   ]
+
+	   :query term: term to search
+	   :statuscode 200: no error
+	   :statuscode 500: server error
+
+
+2.3 Misc
+--------
+
+Build an image from Dockerfile via stdin
+****************************************
+
+.. http:post:: /build
+
+   Build an image from Dockerfile via stdin
+
+   **Example request**:
+
+   .. sourcecode:: http
+
+      POST /build HTTP/1.1
+
+      {{ STREAM }}
+
+   **Example response**:
+
+   .. sourcecode:: http
+
+      HTTP/1.1 200 OK
+
+      {{ STREAM }}
+
+
+       The stream must be a tar archive compressed with one of the following algorithms:
+       identity (no compression), gzip, bzip2, xz. The archive must include a file called
+       `Dockerfile` at its root. It may include any number of other files, which will be
+       accessible in the build context (See the ADD build command).
+
+       The Content-type header should be set to "application/tar".
+
+	:query t: repository name (and optionally a tag) to be applied to the resulting image in case of success
+	:query q: suppress verbose build output
+    :query nocache: do not use the cache when building the image
+	:statuscode 200: no error
+    :statuscode 500: server error
+
+
+Check auth configuration
+************************
+
+.. http:post:: /auth
+
+        Get the default username and email
+
+        **Example request**:
+
+        .. sourcecode:: http
+
+           POST /auth HTTP/1.1
+	   Content-Type: application/json
+
+	   {
+		"username":"hannibal",
+		"password:"xxxx",
+		"email":"hannibal@a-team.com",
+		"serveraddress":"https://index.docker.io/v1/"
+	   }
+
+        **Example response**:
+
+        .. sourcecode:: http
+
+           HTTP/1.1 200 OK
+
+        :statuscode 200: no error
+        :statuscode 204: no error
+        :statuscode 500: server error
+
+
+Display system-wide information
+*******************************
+
+.. http:get:: /info
+
+	Display system-wide information
+	
+	**Example request**:
+
+        .. sourcecode:: http
+
+           GET /info HTTP/1.1
+
+        **Example response**:
+
+        .. sourcecode:: http
+
+           HTTP/1.1 200 OK
+	   Content-Type: application/json
+
+	   {
+		"Containers":11,
+		"Images":16,
+		"Debug":false,
+		"NFd": 11,
+		"NGoroutines":21,
+		"MemoryLimit":true,
+		"SwapLimit":false,
+		"IPv4Forwarding":true
+	   }
+
+        :statuscode 200: no error
+        :statuscode 500: server error
+
+
+Show the docker version information
+***********************************
+
+.. http:get:: /version
+
+	Show the docker version information
+
+	**Example request**:
+
+        .. sourcecode:: http
+
+           GET /version HTTP/1.1
+
+        **Example response**:
+
+        .. sourcecode:: http
+
+           HTTP/1.1 200 OK
+	   Content-Type: application/json
+
+	   {
+		"Version":"0.2.2",
+		"GitCommit":"5a2a5cc+CHANGES",
+		"GoVersion":"go1.0.3"
+	   }
+
+        :statuscode 200: no error
+	:statuscode 500: server error
+
+
+Create a new image from a container's changes
+*********************************************
+
+.. http:post:: /commit
+
+    Create a new image from a container's changes
+
+    **Example request**:
+
+    .. sourcecode:: http
+
+        POST /commit?container=44c004db4b17&m=message&repo=myrepo HTTP/1.1
+
+    **Example response**:
+
+    .. sourcecode:: http
+
+        HTTP/1.1 201 OK
+	    Content-Type: application/vnd.docker.raw-stream
+
+        {"Id":"596069db4bf5"}
+
+    :query container: source container
+    :query repo: repository
+    :query tag: tag
+    :query m: commit message
+    :query author: author (eg. "John Hannibal Smith <hannibal@a-team.com>")
+    :query run: config automatically applied when the image is run. (ex: {"Cmd": ["cat", "/world"], "PortSpecs":["22"]})
+    :statuscode 201: no error
+    :statuscode 404: no such container
+    :statuscode 500: server error
+
+
+Monitor Docker's events
+***********************
+
+.. http:get:: /events
+
+	Get events from docker, either in real time via streaming, or via polling (using `since`)
+
+	**Example request**:
+
+	.. sourcecode:: http
+
+           POST /events?since=1374067924
+
+        **Example response**:
+
+        .. sourcecode:: http
+
+           HTTP/1.1 200 OK
+	   Content-Type: application/json
+
+	   {"status":"create","id":"dfdf82bd3881","from":"base:latest","time":1374067924}
+	   {"status":"start","id":"dfdf82bd3881","from":"base:latest","time":1374067924}
+	   {"status":"stop","id":"dfdf82bd3881","from":"base:latest","time":1374067966}
+	   {"status":"destroy","id":"dfdf82bd3881","from":"base:latest","time":1374067970}
+
+	:query since: timestamp used for polling
+        :statuscode 200: no error
+        :statuscode 500: server error
+
+
+3. Going further
+================
+
+3.1 Inside 'docker run'
+-----------------------
+
+Here are the steps of 'docker run' :
+
+* Create the container
+* If the status code is 404, it means the image doesn't exists:
+        * Try to pull it
+        * Then retry to create the container
+* Start the container
+* If you are not in detached mode:
+        * Attach to the container, using logs=1 (to have stdout and stderr from the container's start) and stream=1
+* If in detached mode or only stdin is attached:
+	* Display the container's id
+
+
+3.2 Hijacking
+-------------
+
+In this version of the API, /attach, uses hijacking to transport stdin, stdout and stderr on the same socket. This might change in the future.
+
+3.3 CORS Requests
+-----------------
+
+To enable cross origin requests to the remote api add the flag "-api-enable-cors" when running docker in daemon mode.
+
+.. code-block:: bash
+
+   docker -d -H="192.168.1.9:4243" -api-enable-cors
+
diff --git a/docs/sources/api/index_api.rst b/docs/sources/api/index_api.rst
index c4b961a..5191fc8 100644
--- a/docs/sources/api/index_api.rst
+++ b/docs/sources/api/index_api.rst
@@ -6,8 +6,6 @@
 Docker Index API
 =================
 
-.. contents:: Table of Contents
-
 1. Brief introduction
 =====================
 
@@ -42,7 +40,7 @@
         Authorization: Basic akmklmasadalkm==
         X-Docker-Token: true
 
-        [{“id”: “9e89cc6f0bc3c38722009fe6857087b486531f9a779a0c17e3ed29dae8f12c4f”}]
+        [{"id": "9e89cc6f0bc3c38722009fe6857087b486531f9a779a0c17e3ed29dae8f12c4f"}]
 
     :parameter namespace: the namespace for the repo
     :parameter repo_name: the name for the repo
@@ -54,7 +52,8 @@
         HTTP/1.1 200
         Vary: Accept
         Content-Type: application/json
-        WWW-Authenticate: Token signature=123abc,repository=”foo/bar”,access=write
+        WWW-Authenticate: Token signature=123abc,repository="foo/bar",access=write
+        X-Docker-Token: signature=123abc,repository="foo/bar",access=write
         X-Docker-Endpoints: registry-1.docker.io [, registry-2.docker.io]
 
         ""
@@ -92,7 +91,8 @@
         HTTP/1.1 202
         Vary: Accept
         Content-Type: application/json
-        WWW-Authenticate: Token signature=123abc,repository=”foo/bar”,access=delete
+        WWW-Authenticate: Token signature=123abc,repository="foo/bar",access=delete
+        X-Docker-Token: signature=123abc,repository="foo/bar",access=delete
         X-Docker-Endpoints: registry-1.docker.io [, registry-2.docker.io]
 
         ""
@@ -124,7 +124,7 @@
         Authorization: Basic akmklmasadalkm==
         X-Docker-Token: true
 
-        [{“id”: “9e89cc6f0bc3c38722009fe6857087b486531f9a779a0c17e3ed29dae8f12c4f”}]
+        [{"id": "9e89cc6f0bc3c38722009fe6857087b486531f9a779a0c17e3ed29dae8f12c4f"}]
 
     :parameter repo_name:  the library name for the repo
 
@@ -135,7 +135,8 @@
         HTTP/1.1 200
         Vary: Accept
         Content-Type: application/json
-        WWW-Authenticate: Token signature=123abc,repository=”library/foobar”,access=write
+        WWW-Authenticate: Token signature=123abc,repository="library/foobar",access=write
+        X-Docker-Token: signature=123abc,repository="foo/bar",access=write
         X-Docker-Endpoints: registry-1.docker.io [, registry-2.docker.io]
 
         ""
@@ -174,7 +175,8 @@
         HTTP/1.1 202
         Vary: Accept
         Content-Type: application/json
-        WWW-Authenticate: Token signature=123abc,repository=”library/foobar”,access=delete
+        WWW-Authenticate: Token signature=123abc,repository="library/foobar",access=delete
+        X-Docker-Token: signature=123abc,repository="foo/bar",access=delete
         X-Docker-Endpoints: registry-1.docker.io [, registry-2.docker.io]
 
         ""
@@ -205,8 +207,8 @@
         Content-Type: application/json
         Authorization: Basic akmklmasadalkm==
 
-        [{“id”: “9e89cc6f0bc3c38722009fe6857087b486531f9a779a0c17e3ed29dae8f12c4f”,
-        “checksum”: “b486531f9a779a0c17e3ed29dae8f12c4f9e89cc6f0bc3c38722009fe6857087”}]
+        [{"id": "9e89cc6f0bc3c38722009fe6857087b486531f9a779a0c17e3ed29dae8f12c4f",
+        "checksum": "b486531f9a779a0c17e3ed29dae8f12c4f9e89cc6f0bc3c38722009fe6857087"}]
 
     :parameter namespace: the namespace for the repo
     :parameter repo_name: the name for the repo
@@ -250,10 +252,10 @@
         Vary: Accept
         Content-Type: application/json
 
-        [{“id”: “9e89cc6f0bc3c38722009fe6857087b486531f9a779a0c17e3ed29dae8f12c4f”,
-        “checksum”: “b486531f9a779a0c17e3ed29dae8f12c4f9e89cc6f0bc3c38722009fe6857087”},
-        {“id”: “ertwetewtwe38722009fe6857087b486531f9a779a0c1dfddgfgsdgdsgds”,
-        “checksum”: “34t23f23fc17e3ed29dae8f12c4f9e89cc6f0bsdfgfsdgdsgdsgerwgew”}]
+        [{"id": "9e89cc6f0bc3c38722009fe6857087b486531f9a779a0c17e3ed29dae8f12c4f",
+        "checksum": "b486531f9a779a0c17e3ed29dae8f12c4f9e89cc6f0bc3c38722009fe6857087"},
+        {"id": "ertwetewtwe38722009fe6857087b486531f9a779a0c1dfddgfgsdgdsgds",
+        "checksum": "34t23f23fc17e3ed29dae8f12c4f9e89cc6f0bsdfgfsdgdsgdsgerwgew"}]
 
     :statuscode 200: OK
     :statuscode 404: Not found
@@ -275,8 +277,8 @@
         Content-Type: application/json
         Authorization: Basic akmklmasadalkm==
 
-        [{“id”: “9e89cc6f0bc3c38722009fe6857087b486531f9a779a0c17e3ed29dae8f12c4f”,
-        “checksum”: “b486531f9a779a0c17e3ed29dae8f12c4f9e89cc6f0bc3c38722009fe6857087”}]
+        [{"id": "9e89cc6f0bc3c38722009fe6857087b486531f9a779a0c17e3ed29dae8f12c4f",
+        "checksum": "b486531f9a779a0c17e3ed29dae8f12c4f9e89cc6f0bc3c38722009fe6857087"}]
 
     :parameter repo_name: the library name for the repo
 
@@ -318,10 +320,10 @@
         Vary: Accept
         Content-Type: application/json
 
-        [{“id”: “9e89cc6f0bc3c38722009fe6857087b486531f9a779a0c17e3ed29dae8f12c4f”,
-        “checksum”: “b486531f9a779a0c17e3ed29dae8f12c4f9e89cc6f0bc3c38722009fe6857087”},
-        {“id”: “ertwetewtwe38722009fe6857087b486531f9a779a0c1dfddgfgsdgdsgds”,
-        “checksum”: “34t23f23fc17e3ed29dae8f12c4f9e89cc6f0bsdfgfsdgdsgdsgerwgew”}]
+        [{"id": "9e89cc6f0bc3c38722009fe6857087b486531f9a779a0c17e3ed29dae8f12c4f",
+        "checksum": "b486531f9a779a0c17e3ed29dae8f12c4f9e89cc6f0bc3c38722009fe6857087"},
+        {"id": "ertwetewtwe38722009fe6857087b486531f9a779a0c1dfddgfgsdgdsgds",
+        "checksum": "34t23f23fc17e3ed29dae8f12c4f9e89cc6f0bsdfgfsdgdsgdsgerwgew"}]
 
     :statuscode 200: OK
     :statuscode 404: Not found
diff --git a/docs/sources/api/registry_api.rst b/docs/sources/api/registry_api.rst
index 58c8ff3..8803b70 100644
--- a/docs/sources/api/registry_api.rst
+++ b/docs/sources/api/registry_api.rst
@@ -6,7 +6,6 @@
 Docker Registry API
 ===================
 
-.. contents:: Table of Contents
 
 1. Brief introduction
 =====================
@@ -61,7 +60,7 @@
         Host: registry-1.docker.io
         Accept: application/json
         Content-Type: application/json
-        Authorization: Token akmklmasadalkmsdfgsdgdge33
+        Authorization: Token signature=123abc,repository="foo/bar",access=read
 
     :parameter image_id: the id for the layer you want to get
 
@@ -71,39 +70,10 @@
 
         HTTP/1.1 200
         Vary: Accept
-        Content-Type: application/json
+        X-Docker-Registry-Version: 0.6.0
         Cookie: (Cookie provided by the Registry)
 
-        {
-            id: "088b4505aa3adc3d35e79c031fa126b403200f02f51920fbd9b7c503e87c7a2c",
-            parent: "aeee6396d62273d180a49c96c62e45438d87c7da4a5cf5d2be6bee4e21bc226f",
-            created: "2013-04-30T17:46:10.843673+03:00",
-            container: "8305672a76cc5e3d168f97221106ced35a76ec7ddbb03209b0f0d96bf74f6ef7",
-            container_config: {
-                Hostname: "host-test",
-                User: "",
-                Memory: 0,
-                MemorySwap: 0,
-                AttachStdin: false,
-                AttachStdout: false,
-                AttachStderr: false,
-                PortSpecs: null,
-                Tty: false,
-                OpenStdin: false,
-                StdinOnce: false,
-                Env: null,
-                Cmd: [
-                "/bin/bash",
-                "-c",
-                "apt-get -q -yy -f install libevent-dev"
-                ],
-                Dns: null,
-                Image: "imagename/blah",
-                Volumes: { },
-                VolumesFrom: ""
-            },
-            docker_version: "0.1.7"
-        }
+        {layer binary data stream}
 
     :statuscode 200: OK
     :statuscode 401: Requires authorization
@@ -120,40 +90,10 @@
 
         PUT /v1/images/088b4505aa3adc3d35e79c031fa126b403200f02f51920fbd9b7c503e87c7a2c/layer HTTP/1.1
         Host: registry-1.docker.io
-        Accept: application/json
-        Content-Type: application/json
-        Authorization: Token akmklmasadalkmsdfgsdgdge33
+        Transfer-Encoding: chunked
+        Authorization: Token signature=123abc,repository="foo/bar",access=write
 
-        {
-            id: "088b4505aa3adc3d35e79c031fa126b403200f02f51920fbd9b7c503e87c7a2c",
-            parent: "aeee6396d62273d180a49c96c62e45438d87c7da4a5cf5d2be6bee4e21bc226f",
-            created: "2013-04-30T17:46:10.843673+03:00",
-            container: "8305672a76cc5e3d168f97221106ced35a76ec7ddbb03209b0f0d96bf74f6ef7",
-            container_config: {
-                Hostname: "host-test",
-                User: "",
-                Memory: 0,
-                MemorySwap: 0,
-                AttachStdin: false,
-                AttachStdout: false,
-                AttachStderr: false,
-                PortSpecs: null,
-                Tty: false,
-                OpenStdin: false,
-                StdinOnce: false,
-                Env: null,
-                Cmd: [
-                "/bin/bash",
-                "-c",
-                "apt-get -q -yy -f install libevent-dev"
-                ],
-                Dns: null,
-                Image: "imagename/blah",
-                Volumes: { },
-                VolumesFrom: ""
-            },
-            docker_version: "0.1.7"
-        }
+        {layer binary data stream}
 
     :parameter image_id: the id for the layer you want to get
 
@@ -165,6 +105,7 @@
         HTTP/1.1 200
         Vary: Accept
         Content-Type: application/json
+        X-Docker-Registry-Version: 0.6.0
 
         ""
 
@@ -191,13 +132,38 @@
         Cookie: (Cookie provided by the Registry)
 
         {
-         “id”: “088b4505aa3adc3d35e79c031fa126b403200f02f51920fbd9b7c503e87c7a2c”,
-         “checksum”:  “sha256:b486531f9a779a0c17e3ed29dae8f12c4f9e89cc6f0bc3c38722009fe6857087”
-         }
+            id: "088b4505aa3adc3d35e79c031fa126b403200f02f51920fbd9b7c503e87c7a2c",
+            parent: "aeee6396d62273d180a49c96c62e45438d87c7da4a5cf5d2be6bee4e21bc226f",
+            created: "2013-04-30T17:46:10.843673+03:00",
+            container: "8305672a76cc5e3d168f97221106ced35a76ec7ddbb03209b0f0d96bf74f6ef7",
+            container_config: {
+                Hostname: "host-test",
+                User: "",
+                Memory: 0,
+                MemorySwap: 0,
+                AttachStdin: false,
+                AttachStdout: false,
+                AttachStderr: false,
+                PortSpecs: null,
+                Tty: false,
+                OpenStdin: false,
+                StdinOnce: false,
+                Env: null,
+                Cmd: [
+                "/bin/bash",
+                "-c",
+                "apt-get -q -yy -f install libevent-dev"
+                ],
+                Dns: null,
+                Image: "imagename/blah",
+                Volumes: { },
+                VolumesFrom: ""
+            },
+            docker_version: "0.1.7"
+        }
 
     :parameter image_id: the id for the layer you want to get
 
-
     **Example Response**:
 
     .. sourcecode:: http
@@ -205,6 +171,7 @@
         HTTP/1.1 200
         Vary: Accept
         Content-Type: application/json
+        X-Docker-Registry-Version: 0.6.0
 
         ""
 
@@ -234,11 +201,40 @@
         HTTP/1.1 200
         Vary: Accept
         Content-Type: application/json
+        X-Docker-Registry-Version: 0.6.0
+        X-Docker-Size: 456789
+        X-Docker-Checksum: b486531f9a779a0c17e3ed29dae8f12c4f9e89cc6f0bc3c38722009fe6857087
 
         {
-         “id”: “088b4505aa3adc3d35e79c031fa126b403200f02f51920fbd9b7c503e87c7a2c”,
-         “checksum”:  “sha256:b486531f9a779a0c17e3ed29dae8f12c4f9e89cc6f0bc3c38722009fe6857087”
-         }
+            id: "088b4505aa3adc3d35e79c031fa126b403200f02f51920fbd9b7c503e87c7a2c",
+            parent: "aeee6396d62273d180a49c96c62e45438d87c7da4a5cf5d2be6bee4e21bc226f",
+            created: "2013-04-30T17:46:10.843673+03:00",
+            container: "8305672a76cc5e3d168f97221106ced35a76ec7ddbb03209b0f0d96bf74f6ef7",
+            container_config: {
+                Hostname: "host-test",
+                User: "",
+                Memory: 0,
+                MemorySwap: 0,
+                AttachStdin: false,
+                AttachStdout: false,
+                AttachStderr: false,
+                PortSpecs: null,
+                Tty: false,
+                OpenStdin: false,
+                StdinOnce: false,
+                Env: null,
+                Cmd: [
+                "/bin/bash",
+                "-c",
+                "apt-get -q -yy -f install libevent-dev"
+                ],
+                Dns: null,
+                Image: "imagename/blah",
+                Volumes: { },
+                VolumesFrom: ""
+            },
+            docker_version: "0.1.7"
+        }
 
     :statuscode 200: OK
     :statuscode 401: Requires authorization
@@ -271,6 +267,7 @@
         HTTP/1.1 200
         Vary: Accept
         Content-Type: application/json
+        X-Docker-Registry-Version: 0.6.0
 
         ["088b4502f51920fbd9b7c503e87c7a2c05aa3adc3d35e79c031fa126b403200f",
          "aeee63968d87c7da4a5cf5d2be6bee4e21bc226fd62273d180a49c96c62e4543",
@@ -297,6 +294,7 @@
         Host: registry-1.docker.io
         Accept: application/json
         Content-Type: application/json
+        X-Docker-Registry-Version: 0.6.0
         Cookie: (Cookie provided by the Registry)
 
     :parameter namespace: namespace for the repo
@@ -309,10 +307,11 @@
         HTTP/1.1 200
         Vary: Accept
         Content-Type: application/json
+        X-Docker-Registry-Version: 0.6.0
 
         {
             "latest": "9e89cc6f0bc3c38722009fe6857087b486531f9a779a0c17e3ed29dae8f12c4f",
-            “0.1.1”:  “b486531f9a779a0c17e3ed29dae8f12c4f9e89cc6f0bc3c38722009fe6857087”
+            "0.1.1":  "b486531f9a779a0c17e3ed29dae8f12c4f9e89cc6f0bc3c38722009fe6857087"
         }
 
     :statuscode 200: OK
@@ -332,6 +331,7 @@
         Host: registry-1.docker.io
         Accept: application/json
         Content-Type: application/json
+        X-Docker-Registry-Version: 0.6.0
         Cookie: (Cookie provided by the Registry)
 
     :parameter namespace: namespace for the repo
@@ -345,6 +345,7 @@
         HTTP/1.1 200
         Vary: Accept
         Content-Type: application/json
+        X-Docker-Registry-Version: 0.6.0
 
         "9e89cc6f0bc3c38722009fe6857087b486531f9a779a0c17e3ed29dae8f12c4f"
 
@@ -377,6 +378,7 @@
         HTTP/1.1 200
         Vary: Accept
         Content-Type: application/json
+        X-Docker-Registry-Version: 0.6.0
 
         ""
 
@@ -399,7 +401,7 @@
         Content-Type: application/json
         Cookie: (Cookie provided by the Registry)
 
-        “9e89cc6f0bc3c38722009fe6857087b486531f9a779a0c17e3ed29dae8f12c4f”
+        "9e89cc6f0bc3c38722009fe6857087b486531f9a779a0c17e3ed29dae8f12c4f"
 
     :parameter namespace: namespace for the repo
     :parameter repository: name for the repo
@@ -412,6 +414,7 @@
         HTTP/1.1 200
         Vary: Accept
         Content-Type: application/json
+        X-Docker-Registry-Version: 0.6.0
 
         ""
 
@@ -449,6 +452,7 @@
         HTTP/1.1 200
         Vary: Accept
         Content-Type: application/json
+        X-Docker-Registry-Version: 0.6.0
 
         ""
 
@@ -456,8 +460,41 @@
     :statuscode 401: Requires authorization
     :statuscode 404: Repository not found
 
-3.0 Authorization
-=================
+2.4 Status
+----------
+
+.. http:get:: /v1/_ping
+
+    Check status of the registry. This endpoint is also used to determine if
+    the registry supports SSL.
+
+    **Example Request**:
+
+    .. sourcecode:: http
+
+        GET /v1/_ping HTTP/1.1
+        Host: registry-1.docker.io
+        Accept: application/json
+        Content-Type: application/json
+
+        ""
+
+    **Example Response**:
+
+    .. sourcecode:: http
+
+        HTTP/1.1 200
+        Vary: Accept
+        Content-Type: application/json
+        X-Docker-Registry-Version: 0.6.0
+
+        ""
+
+    :statuscode 200: OK
+
+
+3 Authorization
+===============
 This is where we describe the authorization process, including the tokens and cookies. 
 
 TODO: add more info.
diff --git a/docs/sources/api/registry_index_spec.rst b/docs/sources/api/registry_index_spec.rst
index 4ea0c68..78b61c8 100644
--- a/docs/sources/api/registry_index_spec.rst
+++ b/docs/sources/api/registry_index_spec.rst
@@ -8,8 +8,6 @@
 Registry & Index Spec
 =====================
 
-.. contents:: Table of Contents
-
 1. The 3 roles
 ===============
 
@@ -564,8 +562,8 @@
     Cookie: session="wD/J7LqL5ctqw8haL10vgfhrb2Q=?foo=UydiYXInCnAxCi4=&timestamp=RjEzNjYzMTQ5NDcuNDc0NjQzCi4="
 
 
-7.0 Document Version
----------------------
+7 Document Version
+====================
 
 - 1.0 : May 6th 2013 : initial release 
 - 1.1 : June 1st 2013 : Added Delete Repository and way to handle new source namespace.
diff --git a/docs/sources/api/remote_api_client_libraries.rst b/docs/sources/api/remote_api_client_libraries.rst
new file mode 100644
index 0000000..bd8610e
--- /dev/null
+++ b/docs/sources/api/remote_api_client_libraries.rst
@@ -0,0 +1,37 @@
+:title: Registry API
+:description: Various client libraries available to use with the Docker remote API
+:keywords: API, Docker, index, registry, REST, documentation, clients, Python, Ruby, Javascript, Erlang, Go
+
+
+==================================
+Docker Remote API Client Libraries
+==================================
+
+These libraries have not been tested by the Docker Maintainers for
+compatibility. Please file issues with the library owners.  If you
+find more library implementations, please list them in Docker doc bugs
+and we will add the libraries here.
+
++----------------------+----------------+--------------------------------------------+
+| Language/Framework   | Name           | Repository                                 |
++======================+================+============================================+
+| Python               | docker-py      | https://github.com/dotcloud/docker-py      |
++----------------------+----------------+--------------------------------------------+
+| Ruby                 | docker-client  | https://github.com/geku/docker-client      |
++----------------------+----------------+--------------------------------------------+
+| Ruby                 | docker-api     | https://github.com/swipely/docker-api      |
++----------------------+----------------+--------------------------------------------+
+| Javascript (NodeJS)  | docker.io      | https://github.com/appersonlabs/docker.io  |
+|                      |                | Install via NPM: `npm install docker.io`   |
++----------------------+----------------+--------------------------------------------+
+| Javascript           | docker-js      | https://github.com/dgoujard/docker-js      |
++----------------------+----------------+--------------------------------------------+
+| Javascript (Angular) | dockerui       | https://github.com/crosbymichael/dockerui  |
+| **WebUI**            |                |                                            |
++----------------------+----------------+--------------------------------------------+
+| Java                 | docker-java    | https://github.com/kpelykh/docker-java     |
++----------------------+----------------+--------------------------------------------+
+| Erlang               | erldocker      | https://github.com/proger/erldocker        |
++----------------------+----------------+--------------------------------------------+
+| Go                   | go-dockerclient| https://github.com/fsouza/go-dockerclient  |
++----------------------+----------------+--------------------------------------------+
diff --git a/docs/sources/commandline/cli.rst b/docs/sources/commandline/cli.rst
index edc618b..62dd370 100644
--- a/docs/sources/commandline/cli.rst
+++ b/docs/sources/commandline/cli.rst
@@ -8,7 +8,7 @@
 ======================
 
 Docker Usage
-~~~~~~~~~~~~
+~~~~~~~~~~~~~~~~~~
 
 To list available commands, either run ``docker`` with no parameters or execute
 ``docker help``::
@@ -21,40 +21,71 @@
 
     ...
 
+
+
 Available Commands
 ~~~~~~~~~~~~~~~~~~
 
-.. toctree::
-   :maxdepth: 2
+.. include:: command/attach.rst
 
-   command/attach
-   command/build
-   command/commit
-   command/cp
-   command/diff
-   command/events
-   command/export
-   command/history
-   command/images
-   command/import
-   command/info
-   command/insert
-   command/inspect
-   command/kill
-   command/login
-   command/logs
-   command/port
-   command/ps
-   command/pull
-   command/push
-   command/restart
-   command/rm
-   command/rmi
-   command/run
-   command/search
-   command/start
-   command/stop
-   command/tag
-   command/top
-   command/version
-   command/wait
+.. include:: command/build.rst
+
+.. include:: command/commit.rst
+
+.. include:: command/cp.rst
+
+.. include:: command/diff.rst
+
+.. include:: command/events.rst
+
+.. include:: command/export.rst
+
+.. include:: command/history.rst
+
+.. include:: command/images.rst
+
+.. include:: command/import.rst
+
+.. include:: command/info.rst
+
+.. include:: command/insert.rst
+
+.. include:: command/inspect.rst
+
+.. include:: command/kill.rst
+
+.. include:: command/login.rst
+
+.. include:: command/logs.rst
+
+.. include:: command/port.rst
+
+.. include:: command/ps.rst
+
+.. include:: command/pull.rst
+
+.. include:: command/push.rst
+
+.. include:: command/restart.rst
+
+.. include:: command/rm.rst
+
+.. include:: command/rmi.rst
+
+.. include:: command/run.rst
+
+.. include:: command/search.rst
+
+.. include:: command/start.rst
+
+.. include:: command/stop.rst
+
+.. include:: command/tag.rst
+
+.. include:: command/top.rst
+
+.. include:: command/version.rst
+
+.. include:: command/wait.rst
+
+
diff --git a/docs/sources/commandline/command/images.rst b/docs/sources/commandline/command/images.rst
index ec8b9f0..279bf24 100644
--- a/docs/sources/commandline/command/images.rst
+++ b/docs/sources/commandline/command/images.rst
@@ -23,4 +23,4 @@
 
     sudo docker images -viz | dot -Tpng -o docker.png
 
-.. image:: images/docker_images.gif
+.. image:: https://docs.docker.io/en/latest/_static/docker_images.gif
diff --git a/docs/sources/commandline/command/run.rst b/docs/sources/commandline/command/run.rst
index d29e70d..b68e083 100644
--- a/docs/sources/commandline/command/run.rst
+++ b/docs/sources/commandline/command/run.rst
@@ -23,10 +23,11 @@
       -m=0: Memory limit (in bytes)
       -n=true: Enable networking for this container
       -p=[]: Map a network port to the container
+      -rm=false: Automatically remove the container when it exits (incompatible with -d)
       -t=false: Allocate a pseudo-tty
       -u="": Username or UID
       -dns=[]: Set custom dns servers for the container
-      -v=[]: Create a bind mount with: [host-dir]:[container-dir]:[rw|ro]. If "host-dir" is missing, then docker creates a new volume.
+      -v=[]: Create a bind mount with: [host-dir]:[container-dir]:[rw|ro]. If "container-dir" is missing, then docker creates a new volume.
       -volumes-from="": Mount all volumes from the given container.
       -entrypoint="": Overwrite the default entrypoint set by the image.
       -w="": Working directory inside the container
diff --git a/docs/sources/contributing/devenvironment.rst b/docs/sources/contributing/devenvironment.rst
index 8d95b7c..59f1664 100644
--- a/docs/sources/contributing/devenvironment.rst
+++ b/docs/sources/contributing/devenvironment.rst
@@ -124,7 +124,7 @@
 
 
 
-.. note:: The binary is availalbe outside the container in the directory  ``./bundles/<version>-dev/binary/``.
+.. note:: The binary is available outside the container in the directory  ``./bundles/<version>-dev/binary/``. You can swap your host docker executable with this binary for live testing - for example, on ubuntu: ``sudo service docker stop ; sudo cp $(which docker) $(which docker)_ ; sudo cp ./bundles/<version>-dev/binary/docker-<version>-dev $(which docker);sudo service docker start``.
 
 
 **Need More Help?**
diff --git a/docs/sources/examples/hello_world.rst b/docs/sources/examples/hello_world.rst
index b7204fd..647a34a 100644
--- a/docs/sources/examples/hello_world.rst
+++ b/docs/sources/examples/hello_world.rst
@@ -2,6 +2,11 @@
 :description: A simple hello world example with Docker
 :keywords: docker, example, hello world
 
+.. _examples:
+
+Hello World
+-----------
+
 .. _running_examples:
 
 Running the Examples
@@ -166,13 +171,11 @@
 The next example in the series is a :ref:`python_web_app` example, or
 you could skip to any of the other examples:
 
-.. toctree::
-   :maxdepth: 1
 
-   python_web_app
-   nodejs_web_app
-   running_redis_service
-   running_ssh_service
-   couchdb_data_volumes
-   postgresql_service
-   mongodb
+* :ref:`python_web_app`
+* :ref:`nodejs_web_app`
+* :ref:`running_redis_service`
+* :ref:`running_ssh_service`
+* :ref:`running_couchdb_service`
+* :ref:`postgresql_service`
+* :ref:`mongodb`
diff --git a/docs/sources/examples/postgresql_service.rst b/docs/sources/examples/postgresql_service.rst
index 27543ec..35bcc01 100644
--- a/docs/sources/examples/postgresql_service.rst
+++ b/docs/sources/examples/postgresql_service.rst
@@ -39,12 +39,12 @@
 
     apt-get update
 
-Install ``python-software-properies``.
+Install ``python-software-properties``.
 
 .. code-block:: bash
 
-    apt-get install python-software-properties
-    apt-get install software-properties-common
+    apt-get -y install python-software-properties
+    apt-get -y install software-properties-common
 
 Add Pitti's PostgreSQL repository. It contains the most recent stable release
 of PostgreSQL i.e. ``9.2``.
@@ -66,18 +66,19 @@
 
 .. code-block:: bash
 
-    sudo -u postgres createuser -P -d -r -s docker
+    su postgres -c "createuser -P -d -r -s docker"
 
 Create a test database also named ``docker`` owned by previously created ``docker``
 role.
 
 .. code-block:: bash
 
-    sudo -u postgres createdb -O docker docker
+    su postgres -c "createdb -O docker docker"
 
 Adjust PostgreSQL configuration so that remote connections to the
 database are possible. Make sure that inside
-``/etc/postgresql/9.2/main/pg_hba.conf`` you have following line:
+``/etc/postgresql/9.2/main/pg_hba.conf`` you have following line (you will need
+to install an editor, e.g. ``apt-get install vim``):
 
 .. code-block:: bash
 
@@ -90,9 +91,17 @@
 
     listen_addresses='*'
 
-*Note:* this PostgreSQL setup is for development only purposes. Refer
-to PostgreSQL documentation how to fine-tune these settings so that it
-is enough secure.
+.. note::
+
+    This PostgreSQL setup is for development only purposes. Refer
+    to PostgreSQL documentation how to fine-tune these settings so that it
+    is enough secure.
+
+Exit.
+
+.. code-block:: bash
+
+    exit
 
 Create an image and assign it a name. ``<container_id>`` is in the
 Bash prompt; you can also locate it using ``docker ps -a``.
@@ -111,7 +120,9 @@
         -D /var/lib/postgresql/9.2/main \
         -c config_file=/etc/postgresql/9.2/main/postgresql.conf')
 
-Connect the PostgreSQL server using ``psql``.
+Connect the PostgreSQL server using ``psql`` (You will need postgres installed
+on the machine.  For ubuntu, use something like
+``sudo apt-get install postgresql``).
 
 .. code-block:: bash
 
@@ -128,7 +139,7 @@
     docker=# CREATE DATABASE foo OWNER=docker;
     CREATE DATABASE
 
-Additionally, publish there your newly created image on Docker Index.
+Additionally, publish your newly created image on Docker Index.
 
 .. code-block:: bash
 
@@ -149,10 +160,11 @@
 
 .. code-block:: bash
 
-    sudo docker commit <container_id> <your username>/postgresql -run='{"Cmd": \
+    sudo docker commit -run='{"Cmd": \
       ["/bin/su", "postgres", "-c", "/usr/lib/postgresql/9.2/bin/postgres -D \
       /var/lib/postgresql/9.2/main -c \
-      config_file=/etc/postgresql/9.2/main/postgresql.conf"], PortSpecs": ["5432"]}
+      config_file=/etc/postgresql/9.2/main/postgresql.conf"], "PortSpecs": ["5432"]}' \
+      <container_id> <your username>/postgresql
 
 From now on, just type ``docker run <your username>/postgresql`` and
 PostgreSQL should automatically start.
diff --git a/docs/sources/index.rst b/docs/sources/index.rst
index 2800310..99d2159 100644
--- a/docs/sources/index.rst
+++ b/docs/sources/index.rst
@@ -2,7 +2,7 @@
 :description: An overview of the Docker Documentation
 :keywords: containers, lxc, concepts, explanation
 
-.. image:: static_files/dockerlogo-h.png
+.. image:: https://www.docker.io/static/img/linked/dockerlogo-horizontal.png
 
 Introduction
 ------------
diff --git a/docs/sources/installation/amazon.rst b/docs/sources/installation/amazon.rst
index 2c74b0f..c6c8104 100644
--- a/docs/sources/installation/amazon.rst
+++ b/docs/sources/installation/amazon.rst
@@ -44,10 +44,10 @@
 new instance will be blocked by the AWS Security Group, so you might
 just get timeouts when you try to connect.
 
-Installing with ``get.docker.io`` (as above) will create a service
-named ``dockerd``. You may want to set up a :ref:`docker group
-<dockergroup>` and add the *ubuntu* user to it so that you don't have
-to use ``sudo`` for every Docker command.
+Installing with ``get.docker.io`` (as above) will create a service named
+``lxc-docker``. It will also set up a :ref:`docker group <dockergroup>` and you
+may want to add the *ubuntu* user to it so that you don't have to use ``sudo``
+for every Docker command.
 
 Once you've got Docker installed, you're ready to try it out -- head
 on over to the :doc:`../use/basics` or :doc:`../examples/index` section.
diff --git a/docs/sources/installation/archlinux.rst b/docs/sources/installation/archlinux.rst
index 4f0f211..a4de066 100644
--- a/docs/sources/installation/archlinux.rst
+++ b/docs/sources/installation/archlinux.rst
@@ -80,7 +80,7 @@
 
     sysctl net.ipv4.ip_forward=1
     
-And, to make it persistent across reboots, enable it on the host's **/etc/sysctl.conf**:
+And, to make it persistent across reboots, enable it on the host's **/etc/sysctl.d/docker.conf**:
 
 ::
 
diff --git a/docs/sources/installation/gentoolinux.rst b/docs/sources/installation/gentoolinux.rst
index abfc9db..c4f2d22 100644
--- a/docs/sources/installation/gentoolinux.rst
+++ b/docs/sources/installation/gentoolinux.rst
@@ -11,59 +11,45 @@
 
 .. include:: install_unofficial.inc
 
-Installing Docker on Gentoo Linux can be accomplished by using the overlay
-provided at https://github.com/tianon/docker-overlay.  The most up-to-date
-documentation for properly installing the overlay can be found in the overlay
-README.  The information here is provided for reference, and may be out of date.
+Installing Docker on Gentoo Linux can be accomplished using one of two methods.
+The first and best way if you're looking for a stable experience is to use the
+official `app-emulation/docker` package directly in the portage tree.
+
+If you're looking for a ``-bin`` ebuild, a live ebuild, or bleeding edge
+ebuild changes/fixes, the second installation method is to use the overlay
+provided at https://github.com/tianon/docker-overlay which can be added using
+``app-portage/layman``. The most accurate and up-to-date documentation for
+properly installing and using the overlay can be found in `the overlay README
+<https://github.com/tianon/docker-overlay/blob/master/README.md#using-this-overlay>`_.
 
 Installation
 ^^^^^^^^^^^^
 
-Ensure that layman is installed:
-
-.. code-block:: bash
-
-   sudo emerge -av app-portage/layman
-
-Add the "docker" overlay using layman:
-
-.. code-block:: bash
-
-   sudo layman -a docker
-
-Once that completes, the ``app-emulation/docker`` package will be available
-for emerge:
+The package should properly pull in all the necessary dependencies and prompt
+for all necessary kernel options.  For the most straightforward installation
+experience, use ``sys-kernel/aufs-sources`` as your kernel sources.  If you
+prefer not to use ``sys-kernel/aufs-sources``, the portage tree also contains
+``sys-fs/aufs3``, which includes the patches necessary for adding AUFS support
+to other kernel source packages such as ``sys-kernel/gentoo-sources`` (and a
+``kernel-patch`` USE flag to perform the patching to ``/usr/src/linux``
+automatically).
 
 .. code-block:: bash
 
    sudo emerge -av app-emulation/docker
 
-If you prefer to use the official binaries, or just do not wish to compile
-docker, emerge ``app-emulation/docker-bin`` instead.  It is important to
-remember that Gentoo is still an unofficial platform, even when using the
-official binaries.
-
-The package should already include all the necessary dependencies.  For the
-simplest installation experience, use ``sys-kernel/aufs-sources`` directly as
-your kernel sources.  If you prefer not to use ``sys-kernel/aufs-sources``, the
-portage tree also contains ``sys-fs/aufs3``, which contains the patches
-necessary for adding AUFS support to other kernel source packages (and a
-``kernel-patch`` use flag to perform the patching automatically).
-
-Between ``app-emulation/lxc`` and ``app-emulation/docker``, all the
-necessary kernel configuration flags should be checked for and warned about in
-the standard manner.
-
 If any issues arise from this ebuild or the resulting binary, including and
 especially missing kernel configuration flags and/or dependencies, `open an
-issue <https://github.com/tianon/docker-overlay/issues>`_ on the docker-overlay
-repository or ping tianon in the #docker IRC channel.
+issue on the docker-overlay repository
+<https://github.com/tianon/docker-overlay/issues>`_ or ping tianon directly in
+the #docker IRC channel on the freenode network.
 
 Starting Docker
 ^^^^^^^^^^^^^^^
 
-Ensure that you are running a kernel that includes the necessary AUFS support
-and includes all the necessary modules and/or configuration for LXC.
+Ensure that you are running a kernel that includes the necessary AUFS
+patches/support and includes all the necessary modules and/or configuration for
+LXC.
 
 OpenRC
 ------
@@ -110,16 +96,3 @@
 .. code-block:: bash
 
    echo net.ipv4.ip_forward = 1 | sudo tee /etc/sysctl.d/docker.conf
-
-fork/exec /usr/sbin/lxc-start: operation not permitted
-^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-
-Unfortunately, Gentoo suffers from `issue #1422
-<https://github.com/dotcloud/docker/issues/1422>`_, meaning that after every
-fresh start of docker, the first docker run fails due to some tricky terminal
-issues, so be sure to run something trivial (such as ``docker run -i -t busybox
-echo hi``) before attempting to run anything important.
-
-There is a tentative (and very hacky) workaround for this in the OpenRC init
-script, and it can be enabled by modifying the appropriate value in
-``/etc/conf.d/docker`` after successful installation.
diff --git a/docs/sources/installation/ubuntulinux.rst b/docs/sources/installation/ubuntulinux.rst
index 4444c7f..e653f70 100644
--- a/docs/sources/installation/ubuntulinux.rst
+++ b/docs/sources/installation/ubuntulinux.rst
@@ -75,7 +75,7 @@
 
    # Add the Docker repository key to your local keychain
    # using apt-key finger you can check the fingerprint matches 36A1 D786 9245 C895 0F96 6E92 D857 6A8B A88D 21E9
-   sudo sh -c "curl https://get.docker.io/gpg | apt-key add -"
+   sudo sh -c "wget -qO- https://get.docker.io/gpg | apt-key add -"
 
    # Add the Docker repository to your apt sources list.
    sudo sh -c "echo deb http://get.docker.io/ubuntu docker main > /etc/apt/sources.list.d/docker.list"
@@ -129,7 +129,7 @@
 
    # Add the Docker repository key to your local keychain
    # using apt-key finger you can check the fingerprint matches 36A1 D786 9245 C895 0F96 6E92 D857 6A8B A88D 21E9
-   sudo sh -c "curl https://get.docker.io/gpg | apt-key add -"
+   sudo sh -c "wget -qO- https://get.docker.io/gpg | apt-key add -"
 
    # Add the Docker repository to your apt sources list.
    sudo sh -c "echo deb http://get.docker.io/ubuntu docker main > /etc/apt/sources.list.d/docker.list"
diff --git a/docs/sources/installation/upgrading.rst b/docs/sources/installation/upgrading.rst
index 4748231..ac4170d 100644
--- a/docs/sources/installation/upgrading.rst
+++ b/docs/sources/installation/upgrading.rst
@@ -53,13 +53,10 @@
 .. code-block:: bash
 
    # get the latest binary
-   wget http://get.docker.io/builds/Linux/x86_64/docker-latest.tgz
-
-
-.. code-block:: bash
-
-   # Unpack it to your current dir
-   tar -xf docker-latest.tgz
+   wget http://get.docker.io/builds/Linux/x86_64/docker-latest -O docker
+   
+   # make it executable
+   chmod +x docker
 
 
 Start docker in daemon mode (``-d``) and disconnect, running the
@@ -73,4 +70,4 @@
    sudo ./docker -d &
 
 
-Alternatively you can replace the docker binary in ``/usr/local/bin``
+Alternatively you can replace the docker binary in ``/usr/local/bin``.
diff --git a/docs/sources/installation/vagrant.rst b/docs/sources/installation/vagrant.rst
index 3d7faf5..94efcb0 100644
--- a/docs/sources/installation/vagrant.rst
+++ b/docs/sources/installation/vagrant.rst
@@ -53,9 +53,7 @@
 
    * Download the 'official' Precise64 base ubuntu virtual machine image from vagrantup.com
    * Boot this image in virtualbox
-   * Add the `Docker PPA sources <https://launchpad.net/~dotcloud/+archive/lxc-docker>`_ to /etc/apt/sources.lst
-   * Update your sources
-   * Install lxc-docker
+   * Follow official :ref:`ubuntu_linux` installation path
 
    You now have a Ubuntu Virtual Machine running with docker pre-installed.
 
diff --git a/docs/sources/commandline/command/images/docker_images.gif b/docs/sources/static_files/docker_images.gif
similarity index 100%
rename from docs/sources/commandline/command/images/docker_images.gif
rename to docs/sources/static_files/docker_images.gif
Binary files differ
diff --git a/docs/sources/toctree.rst b/docs/sources/toctree.rst
index 647257a..c7c368a 100644
--- a/docs/sources/toctree.rst
+++ b/docs/sources/toctree.rst
@@ -8,7 +8,7 @@
 This documentation has the following resources:
 
 .. toctree::
-   :titlesonly:
+   :maxdepth: 1
 
    Introduction <index>
    installation/index
diff --git a/docs/sources/use/baseimages.rst b/docs/sources/use/baseimages.rst
index d7aef9c..fa5c47b 100644
--- a/docs/sources/use/baseimages.rst
+++ b/docs/sources/use/baseimages.rst
@@ -27,7 +27,7 @@
   $ sudo debootstrap raring raring > /dev/null
   $ sudo tar -C raring -c . | sudo docker import - raring
   a29c15f1bf7a
-  $ sudo docker run raring cat /etc/lsb-release                     
+  $ sudo docker run raring cat /etc/lsb-release
   DISTRIB_ID=Ubuntu
   DISTRIB_RELEASE=13.04
   DISTRIB_CODENAME=raring
@@ -37,5 +37,7 @@
 Docker Github Repo:
 
 * `BusyBox <https://github.com/dotcloud/docker/blob/master/contrib/mkimage-busybox.sh>`_
-* `Debian
+* `CentOS
+  <https://github.com/dotcloud/docker/blob/master/contrib/mkimage-centos.sh>`_
+* `Debian/Ubuntu
   <https://github.com/dotcloud/docker/blob/master/contrib/mkimage-debian.sh>`_
diff --git a/docs/sources/use/builder.rst b/docs/sources/use/builder.rst
index 61c7fcc..7a356f8 100644
--- a/docs/sources/use/builder.rst
+++ b/docs/sources/use/builder.rst
@@ -54,8 +54,14 @@
 first instruction must be `FROM`** in order to specify the
 :ref:`base_image_def` from which you are building.
 
-Docker will ignore **comment lines** *beginning* with ``#``. A comment
-marker anywhere in the rest of the line will be treated as an argument.
+Docker will treat lines that *begin* with ``#`` as a comment. A ``#``
+marker anywhere else in the line will be treated as an argument. This
+allows statements like:
+
+::
+
+    # Comment
+    RUN echo 'we are running some # of cool things'
 
 3. Instructions
 ===============
@@ -226,10 +232,10 @@
   with conflicts resolved in favor of 2) on a file-by-file basis.
 
 * If ``<src>`` is any other kind of file, it is copied individually
-  along with its metadata. In this case, if ``<dst>`` ends with a
+  along with its metadata. In this case, if ``<dest>`` ends with a
   trailing slash ``/``, it will be considered a directory and the
-  contents of ``<src>`` will be written at ``<dst>/base(<src>)``.
-* If ``<dst>`` does not end with a trailing slash, it will be
+  contents of ``<src>`` will be written at ``<dest>/base(<src>)``.
+* If ``<dest>`` does not end with a trailing slash, it will be
   considered a regular file and the contents of ``<src>`` will be
   written at ``<dst>``.
 * If ``<dest>`` doesn't exist, it is created along with all missing
@@ -321,7 +327,7 @@
     # VERSION               0.0.1
 
     FROM      ubuntu
-    MAINTAINER Guillaume J. Charmes "guillaume@dotcloud.com"
+    MAINTAINER Guillaume J. Charmes <guillaume@dotcloud.com>
 
     # make sure the package repository is up to date
     RUN echo "deb http://archive.ubuntu.com/ubuntu precise main universe" > /etc/apt/sources.list
diff --git a/docs/sources/use/workingwithrepository.rst b/docs/sources/use/workingwithrepository.rst
index a0d4601..66b2928 100644
--- a/docs/sources/use/workingwithrepository.rst
+++ b/docs/sources/use/workingwithrepository.rst
@@ -176,3 +176,30 @@
 **not** be searchable (or indexed at all) in the Central Index, and
 there will be no user name checking performed. Your registry will
 function completely independently from the Central Index.
+
+Authentication file
+-------------------
+
+The authentication is stored in a json file, ``.dockercfg`` located in your
+home directory. It supports multiple registry urls.
+
+``docker login`` will create the "https://index.docker.io/v1/" key.
+
+``docker login https://my-registry.com`` will create the "https://my-registry.com" key.
+
+For example:
+
+.. code-block:: json
+
+   {
+	"https://index.docker.io/v1/": {
+		"auth": "xXxXxXxXxXx=",
+		"email": "email@example.com"
+	},
+	"https://my-registry.com": {
+		"auth": "XxXxXxXxXxX=",
+		"email": "email@my-registry.com"
+	}
+   }
+
+The ``auth`` field represents ``base64(<username>:<password>)``
diff --git a/docs/theme/docker/layout.html b/docs/theme/docker/layout.html
index 9e44947..e415e97 100755
--- a/docs/theme/docker/layout.html
+++ b/docs/theme/docker/layout.html
@@ -1,51 +1,47 @@
 <!DOCTYPE html>
-<!--[if lt IE 7]>      <html class="no-js lt-ie9 lt-ie8 lt-ie7"> <![endif]-->
-<!--[if IE 7]>         <html class="no-js lt-ie9 lt-ie8"> <![endif]-->
-<!--[if IE 8]>         <html class="no-js lt-ie9"> <![endif]-->
-<!--[if gt IE 8]><!--> <html class="no-js"> <!--<![endif]-->
 <head>
     <meta charset="utf-8">
-    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
-    <meta name="viewport" content="width=device-width, initial-scale=1.0">
+    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
     <meta name="google-site-verification" content="UxV66EKuPe87dgnH1sbrldrx6VsoWMrx5NjwkgUFxXI" />
-
     <title>{{ meta['title'] if meta and meta['title'] else title }} - Docker Documentation</title>
-
     <meta name="description" content="{{ meta['description'] if meta }}" />
     <meta name="keywords" content="{{ meta['keywords'] if meta }}" />
+    <!-- Swiftype tags: https://swiftype.com/documentation/meta_tags -->
+    <meta property='st:popularity' content='4' />
+    <meta property='st:type' content='docker_doc' />
 
     {%- set url_root = pathto('', 1) %}
     {%- if url_root == '#' %}{% set url_root = '' %}{% endif %}
 
     <script type="text/javascript">
-        // This is probably used by the search engine
-        var DOCUMENTATION_OPTIONS = {
-            URL_ROOT:    '{{ url_root }}',
-            VERSION:     '{{ release|e }}',
-            COLLAPSE_INDEX: false,
-            FILE_SUFFIX: '{{ '' if no_search_suffix else file_suffix }}',
-            HAS_SOURCE:  {{ has_source|lower }}
-        };
+        // This is included here for Javascript that doesn't have access to the templates.
+        var doc_version = "{{ current_version }}";
+        var doc_slug = "{{ slug }}";
     </script>
 
     {%- set css_files = css_files + ['_static/css/bootstrap.css'] %}
-    {%- set css_files = css_files + ['_static/css/bootstrap-responsive.css'] %}
     {%- set css_files = css_files + ['_static/pygments.css'] %}
     {%- set css_files = css_files + ['_static/css/main.css'] %}
 
     {%- set script_files =
-    ['https://ajax.googleapis.com/ajax/libs/jquery/1.5.1/jquery.js']
-    + ['https://ajax.googleapis.com/ajax/libs/jqueryui/1.8.12/jquery-ui.min.js']
-    + script_files
+    ['//code.jquery.com/jquery-1.10.1.min.js']
+    + ['//fonts.googleapis.com/css?family=Cabin:400,700,400italic']
     %}
 
-    {%- set script_files = script_files + ['_static/js/docs.js'] %}
+    {#
+        This part is hopefully complex because things like |cut '/index/' are not available in spinx jinja
+        and will make it crash. (and we need index/ out.
+    #}
+    <link rel="canonical" href="http://docs.docker.io/en/latest/
+    {%- for word in pagename.split('/') -%}
+        {%- if word != 'index' -%}
+            {%- if word != '' -%}
+                {{ word }}/
+            {%- endif -%}
+        {%- endif -%}
+    {%- endfor -%}
+    ">
 
-    {%- if pagename == 'index' %}
-    <link rel="canonical" href="http://docs.docker.io/en/latest/">
-    {% else %}
-    <link rel="canonical" href="http://docs.docker.io/en/latest/{{ pagename }}/">
-    {% endif %}
     {%- for cssfile in css_files %}
     <link rel="stylesheet" href="{{ pathto(cssfile, 1) }}" type="text/css" />
     {%- endfor %}
@@ -53,19 +49,17 @@
     {%- for scriptfile in script_files if scriptfile != '_static/jquery.js' %}
     <script type="text/javascript" src="{{ pathto(scriptfile, 1) }}"></script>
     {%- endfor %}
-
     <link rel="shortcut icon" href="{{ pathto('_static/favicon.png', 1) }}"/>
-
-
     {%- block extrahead %}{% endblock %}
 
 </head>
 
 <body>
 
-<div class="navbar navbar-fixed-top">
+<div id="wrap">
+<div class="navbar navbar-static-top navbar-inner navbar-fixed-top ">
     <div class="navbar-dotcloud">
-        <div class="container" style="text-align: center;">
+        <div class="container">
 
             <div style="float: right" class="pull-right">
                 <ul class="nav">
@@ -75,49 +69,37 @@
                     <li id="nav-community"><a href="http://www.docker.io/community/" title="Community">Community</a></li>
                     <li id="nav-documentation" class="active"><a href="http://docs.docker.io/en/latest/">Documentation</a></li>
                     <li id="nav-blog"><a href="http://blog.docker.io/" title="Docker Blog">Blog</a></li>
-                    <li id="nav-index"><a href="http://index.docker.io/" title="Docker Image Index, find images here">INDEX <img class="inline-icon" src="{{ pathto('_static/img/external-link-icon.png', 1) }}" title="external link"> </a></li>
+                    <li id="nav-index"><a href="http://index.docker.io/" title="Docker Image Index, find images here">INDEX <img class="inline-icon" alt="link to external site" src="{{ pathto('_static/img/external-link-icon.png', 1) }}" title="external link"> </a></li>
                 </ul>
             </div>
 
-            <div style="margin-left: -12px; float: left;">
-                <a href="http://www.docker.io" title="Docker Homepage"><img style="margin-top: 0px; height: 60px; width: 160px; margin-left: 10px;" src="{{ pathto('_static/img/docker-top-logo.png', 1) }}"></a>
+            <div class="brand-logo">
+                <a href="http://www.docker.io" title="Docker Homepage"><img src="{{ pathto('_static/img/docker-top-logo.png', 1) }}" alt="Docker logo"></a>
             </div>
         </div>
-
-
     </div>
 </div>
 
-
-<div class="container">
-    <div class="row">
-        <div class="span12 titlebar">
-            <!--<span class="pull-right" style="margin-left: 20px; font-size: 20px">{{version}}</span>-->
-            <div class="pull-right" id="fork-us" style="margin-top: 16px; margin-right: 16px;">
-                <a  href="https://github.com/dotcloud/docker/blob/master/docs/sources/{{ pagename }}.rst"><img src="{{ pathto('_static/img/fork-us.png', 1) }}"> Edit this page on Github</a>
-            </div>
-            <h1 class="pageheader"><a href="http://docs.docker.io/en/latest/" title="Documentation" style="color: white;">DOCUMENTATION</a></h1>
-
-        </div>
-    </div>
-
-</div>
-
 <div class="container">
 
     <!-- Docs nav
      ================================================== -->
-    <div class="row" style="position: relative">
+    <div class="row main-row">
 
         <div class="span3 sidebar bs-docs-sidebar">
+            <div class="page-title" >
+                <h4>DOCUMENTATION</h4>
+            </div>
+            
             {{ toctree(collapse=False, maxdepth=3) }}
 	    <form>
 	      <input type="text" id="st-search-input" class="st-search-input span3" style="width:160px;" />
+          <div id="st-results-container"></div>
 	    </form>
         </div>
 
         <!-- body block -->
-        <div class="span9">
+        <div class="span9 main-content">
 
             <!-- Main section
             ================================================== -->
@@ -125,167 +107,100 @@
                 {% block body %}{% endblock %}
             </section>
 
-	    <!-- Swiftype search -->
-	    <div id="st-results-container"></div>
-	    <script type="text/javascript">
-	      var Swiftype = window.Swiftype || {};
-	      (function() {
-	      Swiftype.key = 'pWPnnyvwcfpcrw1o51Sz';
-	      Swiftype.inputElement = '#st-search-input';
-	      Swiftype.resultContainingElement = '#st-results-container';
-	      Swiftype.attachElement = '#st-search-input';
-	      Swiftype.renderStyle = "overlay";
-
-	      var script = document.createElement('script');
-	      script.type = 'text/javascript';
-	      script.async = true;
-	      script.src = "//swiftype.com/embed.js";
-	      var entry = document.getElementsByTagName('script')[0];
-	      entry.parentNode.insertBefore(script, entry);
-	      }());
-	    </script>
-
+            <div class="pull-right"><a href="https://github.com/dotcloud/docker/blob/{{ current_version }}/docs/sources/{{ pagename }}.rst" title="edit this article">Edit this article on GitHub</a></div>
         </div>
     </div>
 </div>
 
-<div id="footer" class="container" >
-    <div class="row">
+<div id="push-the-footer"></div>
+</div> <!-- end wrap for pushing footer -->
 
-        <div class="span12 footer">
-            <div class="tbox textright forceleftmargin social links pull-right">
-                <a class="twitter" href="http://twitter.com/docker">Twitter</a>
-                <a class="github" href="https://github.com/dotcloud/docker/">GitHub</a>
+<div id="footer">
+    <div class="footer-landscape">
+        <div class="footer-landscape-image">
+            <!-- footer -->
+            <div class="container">
+                <div class="row footer">
+                    <div class="span12 tbox">
+                        <div class="tbox">
+                            <p>Docker is an open source project, sponsored by  <a href="https://dotcloud.com">dotCloud</a>, under the <a href="https://github.com/dotcloud/docker/blob/master/LICENSE" title="Docker licence, hosted in the Github repository">apache 2.0 licence</a></p>
+                        </div>
+
+                        <div class="social links">
+                            <a class="twitter" href="http://twitter.com/docker">Twitter</a>
+                            <a class="github" href="https://github.com/dotcloud/docker/">GitHub</a>
+                        </div>
+
+                        <div class="tbox version-flyer ">
+                            <div class="content">
+                                <small>Current version:</small>
+                                <ul class="inline">
+                                    {% for slug, url in versions %}
+                                    <li class="alternative"><a href="{{ url }}{%- for word in pagename.split('/') -%}
+                                        {%- if word != 'index' -%}
+                                            {%- if word != '' -%}
+                                                {{ word }}/
+                                            {%- endif -%}
+                                        {%- endif -%}
+                                    {%- endfor -%}"
+                                    title="Switch to {{ slug }}">{{ slug }}</a></li>
+                                    {% endfor %}
+                                </ul>
+                            </div>
+                        </div>
+
+
+                    </div>
+                </div>
             </div>
-
-            Docker is a project by <a href="http://www.dotcloud.com">dotCloud</a>
-
-
-{#            {%- if show_source and has_source and sourcename %}#}
-{#            ·#}
-{#            <a href="{{ pathto('_sources/' + sourcename, true)|e }}"#}
-{#               rel="nofollow">View the RST source of this page</a>#}
-{#            {%- endif %}#}
-{#            {%- if pagename != "search" %}#}
-
-{#TODO: Make a proper location for the search #}
-{#            Search:#}
-{#            <form#}
-{#                    style="display: inline;"#}
-{#                    class="search" action="{{ pathto('search') }}" method="get">#}
-{#                <input type="text" name="q" size="18" />#}
-{#                <input type="hidden" name="check_keywords" value="yes" />#}
-{#                <input type="hidden" name="area" value="default" />#}
-{#            </form>#}
-{#            {%- endif %}#}
-
-
         </div>
+        <!-- end of footer -->
     </div>
 </div>
 
 
-  <!-- script which should be loaded after everything else -->
+<script type="text/javascript" src="{{ pathto('_static/js/docs.js', 1) }}"></script>
+
+<!-- Swiftype search -->
+
 <script type="text/javascript">
+  var Swiftype = window.Swiftype || {};
+  (function() {
+  Swiftype.key = 'pWPnnyvwcfpcrw1o51Sz';
+  Swiftype.inputElement = '#st-search-input';
+  Swiftype.resultContainingElement = '#st-results-container';
+  Swiftype.attachElement = '#st-search-input';
+  Swiftype.renderStyle = "overlay";
+  // from https://swiftype.com/questions/how-can-i-make-more-popular-content-rank-higher 
+  // Use "page" for now -- they don't subgroup by document type yet.
+  Swiftype.searchFunctionalBoosts = {"page": {"popularity": "linear"}};
 
-    // Function to make the sticky header possible
-    var shiftWindow = function() {
-        scrollBy(0, -70);
-        console.log("window shifted")
-    };
-    window.addEventListener("hashchange", shiftWindow);
-
-    function loadShift() {
-        if (window.location.hash) {
-            console.log("window has hash");
-            shiftWindow();
-        }
-    }
-
-    $(window).load(function() {
-        loadShift();
-        console.log("late loadshift");
-    });
-
-    $(function(){
-
-        // sidebar accordian-ing
-        // don't apply on last object (it should be the FAQ)
-
-        // define an array to which all opened items should be added
-        var openmenus = [];
-
-        var elements = $('.toctree-l2');
-        for (var i = 0; i < elements.length; i += 1) { var current = $(elements[i]); current.children('ul').hide();}
-
-
-        // set initial collapsed state
-        var elements = $('.toctree-l1');
-        for (var i = 0; i < elements.length; i += 1) {
-            var current = $(elements[i]);
-            if (current.hasClass('current')) {
-
-                currentlink = current.children('a')[0].href;
-                openmenus.push(currentlink);
-
-                // do nothing
-            } else {
-                // collapse children
-                current.children('ul').hide();
-            }
-        }
-
-        // attached handler on click
-        // Do not attach to first element or last (intro, faq) so that
-        // first and last link directly instead of accordian
-        $('.sidebar > ul > li > a').not(':last').not(':first').click(function(){
-
-            var index = $.inArray(this.href, openmenus)
-
-            if (index > -1) {
-                console.log(index);
-                openmenus.splice(index, 1);
-
-
-                $(this).parent().children('ul').slideUp(200, function() {
-                    // $(this).parent().removeClass('current'); // toggle after effect
-                });
-            }
-            else {
-                openmenus.push(this.href);
-                console.log(this);
-
-                var current = $(this);
-
-                setTimeout(function() {
-                    $('.sidebar > ul > li').removeClass('current');
-                    current.parent().addClass('current'); // toggle before effect
-                    current.parent().children('ul').hide();
-                    current.parent().children('ul').slideDown(200);
-                }, 100);
-            }
-            return false;
-        });
-
-    });
+  var script = document.createElement('script');
+  script.type = 'text/javascript';
+  script.async = true;
+  script.src = "//swiftype.com/embed.js";
+  var entry = document.getElementsByTagName('script')[0];
+  entry.parentNode.insertBefore(script, entry);
+  }());
 </script>
 
-    <!-- Google analytics -->
-    <script type="text/javascript">
 
-        var _gaq = _gaq || [];
-        _gaq.push(['_setAccount', 'UA-6096819-11']);
-        _gaq.push(['_setDomainName', 'docker.io']);
-        _gaq.push(['_setAllowLinker', true]);
-        _gaq.push(['_trackPageview']);
+<!-- Google analytics -->
+<script type="text/javascript">
 
-        (function() {
-            var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
-            ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
-            var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
-        })();
+    var _gaq = _gaq || [];
+    _gaq.push(['_setAccount', 'UA-6096819-11']);
+    _gaq.push(['_setDomainName', 'docker.io']);
+    _gaq.push(['_setAllowLinker', true]);
+    _gaq.push(['_trackPageview']);
 
-    </script>
+    (function() {
+        var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
+        ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
+        var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
+    })();
+
+</script>
 
 </body>
 </html>
diff --git a/docs/theme/docker/static/css/bootstrap-responsive.css b/docs/theme/docker/static/css/bootstrap-responsive.css
deleted file mode 100755
index 5215a5d..0000000
--- a/docs/theme/docker/static/css/bootstrap-responsive.css
+++ /dev/null
@@ -1,1109 +0,0 @@
-/*!
- * Bootstrap Responsive v2.3.0
- *
- * Copyright 2012 Twitter, Inc
- * Licensed under the Apache License v2.0
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Designed and built with all the love in the world @twitter by @mdo and @fat.
- */
-
-.clearfix {
-  *zoom: 1;
-}
-
-.clearfix:before,
-.clearfix:after {
-  display: table;
-  line-height: 0;
-  content: "";
-}
-
-.clearfix:after {
-  clear: both;
-}
-
-.hide-text {
-  font: 0/0 a;
-  color: transparent;
-  text-shadow: none;
-  background-color: transparent;
-  border: 0;
-}
-
-.input-block-level {
-  display: block;
-  width: 100%;
-  min-height: 30px;
-  -webkit-box-sizing: border-box;
-     -moz-box-sizing: border-box;
-          box-sizing: border-box;
-}
-
-@-ms-viewport {
-  width: device-width;
-}
-
-.hidden {
-  display: none;
-  visibility: hidden;
-}
-
-.visible-phone {
-  display: none !important;
-}
-
-.visible-tablet {
-  display: none !important;
-}
-
-.hidden-desktop {
-  display: none !important;
-}
-
-.visible-desktop {
-  display: inherit !important;
-}
-
-@media (min-width: 768px) and (max-width: 979px) {
-  .hidden-desktop {
-    display: inherit !important;
-  }
-  .visible-desktop {
-    display: none !important ;
-  }
-  .visible-tablet {
-    display: inherit !important;
-  }
-  .hidden-tablet {
-    display: none !important;
-  }
-}
-
-@media (max-width: 767px) {
-  .hidden-desktop {
-    display: inherit !important;
-  }
-  .visible-desktop {
-    display: none !important;
-  }
-  .visible-phone {
-    display: inherit !important;
-  }
-  .hidden-phone {
-    display: none !important;
-  }
-}
-
-.visible-print {
-  display: none !important;
-}
-
-@media print {
-  .visible-print {
-    display: inherit !important;
-  }
-  .hidden-print {
-    display: none !important;
-  }
-}
-
-@media (min-width: 1200px) {
-  .row {
-    margin-left: -30px;
-    *zoom: 1;
-  }
-  .row:before,
-  .row:after {
-    display: table;
-    line-height: 0;
-    content: "";
-  }
-  .row:after {
-    clear: both;
-  }
-  [class*="span"] {
-    float: left;
-    min-height: 1px;
-    margin-left: 30px;
-  }
-  .container,
-  .navbar-static-top .container,
-  .navbar-fixed-top .container,
-  .navbar-fixed-bottom .container {
-    width: 1170px;
-  }
-  .span12 {
-    width: 1170px;
-  }
-  .span11 {
-    width: 1070px;
-  }
-  .span10 {
-    width: 970px;
-  }
-  .span9 {
-    width: 870px;
-  }
-  .span8 {
-    width: 770px;
-  }
-  .span7 {
-    width: 670px;
-  }
-  .span6 {
-    width: 570px;
-  }
-  .span5 {
-    width: 470px;
-  }
-  .span4 {
-    width: 370px;
-  }
-  .span3 {
-    width: 270px;
-  }
-  .span2 {
-    width: 170px;
-  }
-  .span1 {
-    width: 70px;
-  }
-  .offset12 {
-    margin-left: 1230px;
-  }
-  .offset11 {
-    margin-left: 1130px;
-  }
-  .offset10 {
-    margin-left: 1030px;
-  }
-  .offset9 {
-    margin-left: 930px;
-  }
-  .offset8 {
-    margin-left: 830px;
-  }
-  .offset7 {
-    margin-left: 730px;
-  }
-  .offset6 {
-    margin-left: 630px;
-  }
-  .offset5 {
-    margin-left: 530px;
-  }
-  .offset4 {
-    margin-left: 430px;
-  }
-  .offset3 {
-    margin-left: 330px;
-  }
-  .offset2 {
-    margin-left: 230px;
-  }
-  .offset1 {
-    margin-left: 130px;
-  }
-  .row-fluid {
-    width: 100%;
-    *zoom: 1;
-  }
-  .row-fluid:before,
-  .row-fluid:after {
-    display: table;
-    line-height: 0;
-    content: "";
-  }
-  .row-fluid:after {
-    clear: both;
-  }
-  .row-fluid [class*="span"] {
-    display: block;
-    float: left;
-    width: 100%;
-    min-height: 30px;
-    margin-left: 2.564102564102564%;
-    *margin-left: 2.5109110747408616%;
-    -webkit-box-sizing: border-box;
-       -moz-box-sizing: border-box;
-            box-sizing: border-box;
-  }
-  .row-fluid [class*="span"]:first-child {
-    margin-left: 0;
-  }
-  .row-fluid .controls-row [class*="span"] + [class*="span"] {
-    margin-left: 2.564102564102564%;
-  }
-  .row-fluid .span12 {
-    width: 100%;
-    *width: 99.94680851063829%;
-  }
-  .row-fluid .span11 {
-    width: 91.45299145299145%;
-    *width: 91.39979996362975%;
-  }
-  .row-fluid .span10 {
-    width: 82.90598290598291%;
-    *width: 82.8527914166212%;
-  }
-  .row-fluid .span9 {
-    width: 74.35897435897436%;
-    *width: 74.30578286961266%;
-  }
-  .row-fluid .span8 {
-    width: 65.81196581196582%;
-    *width: 65.75877432260411%;
-  }
-  .row-fluid .span7 {
-    width: 57.26495726495726%;
-    *width: 57.21176577559556%;
-  }
-  .row-fluid .span6 {
-    width: 48.717948717948715%;
-    *width: 48.664757228587014%;
-  }
-  .row-fluid .span5 {
-    width: 40.17094017094017%;
-    *width: 40.11774868157847%;
-  }
-  .row-fluid .span4 {
-    width: 31.623931623931625%;
-    *width: 31.570740134569924%;
-  }
-  .row-fluid .span3 {
-    width: 23.076923076923077%;
-    *width: 23.023731587561375%;
-  }
-  .row-fluid .span2 {
-    width: 14.52991452991453%;
-    *width: 14.476723040552828%;
-  }
-  .row-fluid .span1 {
-    width: 5.982905982905983%;
-    *width: 5.929714493544281%;
-  }
-  .row-fluid .offset12 {
-    margin-left: 105.12820512820512%;
-    *margin-left: 105.02182214948171%;
-  }
-  .row-fluid .offset12:first-child {
-    margin-left: 102.56410256410257%;
-    *margin-left: 102.45771958537915%;
-  }
-  .row-fluid .offset11 {
-    margin-left: 96.58119658119658%;
-    *margin-left: 96.47481360247316%;
-  }
-  .row-fluid .offset11:first-child {
-    margin-left: 94.01709401709402%;
-    *margin-left: 93.91071103837061%;
-  }
-  .row-fluid .offset10 {
-    margin-left: 88.03418803418803%;
-    *margin-left: 87.92780505546462%;
-  }
-  .row-fluid .offset10:first-child {
-    margin-left: 85.47008547008548%;
-    *margin-left: 85.36370249136206%;
-  }
-  .row-fluid .offset9 {
-    margin-left: 79.48717948717949%;
-    *margin-left: 79.38079650845607%;
-  }
-  .row-fluid .offset9:first-child {
-    margin-left: 76.92307692307693%;
-    *margin-left: 76.81669394435352%;
-  }
-  .row-fluid .offset8 {
-    margin-left: 70.94017094017094%;
-    *margin-left: 70.83378796144753%;
-  }
-  .row-fluid .offset8:first-child {
-    margin-left: 68.37606837606839%;
-    *margin-left: 68.26968539734497%;
-  }
-  .row-fluid .offset7 {
-    margin-left: 62.393162393162385%;
-    *margin-left: 62.28677941443899%;
-  }
-  .row-fluid .offset7:first-child {
-    margin-left: 59.82905982905982%;
-    *margin-left: 59.72267685033642%;
-  }
-  .row-fluid .offset6 {
-    margin-left: 53.84615384615384%;
-    *margin-left: 53.739770867430444%;
-  }
-  .row-fluid .offset6:first-child {
-    margin-left: 51.28205128205128%;
-    *margin-left: 51.175668303327875%;
-  }
-  .row-fluid .offset5 {
-    margin-left: 45.299145299145295%;
-    *margin-left: 45.1927623204219%;
-  }
-  .row-fluid .offset5:first-child {
-    margin-left: 42.73504273504273%;
-    *margin-left: 42.62865975631933%;
-  }
-  .row-fluid .offset4 {
-    margin-left: 36.75213675213675%;
-    *margin-left: 36.645753773413354%;
-  }
-  .row-fluid .offset4:first-child {
-    margin-left: 34.18803418803419%;
-    *margin-left: 34.081651209310785%;
-  }
-  .row-fluid .offset3 {
-    margin-left: 28.205128205128204%;
-    *margin-left: 28.0987452264048%;
-  }
-  .row-fluid .offset3:first-child {
-    margin-left: 25.641025641025642%;
-    *margin-left: 25.53464266230224%;
-  }
-  .row-fluid .offset2 {
-    margin-left: 19.65811965811966%;
-    *margin-left: 19.551736679396257%;
-  }
-  .row-fluid .offset2:first-child {
-    margin-left: 17.094017094017094%;
-    *margin-left: 16.98763411529369%;
-  }
-  .row-fluid .offset1 {
-    margin-left: 11.11111111111111%;
-    *margin-left: 11.004728132387708%;
-  }
-  .row-fluid .offset1:first-child {
-    margin-left: 8.547008547008547%;
-    *margin-left: 8.440625568285142%;
-  }
-  input,
-  textarea,
-  .uneditable-input {
-    margin-left: 0;
-  }
-  .controls-row [class*="span"] + [class*="span"] {
-    margin-left: 30px;
-  }
-  input.span12,
-  textarea.span12,
-  .uneditable-input.span12 {
-    width: 1156px;
-  }
-  input.span11,
-  textarea.span11,
-  .uneditable-input.span11 {
-    width: 1056px;
-  }
-  input.span10,
-  textarea.span10,
-  .uneditable-input.span10 {
-    width: 956px;
-  }
-  input.span9,
-  textarea.span9,
-  .uneditable-input.span9 {
-    width: 856px;
-  }
-  input.span8,
-  textarea.span8,
-  .uneditable-input.span8 {
-    width: 756px;
-  }
-  input.span7,
-  textarea.span7,
-  .uneditable-input.span7 {
-    width: 656px;
-  }
-  input.span6,
-  textarea.span6,
-  .uneditable-input.span6 {
-    width: 556px;
-  }
-  input.span5,
-  textarea.span5,
-  .uneditable-input.span5 {
-    width: 456px;
-  }
-  input.span4,
-  textarea.span4,
-  .uneditable-input.span4 {
-    width: 356px;
-  }
-  input.span3,
-  textarea.span3,
-  .uneditable-input.span3 {
-    width: 256px;
-  }
-  input.span2,
-  textarea.span2,
-  .uneditable-input.span2 {
-    width: 156px;
-  }
-  input.span1,
-  textarea.span1,
-  .uneditable-input.span1 {
-    width: 56px;
-  }
-  .thumbnails {
-    margin-left: -30px;
-  }
-  .thumbnails > li {
-    margin-left: 30px;
-  }
-  .row-fluid .thumbnails {
-    margin-left: 0;
-  }
-}
-
-@media (min-width: 768px) and (max-width: 979px) {
-  .row {
-    margin-left: -20px;
-    *zoom: 1;
-  }
-  .row:before,
-  .row:after {
-    display: table;
-    line-height: 0;
-    content: "";
-  }
-  .row:after {
-    clear: both;
-  }
-  [class*="span"] {
-    float: left;
-    min-height: 1px;
-    margin-left: 20px;
-  }
-  .container,
-  .navbar-static-top .container,
-  .navbar-fixed-top .container,
-  .navbar-fixed-bottom .container {
-    width: 724px;
-  }
-  .span12 {
-    width: 724px;
-  }
-  .span11 {
-    width: 662px;
-  }
-  .span10 {
-    width: 600px;
-  }
-  .span9 {
-    width: 538px;
-  }
-  .span8 {
-    width: 476px;
-  }
-  .span7 {
-    width: 414px;
-  }
-  .span6 {
-    width: 352px;
-  }
-  .span5 {
-    width: 290px;
-  }
-  .span4 {
-    width: 228px;
-  }
-  .span3 {
-    width: 166px;
-  }
-  .span2 {
-    width: 104px;
-  }
-  .span1 {
-    width: 42px;
-  }
-  .offset12 {
-    margin-left: 764px;
-  }
-  .offset11 {
-    margin-left: 702px;
-  }
-  .offset10 {
-    margin-left: 640px;
-  }
-  .offset9 {
-    margin-left: 578px;
-  }
-  .offset8 {
-    margin-left: 516px;
-  }
-  .offset7 {
-    margin-left: 454px;
-  }
-  .offset6 {
-    margin-left: 392px;
-  }
-  .offset5 {
-    margin-left: 330px;
-  }
-  .offset4 {
-    margin-left: 268px;
-  }
-  .offset3 {
-    margin-left: 206px;
-  }
-  .offset2 {
-    margin-left: 144px;
-  }
-  .offset1 {
-    margin-left: 82px;
-  }
-  .row-fluid {
-    width: 100%;
-    *zoom: 1;
-  }
-  .row-fluid:before,
-  .row-fluid:after {
-    display: table;
-    line-height: 0;
-    content: "";
-  }
-  .row-fluid:after {
-    clear: both;
-  }
-  .row-fluid [class*="span"] {
-    display: block;
-    float: left;
-    width: 100%;
-    min-height: 30px;
-    margin-left: 2.7624309392265194%;
-    *margin-left: 2.709239449864817%;
-    -webkit-box-sizing: border-box;
-       -moz-box-sizing: border-box;
-            box-sizing: border-box;
-  }
-  .row-fluid [class*="span"]:first-child {
-    margin-left: 0;
-  }
-  .row-fluid .controls-row [class*="span"] + [class*="span"] {
-    margin-left: 2.7624309392265194%;
-  }
-  .row-fluid .span12 {
-    width: 100%;
-    *width: 99.94680851063829%;
-  }
-  .row-fluid .span11 {
-    width: 91.43646408839778%;
-    *width: 91.38327259903608%;
-  }
-  .row-fluid .span10 {
-    width: 82.87292817679558%;
-    *width: 82.81973668743387%;
-  }
-  .row-fluid .span9 {
-    width: 74.30939226519337%;
-    *width: 74.25620077583166%;
-  }
-  .row-fluid .span8 {
-    width: 65.74585635359117%;
-    *width: 65.69266486422946%;
-  }
-  .row-fluid .span7 {
-    width: 57.18232044198895%;
-    *width: 57.12912895262725%;
-  }
-  .row-fluid .span6 {
-    width: 48.61878453038674%;
-    *width: 48.56559304102504%;
-  }
-  .row-fluid .span5 {
-    width: 40.05524861878453%;
-    *width: 40.00205712942283%;
-  }
-  .row-fluid .span4 {
-    width: 31.491712707182323%;
-    *width: 31.43852121782062%;
-  }
-  .row-fluid .span3 {
-    width: 22.92817679558011%;
-    *width: 22.87498530621841%;
-  }
-  .row-fluid .span2 {
-    width: 14.3646408839779%;
-    *width: 14.311449394616199%;
-  }
-  .row-fluid .span1 {
-    width: 5.801104972375691%;
-    *width: 5.747913483013988%;
-  }
-  .row-fluid .offset12 {
-    margin-left: 105.52486187845304%;
-    *margin-left: 105.41847889972962%;
-  }
-  .row-fluid .offset12:first-child {
-    margin-left: 102.76243093922652%;
-    *margin-left: 102.6560479605031%;
-  }
-  .row-fluid .offset11 {
-    margin-left: 96.96132596685082%;
-    *margin-left: 96.8549429881274%;
-  }
-  .row-fluid .offset11:first-child {
-    margin-left: 94.1988950276243%;
-    *margin-left: 94.09251204890089%;
-  }
-  .row-fluid .offset10 {
-    margin-left: 88.39779005524862%;
-    *margin-left: 88.2914070765252%;
-  }
-  .row-fluid .offset10:first-child {
-    margin-left: 85.6353591160221%;
-    *margin-left: 85.52897613729868%;
-  }
-  .row-fluid .offset9 {
-    margin-left: 79.8342541436464%;
-    *margin-left: 79.72787116492299%;
-  }
-  .row-fluid .offset9:first-child {
-    margin-left: 77.07182320441989%;
-    *margin-left: 76.96544022569647%;
-  }
-  .row-fluid .offset8 {
-    margin-left: 71.2707182320442%;
-    *margin-left: 71.16433525332079%;
-  }
-  .row-fluid .offset8:first-child {
-    margin-left: 68.50828729281768%;
-    *margin-left: 68.40190431409427%;
-  }
-  .row-fluid .offset7 {
-    margin-left: 62.70718232044199%;
-    *margin-left: 62.600799341718584%;
-  }
-  .row-fluid .offset7:first-child {
-    margin-left: 59.94475138121547%;
-    *margin-left: 59.838368402492065%;
-  }
-  .row-fluid .offset6 {
-    margin-left: 54.14364640883978%;
-    *margin-left: 54.037263430116376%;
-  }
-  .row-fluid .offset6:first-child {
-    margin-left: 51.38121546961326%;
-    *margin-left: 51.27483249088986%;
-  }
-  .row-fluid .offset5 {
-    margin-left: 45.58011049723757%;
-    *margin-left: 45.47372751851417%;
-  }
-  .row-fluid .offset5:first-child {
-    margin-left: 42.81767955801105%;
-    *margin-left: 42.71129657928765%;
-  }
-  .row-fluid .offset4 {
-    margin-left: 37.01657458563536%;
-    *margin-left: 36.91019160691196%;
-  }
-  .row-fluid .offset4:first-child {
-    margin-left: 34.25414364640884%;
-    *margin-left: 34.14776066768544%;
-  }
-  .row-fluid .offset3 {
-    margin-left: 28.45303867403315%;
-    *margin-left: 28.346655695309746%;
-  }
-  .row-fluid .offset3:first-child {
-    margin-left: 25.69060773480663%;
-    *margin-left: 25.584224756083227%;
-  }
-  .row-fluid .offset2 {
-    margin-left: 19.88950276243094%;
-    *margin-left: 19.783119783707537%;
-  }
-  .row-fluid .offset2:first-child {
-    margin-left: 17.12707182320442%;
-    *margin-left: 17.02068884448102%;
-  }
-  .row-fluid .offset1 {
-    margin-left: 11.32596685082873%;
-    *margin-left: 11.219583872105325%;
-  }
-  .row-fluid .offset1:first-child {
-    margin-left: 8.56353591160221%;
-    *margin-left: 8.457152932878806%;
-  }
-  input,
-  textarea,
-  .uneditable-input {
-    margin-left: 0;
-  }
-  .controls-row [class*="span"] + [class*="span"] {
-    margin-left: 20px;
-  }
-  input.span12,
-  textarea.span12,
-  .uneditable-input.span12 {
-    width: 710px;
-  }
-  input.span11,
-  textarea.span11,
-  .uneditable-input.span11 {
-    width: 648px;
-  }
-  input.span10,
-  textarea.span10,
-  .uneditable-input.span10 {
-    width: 586px;
-  }
-  input.span9,
-  textarea.span9,
-  .uneditable-input.span9 {
-    width: 524px;
-  }
-  input.span8,
-  textarea.span8,
-  .uneditable-input.span8 {
-    width: 462px;
-  }
-  input.span7,
-  textarea.span7,
-  .uneditable-input.span7 {
-    width: 400px;
-  }
-  input.span6,
-  textarea.span6,
-  .uneditable-input.span6 {
-    width: 338px;
-  }
-  input.span5,
-  textarea.span5,
-  .uneditable-input.span5 {
-    width: 276px;
-  }
-  input.span4,
-  textarea.span4,
-  .uneditable-input.span4 {
-    width: 214px;
-  }
-  input.span3,
-  textarea.span3,
-  .uneditable-input.span3 {
-    width: 152px;
-  }
-  input.span2,
-  textarea.span2,
-  .uneditable-input.span2 {
-    width: 90px;
-  }
-  input.span1,
-  textarea.span1,
-  .uneditable-input.span1 {
-    width: 28px;
-  }
-}
-
-@media (max-width: 767px) {
-  body {
-    padding-right: 20px;
-    padding-left: 20px;
-  }
-  .navbar-fixed-top,
-  .navbar-fixed-bottom,
-  .navbar-static-top {
-    margin-right: -20px;
-    margin-left: -20px;
-  }
-  .container-fluid {
-    padding: 0;
-  }
-  .dl-horizontal dt {
-    float: none;
-    width: auto;
-    clear: none;
-    text-align: left;
-  }
-  .dl-horizontal dd {
-    margin-left: 0;
-  }
-  .container {
-    width: auto;
-  }
-  .row-fluid {
-    width: 100%;
-  }
-  .row,
-  .thumbnails {
-    margin-left: 0;
-  }
-  .thumbnails > li {
-    float: none;
-    margin-left: 0;
-  }
-  [class*="span"],
-  .uneditable-input[class*="span"],
-  .row-fluid [class*="span"] {
-    display: block;
-    float: none;
-    width: 100%;
-    margin-left: 0;
-    -webkit-box-sizing: border-box;
-       -moz-box-sizing: border-box;
-            box-sizing: border-box;
-  }
-  .span12,
-  .row-fluid .span12 {
-    width: 100%;
-    -webkit-box-sizing: border-box;
-       -moz-box-sizing: border-box;
-            box-sizing: border-box;
-  }
-  .row-fluid [class*="offset"]:first-child {
-    margin-left: 0;
-  }
-  .input-large,
-  .input-xlarge,
-  .input-xxlarge,
-  input[class*="span"],
-  select[class*="span"],
-  textarea[class*="span"],
-  .uneditable-input {
-    display: block;
-    width: 100%;
-    min-height: 30px;
-    -webkit-box-sizing: border-box;
-       -moz-box-sizing: border-box;
-            box-sizing: border-box;
-  }
-  .input-prepend input,
-  .input-append input,
-  .input-prepend input[class*="span"],
-  .input-append input[class*="span"] {
-    display: inline-block;
-    width: auto;
-  }
-  .controls-row [class*="span"] + [class*="span"] {
-    margin-left: 0;
-  }
-  .modal {
-    position: fixed;
-    top: 20px;
-    right: 20px;
-    left: 20px;
-    width: auto;
-    margin: 0;
-  }
-  .modal.fade {
-    top: -100px;
-  }
-  .modal.fade.in {
-    top: 20px;
-  }
-}
-
-@media (max-width: 480px) {
-  .nav-collapse {
-    -webkit-transform: translate3d(0, 0, 0);
-  }
-  .page-header h1 small {
-    display: block;
-    line-height: 20px;
-  }
-  input[type="checkbox"],
-  input[type="radio"] {
-    border: 1px solid #ccc;
-  }
-  .form-horizontal .control-label {
-    float: none;
-    width: auto;
-    padding-top: 0;
-    text-align: left;
-  }
-  .form-horizontal .controls {
-    margin-left: 0;
-  }
-  .form-horizontal .control-list {
-    padding-top: 0;
-  }
-  .form-horizontal .form-actions {
-    padding-right: 10px;
-    padding-left: 10px;
-  }
-  .media .pull-left,
-  .media .pull-right {
-    display: block;
-    float: none;
-    margin-bottom: 10px;
-  }
-  .media-object {
-    margin-right: 0;
-    margin-left: 0;
-  }
-  .modal {
-    top: 10px;
-    right: 10px;
-    left: 10px;
-  }
-  .modal-header .close {
-    padding: 10px;
-    margin: -10px;
-  }
-  .carousel-caption {
-    position: static;
-  }
-}
-
-@media (max-width: 979px) {
-  body {
-    padding-top: 0;
-  }
-  .navbar-fixed-top,
-  .navbar-fixed-bottom {
-    position: static;
-  }
-  .navbar-fixed-top {
-    margin-bottom: 20px;
-  }
-  .navbar-fixed-bottom {
-    margin-top: 20px;
-  }
-  .navbar-fixed-top .navbar-inner,
-  .navbar-fixed-bottom .navbar-inner {
-    padding: 5px;
-  }
-  .navbar .container {
-    width: auto;
-    padding: 0;
-  }
-  .navbar .brand {
-    padding-right: 10px;
-    padding-left: 10px;
-    margin: 0 0 0 -5px;
-  }
-  .nav-collapse {
-    clear: both;
-  }
-  .nav-collapse .nav {
-    float: none;
-    margin: 0 0 10px;
-  }
-  .nav-collapse .nav > li {
-    float: none;
-  }
-  .nav-collapse .nav > li > a {
-    margin-bottom: 2px;
-  }
-  .nav-collapse .nav > .divider-vertical {
-    display: none;
-  }
-  .nav-collapse .nav .nav-header {
-    color: #777777;
-    text-shadow: none;
-  }
-  .nav-collapse .nav > li > a,
-  .nav-collapse .dropdown-menu a {
-    padding: 9px 15px;
-    font-weight: bold;
-    color: #777777;
-    -webkit-border-radius: 3px;
-       -moz-border-radius: 3px;
-            border-radius: 3px;
-  }
-  .nav-collapse .btn {
-    padding: 4px 10px 4px;
-    font-weight: normal;
-    -webkit-border-radius: 4px;
-       -moz-border-radius: 4px;
-            border-radius: 4px;
-  }
-  .nav-collapse .dropdown-menu li + li a {
-    margin-bottom: 2px;
-  }
-  .nav-collapse .nav > li > a:hover,
-  .nav-collapse .nav > li > a:focus,
-  .nav-collapse .dropdown-menu a:hover,
-  .nav-collapse .dropdown-menu a:focus {
-    background-color: #f2f2f2;
-  }
-  .navbar-inverse .nav-collapse .nav > li > a,
-  .navbar-inverse .nav-collapse .dropdown-menu a {
-    color: #999999;
-  }
-  .navbar-inverse .nav-collapse .nav > li > a:hover,
-  .navbar-inverse .nav-collapse .nav > li > a:focus,
-  .navbar-inverse .nav-collapse .dropdown-menu a:hover,
-  .navbar-inverse .nav-collapse .dropdown-menu a:focus {
-    background-color: #111111;
-  }
-  .nav-collapse.in .btn-group {
-    padding: 0;
-    margin-top: 5px;
-  }
-  .nav-collapse .dropdown-menu {
-    position: static;
-    top: auto;
-    left: auto;
-    display: none;
-    float: none;
-    max-width: none;
-    padding: 0;
-    margin: 0 15px;
-    background-color: transparent;
-    border: none;
-    -webkit-border-radius: 0;
-       -moz-border-radius: 0;
-            border-radius: 0;
-    -webkit-box-shadow: none;
-       -moz-box-shadow: none;
-            box-shadow: none;
-  }
-  .nav-collapse .open > .dropdown-menu {
-    display: block;
-  }
-  .nav-collapse .dropdown-menu:before,
-  .nav-collapse .dropdown-menu:after {
-    display: none;
-  }
-  .nav-collapse .dropdown-menu .divider {
-    display: none;
-  }
-  .nav-collapse .nav > li > .dropdown-menu:before,
-  .nav-collapse .nav > li > .dropdown-menu:after {
-    display: none;
-  }
-  .nav-collapse .navbar-form,
-  .nav-collapse .navbar-search {
-    float: none;
-    padding: 10px 15px;
-    margin: 10px 0;
-    border-top: 1px solid #f2f2f2;
-    border-bottom: 1px solid #f2f2f2;
-    -webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 1px 0 rgba(255, 255, 255, 0.1);
-       -moz-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 1px 0 rgba(255, 255, 255, 0.1);
-            box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 1px 0 rgba(255, 255, 255, 0.1);
-  }
-  .navbar-inverse .nav-collapse .navbar-form,
-  .navbar-inverse .nav-collapse .navbar-search {
-    border-top-color: #111111;
-    border-bottom-color: #111111;
-  }
-  .navbar .nav-collapse .nav.pull-right {
-    float: none;
-    margin-left: 0;
-  }
-  .nav-collapse,
-  .nav-collapse.collapse {
-    height: 0;
-    overflow: hidden;
-  }
-  .navbar .btn-navbar {
-    display: block;
-  }
-  .navbar-static .navbar-inner {
-    padding-right: 10px;
-    padding-left: 10px;
-  }
-}
-
-@media (min-width: 980px) {
-  .nav-collapse.collapse {
-    height: auto !important;
-    overflow: visible !important;
-  }
-}
diff --git a/docs/theme/docker/static/css/bootstrap-responsive.min.css b/docs/theme/docker/static/css/bootstrap-responsive.min.css
deleted file mode 100755
index adfc3f6..0000000
--- a/docs/theme/docker/static/css/bootstrap-responsive.min.css
+++ /dev/null
@@ -1,1088 +0,0 @@
-/*!
- * Bootstrap Responsive v2.3.0
- *
- * Copyright 2012 Twitter, Inc
- * Licensed under the Apache License v2.0
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Designed and built with all the love in the world @twitter by @mdo and @fat.
- */
-.clearfix {
-  *zoom: 1;
-}
-.clearfix:before,
-.clearfix:after {
-  display: table;
-  line-height: 0;
-  content: "";
-}
-.clearfix:after {
-  clear: both;
-}
-.hide-text {
-  font: 0/0 a;
-  color: transparent;
-  text-shadow: none;
-  background-color: transparent;
-  border: 0;
-}
-.input-block-level {
-  display: block;
-  width: 100%;
-  min-height: 30px;
-  -webkit-box-sizing: border-box;
-  -moz-box-sizing: border-box;
-  box-sizing: border-box;
-}
-@-ms-viewport {
-  width: device-width;
-}
-.hidden {
-  display: none;
-  visibility: hidden;
-}
-.visible-phone {
-  display: none !important;
-}
-.visible-tablet {
-  display: none !important;
-}
-.hidden-desktop {
-  display: none !important;
-}
-.visible-desktop {
-  display: inherit !important;
-}
-@media (min-width: 768px) and (max-width: 979px) {
-  .hidden-desktop {
-    display: inherit !important;
-  }
-  .visible-desktop {
-    display: none !important ;
-  }
-  .visible-tablet {
-    display: inherit !important;
-  }
-  .hidden-tablet {
-    display: none !important;
-  }
-}
-@media (max-width: 767px) {
-  .hidden-desktop {
-    display: inherit !important;
-  }
-  .visible-desktop {
-    display: none !important;
-  }
-  .visible-phone {
-    display: inherit !important;
-  }
-  .hidden-phone {
-    display: none !important;
-  }
-}
-.visible-print {
-  display: none !important;
-}
-@media print {
-  .visible-print {
-    display: inherit !important;
-  }
-  .hidden-print {
-    display: none !important;
-  }
-}
-@media (min-width: 1200px) {
-  .row {
-    margin-left: -30px;
-    *zoom: 1;
-  }
-  .row:before,
-  .row:after {
-    display: table;
-    line-height: 0;
-    content: "";
-  }
-  .row:after {
-    clear: both;
-  }
-  [class*="span"] {
-    float: left;
-    min-height: 1px;
-    margin-left: 30px;
-  }
-  .container,
-  .navbar-static-top .container,
-  .navbar-fixed-top .container,
-  .navbar-fixed-bottom .container {
-    width: 1170px;
-  }
-  .span12 {
-    width: 1170px;
-  }
-  .span11 {
-    width: 1070px;
-  }
-  .span10 {
-    width: 970px;
-  }
-  .span9 {
-    width: 870px;
-  }
-  .span8 {
-    width: 770px;
-  }
-  .span7 {
-    width: 670px;
-  }
-  .span6 {
-    width: 570px;
-  }
-  .span5 {
-    width: 470px;
-  }
-  .span4 {
-    width: 370px;
-  }
-  .span3 {
-    width: 270px;
-  }
-  .span2 {
-    width: 170px;
-  }
-  .span1 {
-    width: 70px;
-  }
-  .offset12 {
-    margin-left: 1230px;
-  }
-  .offset11 {
-    margin-left: 1130px;
-  }
-  .offset10 {
-    margin-left: 1030px;
-  }
-  .offset9 {
-    margin-left: 930px;
-  }
-  .offset8 {
-    margin-left: 830px;
-  }
-  .offset7 {
-    margin-left: 730px;
-  }
-  .offset6 {
-    margin-left: 630px;
-  }
-  .offset5 {
-    margin-left: 530px;
-  }
-  .offset4 {
-    margin-left: 430px;
-  }
-  .offset3 {
-    margin-left: 330px;
-  }
-  .offset2 {
-    margin-left: 230px;
-  }
-  .offset1 {
-    margin-left: 130px;
-  }
-  .row-fluid {
-    width: 100%;
-    *zoom: 1;
-  }
-  .row-fluid:before,
-  .row-fluid:after {
-    display: table;
-    line-height: 0;
-    content: "";
-  }
-  .row-fluid:after {
-    clear: both;
-  }
-  .row-fluid [class*="span"] {
-    display: block;
-    float: left;
-    width: 100%;
-    min-height: 30px;
-    margin-left: 2.564102564102564%;
-    *margin-left: 2.5109110747408616%;
-    -webkit-box-sizing: border-box;
-    -moz-box-sizing: border-box;
-    box-sizing: border-box;
-  }
-  .row-fluid [class*="span"]:first-child {
-    margin-left: 0;
-  }
-  .row-fluid .controls-row [class*="span"] + [class*="span"] {
-    margin-left: 2.564102564102564%;
-  }
-  .row-fluid .span12 {
-    width: 100%;
-    *width: 99.94680851063829%;
-  }
-  .row-fluid .span11 {
-    width: 91.45299145299145%;
-    *width: 91.39979996362975%;
-  }
-  .row-fluid .span10 {
-    width: 82.90598290598291%;
-    *width: 82.8527914166212%;
-  }
-  .row-fluid .span9 {
-    width: 74.35897435897436%;
-    *width: 74.30578286961266%;
-  }
-  .row-fluid .span8 {
-    width: 65.81196581196582%;
-    *width: 65.75877432260411%;
-  }
-  .row-fluid .span7 {
-    width: 57.26495726495726%;
-    *width: 57.21176577559556%;
-  }
-  .row-fluid .span6 {
-    width: 48.717948717948715%;
-    *width: 48.664757228587014%;
-  }
-  .row-fluid .span5 {
-    width: 40.17094017094017%;
-    *width: 40.11774868157847%;
-  }
-  .row-fluid .span4 {
-    width: 31.623931623931625%;
-    *width: 31.570740134569924%;
-  }
-  .row-fluid .span3 {
-    width: 23.076923076923077%;
-    *width: 23.023731587561375%;
-  }
-  .row-fluid .span2 {
-    width: 14.52991452991453%;
-    *width: 14.476723040552828%;
-  }
-  .row-fluid .span1 {
-    width: 5.982905982905983%;
-    *width: 5.929714493544281%;
-  }
-  .row-fluid .offset12 {
-    margin-left: 105.12820512820512%;
-    *margin-left: 105.02182214948171%;
-  }
-  .row-fluid .offset12:first-child {
-    margin-left: 102.56410256410257%;
-    *margin-left: 102.45771958537915%;
-  }
-  .row-fluid .offset11 {
-    margin-left: 96.58119658119658%;
-    *margin-left: 96.47481360247316%;
-  }
-  .row-fluid .offset11:first-child {
-    margin-left: 94.01709401709402%;
-    *margin-left: 93.91071103837061%;
-  }
-  .row-fluid .offset10 {
-    margin-left: 88.03418803418803%;
-    *margin-left: 87.92780505546462%;
-  }
-  .row-fluid .offset10:first-child {
-    margin-left: 85.47008547008548%;
-    *margin-left: 85.36370249136206%;
-  }
-  .row-fluid .offset9 {
-    margin-left: 79.48717948717949%;
-    *margin-left: 79.38079650845607%;
-  }
-  .row-fluid .offset9:first-child {
-    margin-left: 76.92307692307693%;
-    *margin-left: 76.81669394435352%;
-  }
-  .row-fluid .offset8 {
-    margin-left: 70.94017094017094%;
-    *margin-left: 70.83378796144753%;
-  }
-  .row-fluid .offset8:first-child {
-    margin-left: 68.37606837606839%;
-    *margin-left: 68.26968539734497%;
-  }
-  .row-fluid .offset7 {
-    margin-left: 62.393162393162385%;
-    *margin-left: 62.28677941443899%;
-  }
-  .row-fluid .offset7:first-child {
-    margin-left: 59.82905982905982%;
-    *margin-left: 59.72267685033642%;
-  }
-  .row-fluid .offset6 {
-    margin-left: 53.84615384615384%;
-    *margin-left: 53.739770867430444%;
-  }
-  .row-fluid .offset6:first-child {
-    margin-left: 51.28205128205128%;
-    *margin-left: 51.175668303327875%;
-  }
-  .row-fluid .offset5 {
-    margin-left: 45.299145299145295%;
-    *margin-left: 45.1927623204219%;
-  }
-  .row-fluid .offset5:first-child {
-    margin-left: 42.73504273504273%;
-    *margin-left: 42.62865975631933%;
-  }
-  .row-fluid .offset4 {
-    margin-left: 36.75213675213675%;
-    *margin-left: 36.645753773413354%;
-  }
-  .row-fluid .offset4:first-child {
-    margin-left: 34.18803418803419%;
-    *margin-left: 34.081651209310785%;
-  }
-  .row-fluid .offset3 {
-    margin-left: 28.205128205128204%;
-    *margin-left: 28.0987452264048%;
-  }
-  .row-fluid .offset3:first-child {
-    margin-left: 25.641025641025642%;
-    *margin-left: 25.53464266230224%;
-  }
-  .row-fluid .offset2 {
-    margin-left: 19.65811965811966%;
-    *margin-left: 19.551736679396257%;
-  }
-  .row-fluid .offset2:first-child {
-    margin-left: 17.094017094017094%;
-    *margin-left: 16.98763411529369%;
-  }
-  .row-fluid .offset1 {
-    margin-left: 11.11111111111111%;
-    *margin-left: 11.004728132387708%;
-  }
-  .row-fluid .offset1:first-child {
-    margin-left: 8.547008547008547%;
-    *margin-left: 8.440625568285142%;
-  }
-  input,
-  textarea,
-  .uneditable-input {
-    margin-left: 0;
-  }
-  .controls-row [class*="span"] + [class*="span"] {
-    margin-left: 30px;
-  }
-  input.span12,
-  textarea.span12,
-  .uneditable-input.span12 {
-    width: 1156px;
-  }
-  input.span11,
-  textarea.span11,
-  .uneditable-input.span11 {
-    width: 1056px;
-  }
-  input.span10,
-  textarea.span10,
-  .uneditable-input.span10 {
-    width: 956px;
-  }
-  input.span9,
-  textarea.span9,
-  .uneditable-input.span9 {
-    width: 856px;
-  }
-  input.span8,
-  textarea.span8,
-  .uneditable-input.span8 {
-    width: 756px;
-  }
-  input.span7,
-  textarea.span7,
-  .uneditable-input.span7 {
-    width: 656px;
-  }
-  input.span6,
-  textarea.span6,
-  .uneditable-input.span6 {
-    width: 556px;
-  }
-  input.span5,
-  textarea.span5,
-  .uneditable-input.span5 {
-    width: 456px;
-  }
-  input.span4,
-  textarea.span4,
-  .uneditable-input.span4 {
-    width: 356px;
-  }
-  input.span3,
-  textarea.span3,
-  .uneditable-input.span3 {
-    width: 256px;
-  }
-  input.span2,
-  textarea.span2,
-  .uneditable-input.span2 {
-    width: 156px;
-  }
-  input.span1,
-  textarea.span1,
-  .uneditable-input.span1 {
-    width: 56px;
-  }
-  .thumbnails {
-    margin-left: -30px;
-  }
-  .thumbnails > li {
-    margin-left: 30px;
-  }
-  .row-fluid .thumbnails {
-    margin-left: 0;
-  }
-}
-@media (min-width: 768px) and (max-width: 979px) {
-  .row {
-    margin-left: -20px;
-    *zoom: 1;
-  }
-  .row:before,
-  .row:after {
-    display: table;
-    line-height: 0;
-    content: "";
-  }
-  .row:after {
-    clear: both;
-  }
-  [class*="span"] {
-    float: left;
-    min-height: 1px;
-    margin-left: 20px;
-  }
-  .container,
-  .navbar-static-top .container,
-  .navbar-fixed-top .container,
-  .navbar-fixed-bottom .container {
-    width: 724px;
-  }
-  .span12 {
-    width: 724px;
-  }
-  .span11 {
-    width: 662px;
-  }
-  .span10 {
-    width: 600px;
-  }
-  .span9 {
-    width: 538px;
-  }
-  .span8 {
-    width: 476px;
-  }
-  .span7 {
-    width: 414px;
-  }
-  .span6 {
-    width: 352px;
-  }
-  .span5 {
-    width: 290px;
-  }
-  .span4 {
-    width: 228px;
-  }
-  .span3 {
-    width: 166px;
-  }
-  .span2 {
-    width: 104px;
-  }
-  .span1 {
-    width: 42px;
-  }
-  .offset12 {
-    margin-left: 764px;
-  }
-  .offset11 {
-    margin-left: 702px;
-  }
-  .offset10 {
-    margin-left: 640px;
-  }
-  .offset9 {
-    margin-left: 578px;
-  }
-  .offset8 {
-    margin-left: 516px;
-  }
-  .offset7 {
-    margin-left: 454px;
-  }
-  .offset6 {
-    margin-left: 392px;
-  }
-  .offset5 {
-    margin-left: 330px;
-  }
-  .offset4 {
-    margin-left: 268px;
-  }
-  .offset3 {
-    margin-left: 206px;
-  }
-  .offset2 {
-    margin-left: 144px;
-  }
-  .offset1 {
-    margin-left: 82px;
-  }
-  .row-fluid {
-    width: 100%;
-    *zoom: 1;
-  }
-  .row-fluid:before,
-  .row-fluid:after {
-    display: table;
-    line-height: 0;
-    content: "";
-  }
-  .row-fluid:after {
-    clear: both;
-  }
-  .row-fluid [class*="span"] {
-    display: block;
-    float: left;
-    width: 100%;
-    min-height: 30px;
-    margin-left: 2.7624309392265194%;
-    *margin-left: 2.709239449864817%;
-    -webkit-box-sizing: border-box;
-    -moz-box-sizing: border-box;
-    box-sizing: border-box;
-  }
-  .row-fluid [class*="span"]:first-child {
-    margin-left: 0;
-  }
-  .row-fluid .controls-row [class*="span"] + [class*="span"] {
-    margin-left: 2.7624309392265194%;
-  }
-  .row-fluid .span12 {
-    width: 100%;
-    *width: 99.94680851063829%;
-  }
-  .row-fluid .span11 {
-    width: 91.43646408839778%;
-    *width: 91.38327259903608%;
-  }
-  .row-fluid .span10 {
-    width: 82.87292817679558%;
-    *width: 82.81973668743387%;
-  }
-  .row-fluid .span9 {
-    width: 74.30939226519337%;
-    *width: 74.25620077583166%;
-  }
-  .row-fluid .span8 {
-    width: 65.74585635359117%;
-    *width: 65.69266486422946%;
-  }
-  .row-fluid .span7 {
-    width: 57.18232044198895%;
-    *width: 57.12912895262725%;
-  }
-  .row-fluid .span6 {
-    width: 48.61878453038674%;
-    *width: 48.56559304102504%;
-  }
-  .row-fluid .span5 {
-    width: 40.05524861878453%;
-    *width: 40.00205712942283%;
-  }
-  .row-fluid .span4 {
-    width: 31.491712707182323%;
-    *width: 31.43852121782062%;
-  }
-  .row-fluid .span3 {
-    width: 22.92817679558011%;
-    *width: 22.87498530621841%;
-  }
-  .row-fluid .span2 {
-    width: 14.3646408839779%;
-    *width: 14.311449394616199%;
-  }
-  .row-fluid .span1 {
-    width: 5.801104972375691%;
-    *width: 5.747913483013988%;
-  }
-  .row-fluid .offset12 {
-    margin-left: 105.52486187845304%;
-    *margin-left: 105.41847889972962%;
-  }
-  .row-fluid .offset12:first-child {
-    margin-left: 102.76243093922652%;
-    *margin-left: 102.6560479605031%;
-  }
-  .row-fluid .offset11 {
-    margin-left: 96.96132596685082%;
-    *margin-left: 96.8549429881274%;
-  }
-  .row-fluid .offset11:first-child {
-    margin-left: 94.1988950276243%;
-    *margin-left: 94.09251204890089%;
-  }
-  .row-fluid .offset10 {
-    margin-left: 88.39779005524862%;
-    *margin-left: 88.2914070765252%;
-  }
-  .row-fluid .offset10:first-child {
-    margin-left: 85.6353591160221%;
-    *margin-left: 85.52897613729868%;
-  }
-  .row-fluid .offset9 {
-    margin-left: 79.8342541436464%;
-    *margin-left: 79.72787116492299%;
-  }
-  .row-fluid .offset9:first-child {
-    margin-left: 77.07182320441989%;
-    *margin-left: 76.96544022569647%;
-  }
-  .row-fluid .offset8 {
-    margin-left: 71.2707182320442%;
-    *margin-left: 71.16433525332079%;
-  }
-  .row-fluid .offset8:first-child {
-    margin-left: 68.50828729281768%;
-    *margin-left: 68.40190431409427%;
-  }
-  .row-fluid .offset7 {
-    margin-left: 62.70718232044199%;
-    *margin-left: 62.600799341718584%;
-  }
-  .row-fluid .offset7:first-child {
-    margin-left: 59.94475138121547%;
-    *margin-left: 59.838368402492065%;
-  }
-  .row-fluid .offset6 {
-    margin-left: 54.14364640883978%;
-    *margin-left: 54.037263430116376%;
-  }
-  .row-fluid .offset6:first-child {
-    margin-left: 51.38121546961326%;
-    *margin-left: 51.27483249088986%;
-  }
-  .row-fluid .offset5 {
-    margin-left: 45.58011049723757%;
-    *margin-left: 45.47372751851417%;
-  }
-  .row-fluid .offset5:first-child {
-    margin-left: 42.81767955801105%;
-    *margin-left: 42.71129657928765%;
-  }
-  .row-fluid .offset4 {
-    margin-left: 37.01657458563536%;
-    *margin-left: 36.91019160691196%;
-  }
-  .row-fluid .offset4:first-child {
-    margin-left: 34.25414364640884%;
-    *margin-left: 34.14776066768544%;
-  }
-  .row-fluid .offset3 {
-    margin-left: 28.45303867403315%;
-    *margin-left: 28.346655695309746%;
-  }
-  .row-fluid .offset3:first-child {
-    margin-left: 25.69060773480663%;
-    *margin-left: 25.584224756083227%;
-  }
-  .row-fluid .offset2 {
-    margin-left: 19.88950276243094%;
-    *margin-left: 19.783119783707537%;
-  }
-  .row-fluid .offset2:first-child {
-    margin-left: 17.12707182320442%;
-    *margin-left: 17.02068884448102%;
-  }
-  .row-fluid .offset1 {
-    margin-left: 11.32596685082873%;
-    *margin-left: 11.219583872105325%;
-  }
-  .row-fluid .offset1:first-child {
-    margin-left: 8.56353591160221%;
-    *margin-left: 8.457152932878806%;
-  }
-  input,
-  textarea,
-  .uneditable-input {
-    margin-left: 0;
-  }
-  .controls-row [class*="span"] + [class*="span"] {
-    margin-left: 20px;
-  }
-  input.span12,
-  textarea.span12,
-  .uneditable-input.span12 {
-    width: 710px;
-  }
-  input.span11,
-  textarea.span11,
-  .uneditable-input.span11 {
-    width: 648px;
-  }
-  input.span10,
-  textarea.span10,
-  .uneditable-input.span10 {
-    width: 586px;
-  }
-  input.span9,
-  textarea.span9,
-  .uneditable-input.span9 {
-    width: 524px;
-  }
-  input.span8,
-  textarea.span8,
-  .uneditable-input.span8 {
-    width: 462px;
-  }
-  input.span7,
-  textarea.span7,
-  .uneditable-input.span7 {
-    width: 400px;
-  }
-  input.span6,
-  textarea.span6,
-  .uneditable-input.span6 {
-    width: 338px;
-  }
-  input.span5,
-  textarea.span5,
-  .uneditable-input.span5 {
-    width: 276px;
-  }
-  input.span4,
-  textarea.span4,
-  .uneditable-input.span4 {
-    width: 214px;
-  }
-  input.span3,
-  textarea.span3,
-  .uneditable-input.span3 {
-    width: 152px;
-  }
-  input.span2,
-  textarea.span2,
-  .uneditable-input.span2 {
-    width: 90px;
-  }
-  input.span1,
-  textarea.span1,
-  .uneditable-input.span1 {
-    width: 28px;
-  }
-}
-@media (max-width: 767px) {
-  body {
-    padding-right: 20px;
-    padding-left: 20px;
-  }
-  .navbar-fixed-top,
-  .navbar-fixed-bottom,
-  .navbar-static-top {
-    margin-right: -20px;
-    margin-left: -20px;
-  }
-  .container-fluid {
-    padding: 0;
-  }
-  .dl-horizontal dt {
-    float: none;
-    width: auto;
-    clear: none;
-    text-align: left;
-  }
-  .dl-horizontal dd {
-    margin-left: 0;
-  }
-  .container {
-    width: auto;
-  }
-  .row-fluid {
-    width: 100%;
-  }
-  .row,
-  .thumbnails {
-    margin-left: 0;
-  }
-  .thumbnails > li {
-    float: none;
-    margin-left: 0;
-  }
-  [class*="span"],
-  .uneditable-input[class*="span"],
-  .row-fluid [class*="span"] {
-    display: block;
-    float: none;
-    width: 100%;
-    margin-left: 0;
-    -webkit-box-sizing: border-box;
-    -moz-box-sizing: border-box;
-    box-sizing: border-box;
-  }
-  .span12,
-  .row-fluid .span12 {
-    width: 100%;
-    -webkit-box-sizing: border-box;
-    -moz-box-sizing: border-box;
-    box-sizing: border-box;
-  }
-  .row-fluid [class*="offset"]:first-child {
-    margin-left: 0;
-  }
-  .input-large,
-  .input-xlarge,
-  .input-xxlarge,
-  input[class*="span"],
-  select[class*="span"],
-  textarea[class*="span"],
-  .uneditable-input {
-    display: block;
-    width: 100%;
-    min-height: 30px;
-    -webkit-box-sizing: border-box;
-    -moz-box-sizing: border-box;
-    box-sizing: border-box;
-  }
-  .input-prepend input,
-  .input-append input,
-  .input-prepend input[class*="span"],
-  .input-append input[class*="span"] {
-    display: inline-block;
-    width: auto;
-  }
-  .controls-row [class*="span"] + [class*="span"] {
-    margin-left: 0;
-  }
-  .modal {
-    position: fixed;
-    top: 20px;
-    right: 20px;
-    left: 20px;
-    width: auto;
-    margin: 0;
-  }
-  .modal.fade {
-    top: -100px;
-  }
-  .modal.fade.in {
-    top: 20px;
-  }
-}
-@media (max-width: 480px) {
-  .nav-collapse {
-    -webkit-transform: translate3d(0, 0, 0);
-  }
-  .page-header h1 small {
-    display: block;
-    line-height: 20px;
-  }
-  input[type="checkbox"],
-  input[type="radio"] {
-    border: 1px solid #ccc;
-  }
-  .form-horizontal .control-label {
-    float: none;
-    width: auto;
-    padding-top: 0;
-    text-align: left;
-  }
-  .form-horizontal .controls {
-    margin-left: 0;
-  }
-  .form-horizontal .control-list {
-    padding-top: 0;
-  }
-  .form-horizontal .form-actions {
-    padding-right: 10px;
-    padding-left: 10px;
-  }
-  .media .pull-left,
-  .media .pull-right {
-    display: block;
-    float: none;
-    margin-bottom: 10px;
-  }
-  .media-object {
-    margin-right: 0;
-    margin-left: 0;
-  }
-  .modal {
-    top: 10px;
-    right: 10px;
-    left: 10px;
-  }
-  .modal-header .close {
-    padding: 10px;
-    margin: -10px;
-  }
-  .carousel-caption {
-    position: static;
-  }
-}
-@media (max-width: 979px) {
-  body {
-    padding-top: 0;
-  }
-  .navbar-fixed-top,
-  .navbar-fixed-bottom {
-    position: static;
-  }
-  .navbar-fixed-top {
-    margin-bottom: 20px;
-  }
-  .navbar-fixed-bottom {
-    margin-top: 20px;
-  }
-  .navbar-fixed-top .navbar-inner,
-  .navbar-fixed-bottom .navbar-inner {
-    padding: 5px;
-  }
-  .navbar .container {
-    width: auto;
-    padding: 0;
-  }
-  .navbar .brand {
-    padding-right: 10px;
-    padding-left: 10px;
-    margin: 0 0 0 -5px;
-  }
-  .nav-collapse {
-    clear: both;
-  }
-  .nav-collapse .nav {
-    float: none;
-    margin: 0 0 10px;
-  }
-  .nav-collapse .nav > li {
-    float: none;
-  }
-  .nav-collapse .nav > li > a {
-    margin-bottom: 2px;
-  }
-  .nav-collapse .nav > .divider-vertical {
-    display: none;
-  }
-  .nav-collapse .nav .nav-header {
-    color: #777777;
-    text-shadow: none;
-  }
-  .nav-collapse .nav > li > a,
-  .nav-collapse .dropdown-menu a {
-    padding: 9px 15px;
-    font-weight: bold;
-    color: #777777;
-    -webkit-border-radius: 3px;
-    -moz-border-radius: 3px;
-    border-radius: 3px;
-  }
-  .nav-collapse .btn {
-    padding: 4px 10px 4px;
-    font-weight: normal;
-    -webkit-border-radius: 4px;
-    -moz-border-radius: 4px;
-    border-radius: 4px;
-  }
-  .nav-collapse .dropdown-menu li + li a {
-    margin-bottom: 2px;
-  }
-  .nav-collapse .nav > li > a:hover,
-  .nav-collapse .nav > li > a:focus,
-  .nav-collapse .dropdown-menu a:hover,
-  .nav-collapse .dropdown-menu a:focus {
-    background-color: #f2f2f2;
-  }
-  .navbar-inverse .nav-collapse .nav > li > a,
-  .navbar-inverse .nav-collapse .dropdown-menu a {
-    color: #999999;
-  }
-  .navbar-inverse .nav-collapse .nav > li > a:hover,
-  .navbar-inverse .nav-collapse .nav > li > a:focus,
-  .navbar-inverse .nav-collapse .dropdown-menu a:hover,
-  .navbar-inverse .nav-collapse .dropdown-menu a:focus {
-    background-color: #111111;
-  }
-  .nav-collapse.in .btn-group {
-    padding: 0;
-    margin-top: 5px;
-  }
-  .nav-collapse .dropdown-menu {
-    position: static;
-    top: auto;
-    left: auto;
-    display: none;
-    float: none;
-    max-width: none;
-    padding: 0;
-    margin: 0 15px;
-    background-color: transparent;
-    border: none;
-    -webkit-border-radius: 0;
-    -moz-border-radius: 0;
-    border-radius: 0;
-    -webkit-box-shadow: none;
-    -moz-box-shadow: none;
-    box-shadow: none;
-  }
-  .nav-collapse .open > .dropdown-menu {
-    display: block;
-  }
-  .nav-collapse .dropdown-menu:before,
-  .nav-collapse .dropdown-menu:after {
-    display: none;
-  }
-  .nav-collapse .dropdown-menu .divider {
-    display: none;
-  }
-  .nav-collapse .nav > li > .dropdown-menu:before,
-  .nav-collapse .nav > li > .dropdown-menu:after {
-    display: none;
-  }
-  .nav-collapse .navbar-form,
-  .nav-collapse .navbar-search {
-    float: none;
-    padding: 10px 15px;
-    margin: 10px 0;
-    border-top: 1px solid #f2f2f2;
-    border-bottom: 1px solid #f2f2f2;
-    -webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 1px 0 rgba(255, 255, 255, 0.1);
-    -moz-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 1px 0 rgba(255, 255, 255, 0.1);
-    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 1px 0 rgba(255, 255, 255, 0.1);
-  }
-  .navbar-inverse .nav-collapse .navbar-form,
-  .navbar-inverse .nav-collapse .navbar-search {
-    border-top-color: #111111;
-    border-bottom-color: #111111;
-  }
-  .navbar .nav-collapse .nav.pull-right {
-    float: none;
-    margin-left: 0;
-  }
-  .nav-collapse,
-  .nav-collapse.collapse {
-    height: 0;
-    overflow: hidden;
-  }
-  .navbar .btn-navbar {
-    display: block;
-  }
-  .navbar-static .navbar-inner {
-    padding-right: 10px;
-    padding-left: 10px;
-  }
-}
-@media (min-width: 980px) {
-  .nav-collapse.collapse {
-    height: auto !important;
-    overflow: visible !important;
-  }
-}
diff --git a/docs/theme/docker/static/css/main.css b/docs/theme/docker/static/css/main.css
index 43ec37c..756adb1 100755
--- a/docs/theme/docker/static/css/main.css
+++ b/docs/theme/docker/static/css/main.css
@@ -1,280 +1,205 @@
-/* ==========================================================================
-   Author's custom styles
-   ========================================================================== */
-.red {
-  background-color: red;
-}
-.blue {
-  background-color: blue;
-}
-.orange {
-  background-color: orange;
-}
-.gray {
-  background-color: grey;
+.debug {
+  border: 2px dotted red !important;
+  box-sizing: border-box;
+  -moz-box-sizing: border-box;
 }
 body {
-  padding-top: 58px;
-  font-family: Arial, Helvetica, sans-serif;
+  min-width: 940px;
+  font-family: "Cabin", "Helvetica Neue", Helvetica, Arial, sans-serif;
 }
-h1,
-h2,
-h3,
-h4 {
-  font-family: Arial, Helvetica, sans-serif;
-  font-weight: 900;
+p a {
+  text-decoration: underline;
 }
-/* ===================
-	Top navigation
-===================== */
-.navbar {
-  z-index: 999;
-  background-color: white;
+p a.btn {
+  text-decoration: none;
+}
+.brand.logo a {
+  text-decoration: none;
+}
+.navbar .navbar-inner {
+  padding-left: 0px;
+  padding-right: 0px;
 }
 .navbar .nav li a {
-  padding: 22px 15px 22px;
+  padding: 24.2857142855px 17px 24.2857142855px;
+  color: #777777;
+  text-decoration: none;
+  text-shadow: 0 1px 0 #f2f2f2;
 }
-.navbar-dotcloud .container {
-  border-bottom: 2px #000000 solid;
+.navbar .nav > li {
+  float: left;
+}
+.nav-underline {
+  height: 6px;
+  background-color: #71afc0;
+}
+.nav-login li a {
+  color: white;
+  padding: 10px 15px 10px;
+}
+.navbar .brand {
+  margin-left: 0px;
+  float: left;
+  display: block;
+}
+.navbar-inner {
+  min-height: 70px;
+  padding-left: 20px;
+  padding-right: 20px;
+  background-color: #ededed;
+  background-image: -moz-linear-gradient(top, #f2f2f2, #e5e5e5);
+  background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#f2f2f2), to(#e5e5e5));
+  background-image: -webkit-linear-gradient(top, #f2f2f2, #e5e5e5);
+  background-image: -o-linear-gradient(top, #f2f2f2, #e5e5e5);
+  background-image: linear-gradient(to bottom, #f2f2f2, #e5e5e5);
+  background-repeat: repeat-x;
+  filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff2f2f2', endColorstr='#ffe5e5e5', GradientType=0);
+  border: 1px solid #c7c7c7;
+  -webkit-border-radius: 4px;
+  -moz-border-radius: 4px;
+  border-radius: 4px;
+  -webkit-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.065);
+  -moz-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.065);
+  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.065);
+}
+.brand.logo a {
+  color: white;
 }
 .inline-icon {
   margin-bottom: 6px;
 }
-/*
-* Responsive YouTube, Vimeo, Embed, and HTML5 Videos with CSS
-* http://www.jonsuh.com
-*
-* Copyright (c) 2012 Jonathan Suh
-* Free to use under the MIT license.
-* http://www.opensource.org/licenses/mit-license.php
-*/
-.js-video {
-  height: 0;
-  padding-top: 25px;
-  padding-bottom: 67.5%;
-  margin-bottom: 10px;
-  position: relative;
-  overflow: hidden;
-}
-.js-video.vimeo {
-  padding-top: 0;
-}
-.js-video.widescreen {
-  padding-bottom: 57.25%;
-}
-.js-video embed,
-.js-video iframe,
-.js-video object,
-.js-video video {
-  top: 0;
-  left: 0;
-  width: 100%;
-  height: 100%;
-  position: absolute;
-}
-/* Responsive */
-@media (max-width: 767px) {
-  .js-video {
-    padding-top: 0;
-  }
-}
-/* button style from http://charliepark.org/bootstrap_buttons/ */
-.btn-custom {
-  background-color: #292929 !important;
-  background-repeat: repeat-x;
-  filter: progid:DXImageTransform.Microsoft.gradient(startColorstr="#515151", endColorstr="#282828");
-  background-image: -khtml-gradient(linear, left top, left bottom, from(#515151), to(#282828));
-  background-image: -moz-linear-gradient(top, #515151, #282828);
-  background-image: -ms-linear-gradient(top, #515151, #282828);
-  background-image: -webkit-gradient(linear, left top, left bottom, color-stop(0%, #515151), color-stop(100%, #282828));
-  background-image: -webkit-linear-gradient(top, #515151, #282828);
-  background-image: -o-linear-gradient(top, #515151, #282828);
-  background-image: linear-gradient(#515151, #282828);
-  border-color: #282828 #282828 #1f1f1f;
-  color: #fff !important;
-  text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.26);
-  -webkit-font-smoothing: antialiased;
-}
-/* ===================
-	Page title bar
-===================== */
-h1.pageheader {
-  color: #ffffff;
-  font-size: 20px;
-  font-family: "Arial Black", Tahoma, sans-serif;
-  margin: 8px;
-  margin-left: 22px;
-}
-/* ===================
-	Hero unit
-===================== */
-section.header {
-  margin-top: 0;
-}
-.hero-unit {
-  background-color: #292e33;
-}
-.hero-unit h5 {
-  color: #ffffff;
-}
-/* ===================
-	Main content layout
-===================== */
-.contentblock {
-  margin-top: 20px;
-  border-width: 3px;
-  background-color: #eeeeee;
-  box-sizing: content-box;
-  padding: 20px;
-}
-.section img {
-  margin: 15px 15px 15px 0;
-  border: 2px solid gray;
-}
-.admonition {
-  padding: 10px;
-  border: 1px solid grey;
-  margin-bottom: 10px;
-  margin-top: 10px;
-  -webkit-border-radius: 4px;
-  -moz-border-radius: 4px;
-  border-radius: 4px;
-}
-.admonition .admonition-title {
-  font-weight: bold;
-}
-.admonition.note {
-  background-color: #f1ebba;
-}
-.admonition.warning {
-  background-color: #eed9af;
-}
-.admonition.danger {
-  background-color: #e9bcab;
-}
-/* ===================
-	left navigation
-===================== */
-.dotcloudsidebar {
-  float: left;
-  height: 100%;
-  top: 0px;
-  bottom: 0px;
-  position: relative;
-  min-height: 100%;
-  margin-top: 78px;
-  margin-bottom: 22px;
-}
-.sidebar {
-  font-weight: normal;
-  float: left;
-  /*  min-height: 475px;*/
-
-  background: #ececec;
-  /*  border-left: 1px solid #bbbbbb;*/
-
-  /*  border-right: 1px solid #cccccc;*/
-
-  position: relative;
-}
-.sidebar ul {
-  padding: 0px;
-}
-.sidebar ul li {
-  font-size: 14px;
-  list-style-type: none;
-  list-style-position: outside;
-  list-style-image: none;
-  margin-left: -25px;
-  padding: 0px;
-}
-.sidebar ul li a {
-  display: block;
-  color: #443331;
-  outline: 1px solid #dddddd;
-  padding: 12px 12px 10px 12px;
-  margin-top: 1px;
-  background-color: #d2d2d2;
-}
-.sidebar ul li .toctree-l1 {
-  font-size: larger;
-}
-.sidebar ul li .toctree-l1 a {
-  background-color: #dfdfdf;
-}
-.sidebar ul li .toctree-l1 .current {
-  font-weight: bold;
-}
-.sidebar ul li .toctree-l2 a {
-  padding-left: 18px;
-  background-color: #ffffff;
-}
-.sidebar ul li .toctree-l2 .current {
-  font-weight: bold;
-}
-.sidebar ul li .toctree-l3 {
-  font-size: smaller;
-}
-.sidebar ul li .toctree-l3 a {
-  padding-left: 36px;
-  background-color: #ffffff;
-}
-.sidebar ul li .toctree-l3 .current {
-  font-weight: bold;
-}
-.brand img {
-  height: 38px;
-  margin-left: -6px;
-}
-.border-box {
-  box-sizing: border-box;
-  padding: 20px;
-  background-color: #111188;
-  color: white;
-}
-.titlebar {
-  background-color: #000000;
-  margin-top: 0px;
-  margin-bottom: 20px;
-  min-height: 40px;
-  color: white;
-  padding-top: 8px;
-  padding-bottom: 8px;
-}
-.footer {
-  border-top: 2px solid black;
+.row {
   margin-top: 15px;
-  margin-bottom: 20px;
-  min-height: 40px;
-  padding-left: 8px;
-  padding-top: 8px;
-  padding-bottom: 8px;
+  margin-bottom: 15px;
 }
-/* This is the default */
-.span6.with-padding {
-  background-color: #111188;
-  height: 200px;
-  color: white;
-  padding: 10px;
+div[class*='span'] {
+  -moz-box-sizing: border-box;
+  box-sizing: border-box;
 }
-#global {
-  min-height: 500px;
+.box {
+  padding: 30px;
+  background-color: white;
+  margin-top: 8px;
+}
+.paper {
+  background-color: white;
+  padding-top: 30px;
+  padding-bottom: 30px;
+}
+.copy-headline {
+  margin-top: 0px;
+}
+.box h1,
+.box h2,
+.box h3,
+.box h4 {
+  margin-top: -5px;
+}
+.nested {
+  padding: 30px;
+}
+.box.div {
+  padding: 30px;
+}
+span.read-more {
+  margin-left: 15px;
+  white-space: nowrap;
+}
+.forcetopalign {
+  margin-top: 15px !important;
+}
+.forcetopmargin {
+  margin-top: 23px !important;
+}
+.forceleftalign {
+  margin-left: 15px !important;
+}
+.forceleftmargin {
+  margin-left: 21px !important;
+}
+.textcenter {
+  text-align: center;
+}
+.textright {
+  text-align: right;
+}
+.textsmaller {
+  font-size: 12px;
+}
+.modal-backdrop {
+  opacity: 0.4;
+}
+/* generic page copy styles */
+.copy-headline h1 {
+  font-size: 21px;
 }
 /* =======================
-   Row size
+   Sticky footer
 ======================= */
-.row1 {
-  background-color: #999999;
+html,
+body {
   height: 100%;
-  position: relative;
+  /* The html and body elements cannot have any padding or margin. */
+
+}
+/* Wrapper for page content to push down footer */
+#wrap {
+  min-height: 100%;
+  height: auto !important;
+  height: 100%;
+  /* Negative indent footer by it's height */
+
+  margin: 0 auto -280px;
+}
+/* Set the fixed height of the footer here */
+#push-the-footer,
+#footer {
+  height: 280px;
+}
+.main-row {
+  padding-top: 50px;
+}
+#footer .footer {
+  margin-top: 160px;
+}
+#footer .footer .ligaturesymbols {
+  font-size: 30px;
+  color: black;
+}
+#footer .footer .ligaturesymbols a {
+  color: black;
+}
+#footer .footer .footerlist h3,
+#footer .footer .footerlist h4 {
+  /* correct the top alignment */
+
+  margin-top: 0px;
+}
+.footer-landscape-image {
+  position: absolute:
+  bottom: 0;
+  margin-bottom: 0;
+  background-image: url('https://www.docker.io/static/img/website-footer_clean.svg');
+  background-repeat: repeat-x;
+  height: 280px;
+}
+.main-row {
+  margin-top: 40px;
+}
+.main-content {
+  padding: 16px 18px inherit;
 }
 /* =======================
    Social footer
 ======================= */
+.social {
+  margin-left: 0px;
+  margin-top: 15px;
+}
 .social .twitter,
 .social .github,
 .social .googleplus {
-  background: url("../img/footer-links.png") no-repeat transparent;
+  background: url("https://www.docker.io/static/img/footer-links.png") no-repeat transparent;
   display: inline-block;
   height: 35px;
   overflow: hidden;
@@ -288,93 +213,160 @@
 .social .github {
   background-position: -59px 2px;
 }
-#fork-us {
-  /*font-family: 'Maven Pro';*/
-
-  /*font-weight: bold;*/
-
+form table th {
+  vertical-align: top;
+  text-align: right;
+  white-space: nowrap;
+}
+form .labeldd label {
+  font-weight: bold;
+}
+form .helptext {
   font-size: 12px;
-  /*text-transform: uppercase;*/
-
-  display: block;
-  padding: 0px 1em;
-  height: 28px;
-  line-height: 28px;
-  background-color: #43484c;
-  filter: progid:DXImageTransform.Microsoft.gradient(gradientType=0, startColorstr='#FFFF6E56', endColorstr='#FFED4F35');
-  background-image: -webkit-gradient(linear, 50% 0%, 50% 100%, color-stop(0%, #747474), color-stop(100%, #43484c));
-  background-image: -webkit-linear-gradient(top, #747474 0%, #43484c 100%);
-  background-image: -moz-linear-gradient(top, #747474 0%, #43484c 100%);
-  background-image: -o-linear-gradient(top, #747474 0%, #43484c 100%);
-  background-image: linear-gradient(top, #747474 0%, #43484c 100%);
-  border: 1px solid #43484c;
-  -webkit-border-radius: 4px;
-  -moz-border-radius: 4px;
-  -ms-border-radius: 4px;
-  -o-border-radius: 4px;
-  border-radius: 4px;
-  -webkit-box-shadow: inset rgba(255, 255, 255, 0.17) 0 1px 1px;
-  -moz-box-shadow: inset rgba(255, 255, 255, 0.17) 0 1px 1px;
-  box-shadow: inset rgba(255, 255, 255, 0.17) 0 1px 1px;
-  margin: 8px;
+  margin-top: -4px;
+  margin-bottom: 10px;
 }
-#fork-us a {
-  color: #faf2ee;
-  text-shadow: rgba(0, 0, 0, 0.3) 0px 1px 0px;
+form .fielddd input {
+  width: 250px;
 }
+form .error {
+  color: #a30000;
+}
+div.alert.alert-block {
+  margin-bottom: 15px;
+}
+/* ======================= =======================
+  Documentation
+========================= ========================= */
 /* =======================
-   Media size overrides
-======================= */
-/* Large desktop */
-@media (min-width: 1200px) {
-  .span6.with-padding {
-    background-color: #dc143c;
-    width: 540px;
-    padding: 15px;
-  }
+  Styles for the sidebar
+========================= */
+.page-title {
+  background-color: white;
+  border: 1px solid transparent;
+  text-align: center;
+  width: 100%;
 }
-/* Normal desktop */
-@media (min-width: 980px) and (max-width: 1199px) {
-  .span6.with-padding {
-    background-color: #ee1111;
-    width: 440px;
-    padding: 10px;
-  }
+.page-title h4 {
+  font-size: 20px;
 }
-/* Portrait tablet to landscape and desktop */
-@media (min-width: 768px) and (max-width: 979px) {
-  body {
-    padding-top: 0px;
-  }
-  .span6.with-padding {
-    background-color: #292e33;
-    width: 332px;
-    padding: 10px;
-  }
+.bs-docs-sidebar {
+  padding-left: 5px;
+  max-width: 100%;
+  box-sizing: border-box;
+  -moz-box-sizing: border-box;
+  margin-top: 18px;
 }
-/* Landscape phone to portrait tablet */
-@media (max-width: 767px) {
-  body {
-    padding-top: 0px;
-  }
-  #global {
-    /* TODO: Fix this to be relative to the navigation size */
-  
-  }
-  #fork-us {
-    display: none;
-  }
+.bs-docs-sidebar ul {
+  list-style: none;
+  margin-left: 0px;
 }
-/* Landscape phones and down */
-@media (max-width: 480px) {
-  #nav-gettingstarted {
-    display: none;
-  }
+.bs-docs-sidebar .toctree-l2 > ul {
+  width: 100%;
 }
-/* Misc fixes */
-table th {
-  text-align: left;
+.bs-docs-sidebar ul > li.toctree-l1.has-children {
+  background-image: url('../img/menu_arrow_right.gif');
+  background-repeat: no-repeat;
+  background-position: 13px 13px;
+  list-style-type: none;
+  padding: 0px 0px 0px 0px;
+  vertical-align: middle;
 }
+.bs-docs-sidebar ul > li.toctree-l1.has-children.open {
+  background-image: url('../img/menu_arrow_down.gif');
+}
+.bs-docs-sidebar ul > li > a {
+  box-sizing: border-box;
+  -moz-box-sizing: border-box;
+  width: 100%;
+  display: inline-block;
+  padding-top: 8px;
+  padding-bottom: 8px;
+  padding-left: 35px;
+  padding-right: 20px;
+  font-size: 14px;
+  border-bottom: 1.5px solid #595959;
+  line-height: 20px;
+}
+.bs-docs-sidebar ul > li:first-child.active > a {
+  border-top: 1.5px solid #595959;
+}
+.bs-docs-sidebar ul > li:last-child > a {
+  border-bottom: none;
+}
+.bs-docs-sidebar ul > li:last-child.active > a {
+  border-bottom: 1.5px solid #595959;
+}
+.bs-docs-sidebar ul > li.active > a {
+  border-right: 1.5px solid #595959;
+  border-left: 1.5px solid #595959;
+  color: #394d54;
+}
+.bs-docs-sidebar ul > li:hover {
+  background-color: #e8e8e8;
+}
+.bs-docs-sidebar.toctree-l3 ul {
+  display: inherit;
+  margin-left: 15px;
+  font-size: smaller;
+}
+.bs-docs-sidebar .toctree-l3 a {
+  border: none;
+  font-size: 12px;
+  line-height: 15px;
+}
+.bs-docs-sidebar ul > li > ul {
+  display: none;
+}
+.bs-docs-sidebar ul > li.current > ul {
+  display: inline-block;
+  padding-left: 0px;
+  width: 100%;
+}
+.toctree-l2.current > a {
+  font-weight: bold;
+}
+.toctree-l2.current {
+  border: 1.5px solid #595959;
+  color: #394d54;
+}
+/* =====================================
+  Styles for the floating version widget
+====================================== */
+.version-flyer {
+  position: fixed;
+  float: right;
+  right: 0;
+  bottom: 40px;
+  background-color: #E0E0E0;
+  border: 1px solid #88BABC;
+  padding: 5px;
+  font-size: larger;
+}
+.version-flyer .content {
+  padding-right: 45px;
+  margin-top: 7px;
+  margin-left: 7px;
+  background-image: url('../img/container3.png');
+  background-position: right center;
+  background-repeat: no-repeat;
+}
+.version-flyer .alternative {
+  visibility: hidden;
+  display: none;
+}
+.version-flyer .active-slug {
+  visibility: visible;
+  display: inline-block;
+}
+.version-flyer:hover .alternative {
+  animation-duration: 1s;
+  display: inline-block;
+  visibility: visible;
+}
+/* =====================================
+  Styles for 
+====================================== */
 h1:hover > a.headerlink,
 h2:hover > a.headerlink,
 h3:hover > a.headerlink,
@@ -391,21 +383,30 @@
   float: right;
   visibility: hidden;
 }
-
-/* Swiftype style */
-
-#st-search-input {
-  margin-right: 14px;
-  margin-left: 9px;
-  height: 19px;
-  width: 120px;
-
+/* =====================================
+  Miscellaneous information
+====================================== */
+.admonition.warning,
+.admonition.note,
+.admonition.seealso,
+.admonition.todo {
+  border: 3px solid black;
+  padding: 10px;
+  margin: 5px auto 10px;
 }
-#swiftype-img {
-    border: none;
-    width: 145px;
-    height: auto;
-    margin: 0px auto;
-    margin-left: 13px;
-    margin-top: -30px;
-}
\ No newline at end of file
+.admonition .admonition-title {
+  font-size: larger;
+}
+.admonition.warning,
+.admonition.danger {
+  border-color: #ac0004;
+}
+.admonition.note {
+  border-color: #cbc200;
+}
+.admonition.todo {
+  border-color: orange;
+}
+.admonition.seealso {
+  border-color: #23cb1f;
+}
diff --git a/docs/theme/docker/static/css/main.less b/docs/theme/docker/static/css/main.less
index 0451df1..ce18a38 100644
--- a/docs/theme/docker/static/css/main.less
+++ b/docs/theme/docker/static/css/main.less
@@ -1,376 +1,337 @@
+// Main CSS configuration file
+// by Thatcher Peskens, thatcher@dotcloud.com
+//
+// Please note variables.less is customized to include custom font, background-color, and link colors.
 
 
-/* ==========================================================================
-   Author's custom styles
-   ========================================================================== */
-
 @import "variables.less";
 
-@red: crimson;
-@lightblue: #118;
-@lightred: #e11;
-@darkblue: #292E33;
+// Variables for main.less
+// -----------------------
 
-@borderGray: #888;
+@box-top-margin: 			8px;
+@box-padding-size:			30px;
+@docker-background-color:   #71AFC0;
+@very-dark-sea-green:       #394D54;
+
+// Custom colors for Docker
+// --------------------------
+@gray-super-light:		#F2F2F2;
+@deep-red: 				#A30000;
+@deep-blue:				#1B2033;
+@deep-green: 			#007035;
+@link-blue:				#213B8F;
 
 
-.red {
-  background-color: red;
-}
-.blue {
-  background-color: blue;
-}
-.orange {
-  background-color: orange;
-}
-.gray {
-  background-color: grey;
+.debug {
+  border: 2px dotted red !important;
+  box-sizing: border-box;
+  -moz-box-sizing: border-box;
 }
 
 
+// Other custom colors for Docker
+// --------------------------
+
+// ** are defined in sources/less/variables  **
+//@import "bootstrap/variables.less";
+
+
+// Styles generic for each and every page
+// ----------------------------------- // -----------------------------------
+
+
+// moving body down to make place for fixed navigation
 body {
-  padding-top: 58px;
-  font-family: Arial, Helvetica, sans-serif;
+  min-width: 940px;
+  font-family: @font-family-base;
+
 }
 
 
-h1, h2, h3, h4 {
-  font-family: Arial, Helvetica, sans-serif;
-// font-weight: bold;
-  font-weight: 900;
-}
+p a {
+	text-decoration: underline;
 
-/* ===================
-	Top navigation
-===================== */
-
-.navbar {
-  z-index: 999;
-  .nav {
-  // float: right;
-
-    li a{
-      padding: 22px 15px 22px;
+    &.btn {
+      text-decoration: none;
     }
-  }
-  background-color: white;
+
 }
 
-.navbar-dotcloud .container {
-  border-bottom: 2px @black solid;
+.brand.logo a {
+  text-decoration: none;
+}
+
+// Styles for top navigation
+// ----------------------------------
+.navbar .navbar-inner {
+	padding-left: 0px;
+	padding-right: 0px;
+}
+
+.navbar .nav {
+  li a {
+  	padding: ((@navbar-height - @line-height-base) / 2) 17px ((@navbar-height - @line-height-base) / 2);
+    color: #777777;
+    text-decoration: none;
+    text-shadow: 0 1px 0 #f2f2f2;
+  }
+}
+
+
+.navbar .nav > li {
+  float: left;
+}
+
+.nav-underline {
+  height: 6px;
+  background-color: @docker-background-color;
+}
+
+.nav-login {
+  li {
+   	a {
+		color: white;
+		padding: 10px 15px 10px;
+	}
+  }
+}
+
+
+
+.navbar .brand {
+	margin-left: 0px;
+	float: left;
+	display: block;
+}
+
+.navbar-inner {
+  min-height: 70px;
+  padding-left: 20px;
+  padding-right: 20px;
+  background-color: #ededed;
+  background-image: -moz-linear-gradient(top, #f2f2f2, #e5e5e5);
+  background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#f2f2f2), to(#e5e5e5));
+  background-image: -webkit-linear-gradient(top, #f2f2f2, #e5e5e5);
+  background-image: -o-linear-gradient(top, #f2f2f2, #e5e5e5);
+  background-image: linear-gradient(to bottom, #f2f2f2, #e5e5e5);
+  background-repeat: repeat-x;
+  filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff2f2f2', endColorstr='#ffe5e5e5', GradientType=0);
+  border: 1px solid #c7c7c7;
+  -webkit-border-radius: 4px;
+  -moz-border-radius: 4px;
+  border-radius: 4px;
+  -webkit-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.065);
+  -moz-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.065);
+  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.065);
+}
+
+.brand.logo a {
+	color: white;
+
+}
+
+.logo {
+//	background-color: #A30000;
+//	color: white;
 }
 
 .inline-icon {
   margin-bottom: 6px;
 }
 
-/*
-* Responsive YouTube, Vimeo, Embed, and HTML5 Videos with CSS
-* http://www.jonsuh.com
-*
-* Copyright (c) 2012 Jonathan Suh
-* Free to use under the MIT license.
-* http://www.opensource.org/licenses/mit-license.php
-*/
+// Bootstrap elements
+// ----------------------------------
 
-.js-video {
-  height: 0;
-  padding-top: 25px;
-  padding-bottom: 67.5%;
-  margin-bottom: 10px;
-  position: relative;
-  overflow: hidden;
-}
-.js-video.vimeo {
-  padding-top: 0;
-}
-.js-video.widescreen {
-  padding-bottom: 57.25%;
-}
-.js-video embed, .js-video iframe, .js-video object, .js-video video {
-  top: 0;
-  left: 0;
-  width: 100%;
-  height: 100%;
-  position: absolute;
-}
-
-/* Responsive */
-@media (max-width: 767px) {
-  .js-video {
-    padding-top: 0;
-  }
-}
-
-/* button style from http://charliepark.org/bootstrap_buttons/ */
-.btn-custom {
-  background-color: hsl(0, 0%, 16%) !important;
-  background-repeat: repeat-x;
-  filter: progid:DXImageTransform.Microsoft.gradient(startColorstr="#515151", endColorstr="#282828");
-  background-image: -khtml-gradient(linear, left top, left bottom, from(#515151), to(#282828));
-  background-image: -moz-linear-gradient(top, #515151, #282828);
-  background-image: -ms-linear-gradient(top, #515151, #282828);
-  background-image: -webkit-gradient(linear, left top, left bottom, color-stop(0%, #515151), color-stop(100%, #282828));
-  background-image: -webkit-linear-gradient(top, #515151, #282828);
-  background-image: -o-linear-gradient(top, #515151, #282828);
-  background-image: linear-gradient(#515151, #282828);
-  border-color: #282828 #282828 hsl(0, 0%, 12%);
-  color: #fff !important;
-  text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.26);
-  -webkit-font-smoothing: antialiased;
-}
-
-
-
-/* ===================
-	Page title bar
-===================== */
-
-h1.pageheader {
-  color: @white;
-  font-size: 20px;
-  font-family: "Arial Black", Tahoma, sans-serif;
-  margin: 8px;
-  margin-left: 22px;
-}
-
-/* ===================
-	Hero unit
-===================== */
-
-section.header {
-  margin-top:0;
-}
-
-.hero-unit {
-  background-color: @darkblue;
-
-  h5 {
-    color: @white;
-  }
-  .subtitle {
-
-  }
-
-}
-
-/* ===================
-	Main content layout
-===================== */
-
-.contentblock {
-  margin-top: 20px;
-  border-width: 3px;
-// border-color: #E00;
-//	border-style:solid;
-//	border-color: @borderGray;
-// box-sizing: border-box;
-  background-color: @grayLighter;
-  box-sizing: content-box;
-  padding: 20px;
-}
-
-.section img {
-  margin: 15px 15px 15px 0;
-  border: 2px solid gray;
-}
-
-.admonition {
-  padding: 10px;
-  border: 1px solid grey;
-
-  margin-bottom: 10px;
-  margin-top: 10px;
-
-  -webkit-border-radius: 4px;
-  -moz-border-radius: 4px;
-  border-radius: 4px;
-}
-
-.admonition .admonition-title {
-  font-weight: bold;
-}
-
-.admonition.note {
-  background-color: rgb(241, 235, 186);
-}
-
-.admonition.warning {
-  background-color: rgb(238, 217, 175);
-}
-
-.admonition.danger {
-  background-color: rgb(233, 188, 171);
-}
-
-/* ===================
-	left navigation
-===================== */
-
-.dotcloudsidebar {
-// background-color: #ee3;
-// border: 1px red dotted;
-  float: left;
-  height: 100%;
-  top: 0px;
-  bottom: 0px;
-  position: relative;
-// margin: 0px;
-  min-height: 100%;
-  margin-top: 78px;
-  margin-bottom: 22px;
-
-}
-
-  .sidebar {
-  //  font-family: "Maven Pro";
-    font-weight: normal;
-  //  margin-top: 38px;
-    float: left;
-  //  width: 220px;
-  /*  min-height: 475px;*/
-  //  margin-bottom: 28px;
-  //  padding-bottom: 120px;
-    background: #ececec;
-  /*  border-left: 1px solid #bbbbbb;*/
-  /*  border-right: 1px solid #cccccc;*/
-    position: relative;
-
-
-
-  ul {
-    padding: 0px;
-    li {
-      font-size: 14px;
-    //      list-style: none;
-      list-style-type: none;
-      list-style-position: outside;
-      list-style-image: none;
-      margin-left: -25px;
-      padding: 0px;
-
-      a {
-        display: block;
-        color: #443331;
-        outline: 1px solid #dddddd;
-        padding: 12px 12px 10px 12px;
-        margin-top: 1px;
-        background-color: #d2d2d2;
-      }
-
-      .toctree-l1, .toctree-l2 {
-
-      }
-
-      .toctree-l1 {
-        font-size: larger;
-        a {
-          background-color: rgb(223, 223, 223);
-        }
-        .current {
-          font-weight: bold;
-        }
-      //          margin-left: -25px;
-      }
-      .toctree-l2 {
-        a {
-          padding-left: 18px;
-          background-color: rgb(255, 255, 255);
-        }
-        .current {
-          font-weight: bold;
-        }
-
-      }
-      .toctree-l3 {
-        font-size: smaller;
-        a {
-          padding-left: 36px;
-          background-color: rgb(255, 255, 255);
-        }
-        .current {
-          font-weight: bold;
-        }
-
-      }
-
-
-    }
-  }
-}
-
-.brand img {
-  height: 38px;
-  margin-left: -6px;
-}
-
-.border-box {
-  box-sizing: border-box;
-  padding: 20px;
-  background-color: @lightblue;
-  color: white;
-}
-
-
-.titlebar {
-  background-color: @black;
-  margin-top: 0px;
-  margin-bottom: 20px;
-  min-height: 40px;
-  color: white;
-//	box-sizing: border-box;
-  padding-top: 8px;
-  padding-bottom: 8px;
-}
-
-
-.footer {
-  border-top: 2px solid black;
-
-//  background-color: #d2d2d2;
+.row {
   margin-top: 15px;
-  margin-bottom: 20px;
+  margin-bottom: 15px;
+}
 
-  min-height: 40px;
+.container {
+	// background-color: green;
+}
 
-  padding-left: 8px;
-  padding-top: 8px;
-  padding-bottom: 8px;
+// Styles on blocks of content
+// ----------------------------------
+
+// everything which is a block should have box-sizing: border-box;
+
+div[class*='span']
+{
+  -moz-box-sizing: border-box;
+  box-sizing: border-box;
 }
 
 
-
-/* This is the default */
-.span6.with-padding {
-  background-color: @lightblue;
-  height: 200px;
-  color: white;
-  padding: 10px;
+// Box for making white with a border, and some nice spacings
+.box {
+    padding: @box-padding-size;
+	background-color: white;
+	margin-top: @box-top-margin;
 }
 
-#global {
-  min-height: 500px;
+.paper {
+  	background-color: white;
+    padding-top: 30px;
+    padding-bottom: 30px;
 }
 
+.copy-headline {
+  margin-top: 0px;
+//  border-bottom: 1.2px solid @veryDarkSeaGreen;
+}
+
+.box {
+	h1, h2, h3, h4 {
+		margin-top: -5px;
+	}
+}
+
+.nested {
+	padding: @box-padding-size;
+}
+
+.box.div {
+  padding: @box-padding-size;
+}
+
+span.read-more {
+  margin-left: 15px;
+  white-space: nowrap;
+}
+
+
+// set a top margin of @box-top-margin + 8 px to make it show a margin
+//instead of the div being flush against the side. Typically only
+// required for a stacked div in a column, w.o. using row.
+.forcetopalign {
+	margin-top: 15px !important;
+}
+.forcetopmargin {
+	margin-top: 23px !important;
+}
+.forceleftalign {
+	margin-left: 15px !important;
+}
+.forceleftmargin {
+	margin-left: 21px !important;
+}
+
+
+// simple text aligns
+.textcenter {
+	text-align: center;
+}
+
+.textright {
+	text-align: right;
+}
+
+.textsmaller {
+  font-size: @font-size-small;
+}
+
+.modal-backdrop {
+  opacity: 0.4;
+}
+
+
+/* generic page copy styles */
+
+.copy-headline h1 {
+  font-size: 21px;
+}
 
 
 /* =======================
-   Row size
+   Sticky footer
 ======================= */
 
-.row1 {
-  background-color: @grayLight;
+@sticky-footer-height: 280px;
+
+html,
+body {
   height: 100%;
-  position: relative;
+  /* The html and body elements cannot have any padding or margin. */
 }
 
+/* Wrapper for page content to push down footer */
+#wrap {
+  min-height: 100%;
+  height: auto !important;
+  height: 100%;
+  /* Negative indent footer by it's height */
+  margin: 0 auto -@sticky-footer-height;
+}
+
+/* Set the fixed height of the footer here */
+#push-the-footer,
+#footer {
+  height: @sticky-footer-height;
+}
+
+#footer {
+//    margin-bottom: -60px;
+//  margin-top: 160px;
+}
+
+.main-row {
+  padding-top: @navbar-height; 
+}
+
+
+// Styles on the footer
+// ----------------------------------
+
+//
+#footer .footer {
+	margin-top: 160px;
+	.ligaturesymbols {
+		font-size: 30px;
+		color: black;
+		a {
+			color: black;
+		}
+	}
+
+  .footerlist {
+    h3, h4 {
+      /* correct the top alignment */
+      margin-top: 0px;
+    }
+  }
+
+}
+
+.footer-landscape-image {
+  position: absolute:
+  bottom: 0;
+  margin-bottom: 0;
+  background-image: url('https://www.docker.io/static/img/website-footer_clean.svg');
+  background-repeat: repeat-x;
+  height: @sticky-footer-height;
+}
+
+.main-row {
+  margin-top: 40px;
+}
+
+.main-content {
+  padding: 16px 18px inherit;
+}
 
 /* =======================
    Social footer
 ======================= */
 
+.social {
+  margin-left: 0px;
+  margin-top: 15px;
+}
+
 .social .twitter, .social .github, .social .googleplus {
-  background: url("../img/footer-links.png") no-repeat transparent;
+  background: url("https://www.docker.io/static/img/footer-links.png") no-repeat transparent;
   display: inline-block;
   height: 35px;
   overflow: hidden;
@@ -387,107 +348,219 @@
   background-position: -59px 2px;
 }
 
+// Styles on the forms
+// ----------------------------------
 
-#fork-us {
-  /*font-family: 'Maven Pro';*/
-  /*font-weight: bold;*/
-  font-size: 12px;
-  /*text-transform: uppercase;*/
-  display: block;
-  padding: 0px 1em;
-  height: 28px;
-  line-height: 28px;
-  background-color: #43484c;
-  filter: progid:DXImageTransform.Microsoft.gradient(gradientType=0, startColorstr='#FFFF6E56', endColorstr='#FFED4F35');
-  background-image: -webkit-gradient(linear, 50% 0%, 50% 100%, color-stop(0%, #747474), color-stop(100%, #43484c));
-  background-image: -webkit-linear-gradient(top, #747474 0%, #43484c 100%);
-  background-image: -moz-linear-gradient(top, #747474 0%, #43484c 100%);
-  background-image: -o-linear-gradient(top, #747474 0%, #43484c 100%);
-  background-image: linear-gradient(top, #747474 0%, #43484c 100%);
-  border: 1px solid #43484c;
-  -webkit-border-radius: 4px;
-  -moz-border-radius: 4px;
-  -ms-border-radius: 4px;
-  -o-border-radius: 4px;
-  border-radius: 4px;
-  -webkit-box-shadow: inset rgba(255, 255, 255, 0.17) 0 1px 1px;
-  -moz-box-shadow: inset rgba(255, 255, 255, 0.17) 0 1px 1px;
-  box-shadow: inset rgba(255, 255, 255, 0.17) 0 1px 1px;
-  margin: 8px;
-
-  a {
-    color: #faf2ee;
-    text-shadow: rgba(0, 0, 0, 0.3) 0px 1px 0px;
+form table {
+  th {
+    vertical-align: top;
+    text-align: right;
+    white-space: nowrap;
   }
 }
+
+form {
+  .labeldd label {
+    font-weight: bold;
+  }
+
+  .helptext {
+    font-size: @font-size-small;
+    margin-top: -4px;
+    margin-bottom: 10px;
+  }
+
+  .fielddd input {
+    width: 250px;
+  }
+
+  .error {
+    color: @deep-red;
+  }
+
+  [type=submit] {
+//    margin-top: -8px;
+  }
+}
+
+div.alert.alert-block {
+  margin-bottom: 15px;
+}
+
+/* ======================= =======================
+  Documentation
+========================= ========================= */
+
+
 /* =======================
-   Media size overrides
-======================= */
+  Styles for the sidebar
+========================= */
 
-/* Large desktop */
-@media (min-width: 1200px) {
-  .span6.with-padding {
-    background-color: @red;
 
-    width: (@gridColumnWidth1200 * 6) + (@gridGutterWidth1200 * 5) - @gridGutterWidth1200;
-    padding: @gridGutterWidth1200/2;
+@sidebar-navigation-border: 1.5px solid #595959;
+@sidebar-navigation-width: 225px;
+
+
+.page-title {
+  // border-bottom: 1px solid #bbbbbb;
+  background-color: white;
+  border: 1px solid transparent;
+  text-align: center;
+  width: 100%;
+  h4 {
+    font-size: 20px;
   }
 }
 
-/* Normal desktop */
-@media (min-width: 980px) and (max-width: 1199px) {
-  .span6.with-padding {
-    background-color: @lightred;
+.bs-docs-sidebar {
+  padding-left: 5px;
+  max-width: 100%;
+  box-sizing: border-box;
+  -moz-box-sizing: border-box;
+  margin-top: 18px;
 
-    width: (@gridColumnWidth * 6) + (@gridGutterWidth * 5) - @gridGutterWidth;
-    padding: @gridGutterWidth/2;
+  ul {
+      list-style: none;
+      margin-left: 0px;
   }
 
-}
-
-/* Portrait tablet to landscape and desktop */
-@media (min-width: 768px) and (max-width: 979px) {
-  body {
-    padding-top: 0px;
+  .toctree-l2 > ul {
+    width: 100%;
   }
 
+  ul > li {
+    &.toctree-l1.has-children {
+        background-image: url('../img/menu_arrow_right.gif');
+        background-repeat: no-repeat;
+        background-position: 13px 13px;
+        list-style-type: none;
+        // margin-left: px;
+        padding: 0px 0px 0px 0px;
+        vertical-align: middle;
 
-  .span6.with-padding {
-    background-color: @darkblue;
+        &.open {
+          background-image: url('../img/menu_arrow_down.gif');
+        }
+    }
 
-    width: (@gridColumnWidth768 * 6) + (@gridGutterWidth768 * 5) - @gridGutterWidth768;
-    padding: @gridGutterWidth768/2;
+    & > a {
+      box-sizing: border-box;
+      -moz-box-sizing: border-box;
+      width: 100%;
+      display:inline-block;
+      padding-top: 8px;
+      padding-bottom: 8px;
+      padding-left: 35px;
+      padding-right: 20px;
+      font-size: @font-size-base;
+      border-bottom: @sidebar-navigation-border;
+      line-height: 20px;
+    }
 
+    &:first-child.active > a {
+      border-top: @sidebar-navigation-border;
+    }
+
+    &:last-child > a {
+      border-bottom: none;
+    }
+
+    &:last-child.active > a {
+      border-bottom: @sidebar-navigation-border;
+    }
+
+    &.active > a {
+      border-right: @sidebar-navigation-border;
+      border-left: @sidebar-navigation-border;
+      color: @very-dark-sea-green;
+    }
+
+    &:hover {
+      background-color: #e8e8e8;
+    }
   }
-}
 
-/* Landscape phone to portrait tablet */
-@media (max-width: 767px) {
-  body {
-    padding-top: 0px;
+  &.toctree-l3 ul {
+    display: inherit; 
+    
+    margin-left: 15px; 
+    font-size: smaller;
   }
-  #global {
-  /* TODO: Fix this to be relative to the navigation size */
-//    padding-top: 600px;
+
+  .toctree-l3 a {
+    border: none;
+    font-size: 12px;
+    line-height: 15px;
   }
-  #fork-us {
+
+  ul > li > ul {
     display: none;
   }
-}
 
-
-/* Landscape phones and down */
-@media (max-width: 480px) {
-  #nav-gettingstarted {
-    display: none;
+  ul > li.current > ul {
+    display: inline-block;
+    padding-left: 0px;
+    width: 100%;
   }
 }
 
-/* Misc fixes */
-table th {
-  text-align: left;
+.toctree-l2 {
+  &.current > a {
+    font-weight: bold;
+  }
+  &.current {
+    border: 1.5px solid #595959;
+    color: #394d54;
+  }
 }
 
+
+/* =====================================
+  Styles for the floating version widget
+====================================== */
+
+.version-flyer {
+  position: fixed;
+  float: right;
+  right: 0;
+  bottom: 40px;
+  background-color: #E0E0E0;
+  border: 1px solid #88BABC;
+  padding: 5px;
+  font-size: larger;
+
+  .content {
+    padding-right: 45px;
+    margin-top: 7px;
+    margin-left: 7px;
+    // display: inline-block;
+    background-image: url('../img/container3.png');
+    background-position: right center; 
+    background-repeat: no-repeat;
+  }
+
+  .alternative {
+    visibility: hidden;
+    display: none;
+  }
+
+  .active-slug {
+    visibility: visible;
+    display: inline-block;
+  }
+
+  &:hover .alternative {
+    animation-duration: 1s;
+    display: inline-block;
+    visibility: visible;
+  }
+
+}
+
+/* =====================================
+  Styles for 
+====================================== */
+
 h1:hover > a.headerlink,
 h2:hover > a.headerlink,
 h3:hover > a.headerlink,
@@ -504,4 +577,38 @@
   font-weight: bold;
   float: right;
   visibility: hidden;
-}
\ No newline at end of file
+}
+
+/* =====================================
+  Miscellaneous information
+====================================== */
+
+.admonition {
+  &.warning, &.note, &.seealso, &.todo {
+    border: 3px solid black;
+    padding: 10px;
+    margin: 5px auto 10px;
+  }
+
+  .admonition-title {
+      font-size: larger;
+  }
+
+  &.warning, &.danger {
+    border-color: #ac0004;
+  }
+
+  &.note {
+    border-color: #cbc200;
+  }
+
+  &.todo {
+    border-color: orange;
+  }
+
+  &.seealso {
+    border-color: #23cb1f;
+  }
+
+}
+
diff --git a/docs/theme/docker/static/css/variables.less b/docs/theme/docker/static/css/variables.less
old mode 100755
new mode 100644
index 31c131b..cc1d764
--- a/docs/theme/docker/static/css/variables.less
+++ b/docs/theme/docker/static/css/variables.less
@@ -9,128 +9,175 @@
 
 // Grays
 // -------------------------
-@black:                 #000;
-@grayDarker:            #222;
-@grayDark:              #333;
-@gray:                  #555;
-@grayLight:             #999;
-@grayLighter:           #eee;
-@white:                 #fff;
 
+@gray-darker:            lighten(#000, 13.5%); // #222
+@gray-dark:              lighten(#000, 20%);   // #333
+@gray:                   lighten(#000, 33.5%); // #555
+@gray-light:             lighten(#000, 60%);   // #999
+@gray-lighter:           lighten(#000, 93.5%); // #eee
 
-// Accent colors
+// Brand colors
 // -------------------------
-@blue:                  #049cdb;
-@blueDark:              #0064cd;
-@green:                 #46a546;
-@red:                   #9d261d;
-@yellow:                #ffc40d;
-@orange:                #f89406;
-@pink:                  #c3325f;
-@purple:                #7a43b6;
 
+@brand-primary:         #428bca;
+@brand-success:         #5cb85c;
+@brand-warning:         #f0ad4e;
+@brand-danger:          #d9534f;
+@brand-info:            #5bc0de;
 
 // Scaffolding
 // -------------------------
-@bodyBackground:        @white;
-@textColor:             @grayDark;
 
+@body-bg:               #fff;
+@text-color:            @gray-dark;
 
 // Links
 // -------------------------
-@linkColor:             #08c;
-@linkColorHover:        darken(@linkColor, 15%);
 
+@link-color:            @brand-primary;
+@link-hover-color:      darken(@link-color, 15%);
 
 // Typography
 // -------------------------
-@sansFontFamily:        "Helvetica Neue", Helvetica, Arial, sans-serif;
-@serifFontFamily:       Georgia, "Times New Roman", Times, serif;
-@monoFontFamily:        Monaco, Menlo, Consolas, "Courier New", monospace;
 
-@baseFontSize:          14px;
-@baseFontFamily:        @sansFontFamily;
-@baseLineHeight:        20px;
-@altFontFamily:         @serifFontFamily;
+@font-family-sans-serif:  "Cabin", "Helvetica Neue", Helvetica, Arial, sans-serif;
+@font-family-serif:       Georgia, "Times New Roman", Times, serif;
+@font-family-monospace:   Monaco, Menlo, Consolas, "Courier New", monospace;
+@font-family-base:        @font-family-sans-serif;
 
-@headingsFontFamily:    inherit; // empty to use BS default, @baseFontFamily
-@headingsFontWeight:    bold;    // instead of browser default, bold
-@headingsColor:         inherit; // empty to use BS default, @textColor
+@font-size-base:          14px;
+@font-size-large:         ceil(@font-size-base * 1.25); // ~18px
+@font-size-small:         ceil(@font-size-base * 0.85); // ~12px
 
+@line-height-base:        1.428571429; // 20/14
+@line-height-computed:    floor(@font-size-base * @line-height-base); // ~20px
 
-// Component sizing
+@headings-font-family:    @font-family-base;
+@headings-font-weight:    500;
+@headings-line-height:    1.1;
+
+// Iconography
 // -------------------------
-// Based on 14px font-size and 20px line-height
 
-@fontSizeLarge:         @baseFontSize * 1.25; // ~18px
-@fontSizeSmall:         @baseFontSize * 0.85; // ~12px
-@fontSizeMini:          @baseFontSize * 0.75; // ~11px
+@icon-font-path:          "../fonts/";
+@icon-font-name:          "glyphicons-halflings-regular";
 
-@paddingLarge:          11px 19px; // 44px
-@paddingSmall:          2px 10px;  // 26px
-@paddingMini:           0 6px;   // 22px
 
-@baseBorderRadius:      4px;
-@borderRadiusLarge:     6px;
-@borderRadiusSmall:     3px;
+// Components
+// -------------------------
+// Based on 14px font-size and 1.428 line-height (~20px to start)
 
+@padding-base-vertical:          6px;
+@padding-base-horizontal:        12px;
+
+@padding-large-vertical:         10px;
+@padding-large-horizontal:       16px;
+
+@padding-small-vertical:         5px;
+@padding-small-horizontal:       10px;
+
+@line-height-large:              1.33;
+@line-height-small:              1.5;
+
+@border-radius-base:             4px;
+@border-radius-large:            6px;
+@border-radius-small:            3px;
+
+@component-active-bg:            @brand-primary;
+
+@caret-width-base:               4px;
+@caret-width-large:              5px;
 
 // Tables
 // -------------------------
-@tableBackground:                   transparent; // overall background-color
-@tableBackgroundAccent:             #f9f9f9; // for striping
-@tableBackgroundHover:              #f5f5f5; // for hover
-@tableBorder:                       #ddd; // table and cell border
+
+@table-cell-padding:                 8px;
+@table-condensed-cell-padding:       5px;
+
+@table-bg:                           transparent; // overall background-color
+@table-bg-accent:                    #f9f9f9; // for striping
+@table-bg-hover:                     #f5f5f5;
+@table-bg-active:                    @table-bg-hover;
+
+@table-border-color:                 #ddd; // table and cell border
+
 
 // Buttons
 // -------------------------
-@btnBackground:                     @white;
-@btnBackgroundHighlight:            darken(@white, 10%);
-@btnBorder:                         #ccc;
 
-@btnPrimaryBackground:              @linkColor;
-@btnPrimaryBackgroundHighlight:     spin(@btnPrimaryBackground, 20%);
+@btn-font-weight:                normal;
 
-@btnInfoBackground:                 #5bc0de;
-@btnInfoBackgroundHighlight:        #2f96b4;
+@btn-default-color:              #333;
+@btn-default-bg:                 #fff;
+@btn-default-border:             #ccc;
 
-@btnSuccessBackground:              #62c462;
-@btnSuccessBackgroundHighlight:     #51a351;
+@btn-primary-color:              #fff;
+@btn-primary-bg:                 @brand-primary;
+@btn-primary-border:             darken(@btn-primary-bg, 5%);
 
-@btnWarningBackground:              lighten(@orange, 15%);
-@btnWarningBackgroundHighlight:     @orange;
+@btn-success-color:              #fff;
+@btn-success-bg:                 @brand-success;
+@btn-success-border:             darken(@btn-success-bg, 5%);
 
-@btnDangerBackground:               #ee5f5b;
-@btnDangerBackgroundHighlight:      #bd362f;
+@btn-warning-color:              #fff;
+@btn-warning-bg:                 @brand-warning;
+@btn-warning-border:             darken(@btn-warning-bg, 5%);
 
-@btnInverseBackground:              #444;
-@btnInverseBackgroundHighlight:     @grayDarker;
+@btn-danger-color:               #fff;
+@btn-danger-bg:                  @brand-danger;
+@btn-danger-border:              darken(@btn-danger-bg, 5%);
+
+@btn-info-color:                 #fff;
+@btn-info-bg:                    @brand-info;
+@btn-info-border:                darken(@btn-info-bg, 5%);
+
+@btn-link-disabled-color:        @gray-light;
 
 
 // Forms
 // -------------------------
-@inputBackground:               @white;
-@inputBorder:                   #ccc;
-@inputBorderRadius:             @baseBorderRadius;
-@inputDisabledBackground:       @grayLighter;
-@formActionsBackground:         #f5f5f5;
-@inputHeight:                   @baseLineHeight + 10px; // base line-height + 8px vertical padding + 2px top/bottom border
+
+@input-bg:                       #fff;
+@input-bg-disabled:              @gray-lighter;
+
+@input-color:                    @gray;
+@input-border:                   #ccc;
+@input-border-radius:            @border-radius-base;
+@input-border-focus:             #66afe9;
+
+@input-color-placeholder:        @gray-light;
+
+@input-height-base:              (@line-height-computed + (@padding-base-vertical * 2) + 2);
+@input-height-large:             (floor(@font-size-large * @line-height-large) + (@padding-large-vertical * 2) + 2);
+@input-height-small:             (floor(@font-size-small * @line-height-small) + (@padding-small-vertical * 2) + 2);
+
+@legend-color:                   @gray-dark;
+@legend-border-color:            #e5e5e5;
+
+@input-group-addon-bg:           @gray-lighter;
+@input-group-addon-border-color: @input-border;
 
 
 // Dropdowns
 // -------------------------
-@dropdownBackground:            @white;
-@dropdownBorder:                rgba(0,0,0,.2);
-@dropdownDividerTop:            #e5e5e5;
-@dropdownDividerBottom:         @white;
 
-@dropdownLinkColor:             @grayDark;
-@dropdownLinkColorHover:        @white;
-@dropdownLinkColorActive:       @white;
+@dropdown-bg:                    #fff;
+@dropdown-border:                rgba(0,0,0,.15);
+@dropdown-fallback-border:       #ccc;
+@dropdown-divider-bg:            #e5e5e5;
 
-@dropdownLinkBackgroundActive:  @linkColor;
-@dropdownLinkBackgroundHover:   @dropdownLinkBackgroundActive;
+@dropdown-link-active-color:     #fff;
+@dropdown-link-active-bg:        @component-active-bg;
 
+@dropdown-link-color:            @gray-dark;
+@dropdown-link-hover-color:      #fff;
+@dropdown-link-hover-bg:         @dropdown-link-active-bg;
+
+@dropdown-link-disabled-color:   @gray-light;
+
+@dropdown-header-color:          @gray-light;
+
+@dropdown-caret-color:           #000;
 
 
 // COMPONENT VARIABLES
@@ -141,161 +188,435 @@
 // -------------------------
 // Used for a bird's eye view of components dependent on the z-axis
 // Try to avoid customizing these :)
-@zindexDropdown:          1000;
-@zindexPopover:           1010;
-@zindexTooltip:           1030;
-@zindexFixedNavbar:       1030;
-@zindexModalBackdrop:     1040;
-@zindexModal:             1050;
+
+@zindex-navbar:            1000;
+@zindex-dropdown:          1000;
+@zindex-popover:           1010;
+@zindex-tooltip:           1030;
+@zindex-navbar-fixed:      1030;
+@zindex-modal-background:  1040;
+@zindex-modal:             1050;
+
+// Media queries breakpoints
+// --------------------------------------------------
+
+// Extra small screen / phone
+@screen-xs:                  480px;
+@screen-phone:               @screen-xs;
+
+// Small screen / tablet
+@screen-sm:                  768px;
+@screen-tablet:              @screen-sm;
+
+// Medium screen / desktop
+@screen-md:                  992px;
+@screen-desktop:             @screen-md;
+
+// Large screen / wide desktop
+@screen-lg:                  1600px;
+@screen-lg-desktop:          @screen-lg;
+
+// So media queries don't overlap when required, provide a maximum
+@screen-xs-max:              (@screen-sm - 1);
+@screen-sm-max:              (@screen-md - 1);
+@screen-md-max:              (@screen-lg - 1);
 
 
-// Sprite icons path
-// -------------------------
-@iconSpritePath:          "../img/glyphicons-halflings.png";
-@iconWhiteSpritePath:     "../img/glyphicons-halflings-white.png";
+// Grid system
+// --------------------------------------------------
 
-
-// Input placeholder text color
-// -------------------------
-@placeholderText:         @grayLight;
-
-
-// Hr border color
-// -------------------------
-@hrBorder:                @grayLighter;
-
-
-// Horizontal forms & lists
-// -------------------------
-@horizontalComponentOffset:       180px;
-
-
-// Wells
-// -------------------------
-@wellBackground:                  #f5f5f5;
+// Number of columns in the grid system
+@grid-columns:              12;
+// Padding, to be divided by two and applied to the left and right of all columns
+@grid-gutter-width:         30px;
+// Point at which the navbar stops collapsing
+@grid-float-breakpoint:     @screen-desktop;
 
 
 // Navbar
 // -------------------------
-@navbarCollapseWidth:             979px;
-@navbarCollapseDesktopWidth:      @navbarCollapseWidth + 1;
 
-@navbarHeight:                    40px;
-@navbarBackgroundHighlight:       #ffffff;
-@navbarBackground:                darken(@navbarBackgroundHighlight, 5%);
-@navbarBorder:                    darken(@navbarBackground, 12%);
 
-@navbarText:                      #777;
-@navbarLinkColor:                 #777;
-@navbarLinkColorHover:            @grayDark;
-@navbarLinkColorActive:           @gray;
-@navbarLinkBackgroundHover:       transparent;
-@navbarLinkBackgroundActive:      darken(@navbarBackground, 5%);
+// Basics of a navbar
+@navbar-height:                    50px;
+@navbar-margin-bottom:             @line-height-computed;
+@navbar-default-color:             #777;
+@navbar-default-bg:                #f8f8f8;
+@navbar-default-border:            darken(@navbar-default-bg, 6.5%);
+@navbar-border-radius:             @border-radius-base;
+@navbar-padding-horizontal:        floor(@grid-gutter-width / 2);
+@navbar-padding-vertical:          ((@navbar-height - @line-height-computed) / 2);
 
-@navbarBrandColor:                @navbarLinkColor;
+// Navbar links
+@navbar-default-link-color:                #777;
+@navbar-default-link-hover-color:          #333;
+@navbar-default-link-hover-bg:             transparent;
+@navbar-default-link-active-color:         #555;
+@navbar-default-link-active-bg:            darken(@navbar-default-bg, 6.5%);
+@navbar-default-link-disabled-color:       #ccc;
+@navbar-default-link-disabled-bg:          transparent;
+
+// Navbar brand label
+@navbar-default-brand-color:               @navbar-default-link-color;
+@navbar-default-brand-hover-color:         darken(@navbar-default-link-color, 10%);
+@navbar-default-brand-hover-bg:            transparent;
+
+// Navbar toggle
+@navbar-default-toggle-hover-bg:           #ddd;
+@navbar-default-toggle-icon-bar-bg:        #ccc;
+@navbar-default-toggle-border-color:       #ddd;
+
 
 // Inverted navbar
-@navbarInverseBackground:                #111111;
-@navbarInverseBackgroundHighlight:       #222222;
-@navbarInverseBorder:                    #252525;
+//
+// Reset inverted navbar basics
+@navbar-inverse-color:                      @gray-light;
+@navbar-inverse-bg:                         #222;
+@navbar-inverse-border:                     darken(@navbar-inverse-bg, 10%);
 
-@navbarInverseText:                      @grayLight;
-@navbarInverseLinkColor:                 @grayLight;
-@navbarInverseLinkColorHover:            @white;
-@navbarInverseLinkColorActive:           @navbarInverseLinkColorHover;
-@navbarInverseLinkBackgroundHover:       transparent;
-@navbarInverseLinkBackgroundActive:      @navbarInverseBackground;
+// Inverted navbar links
+@navbar-inverse-link-color:                 @gray-light;
+@navbar-inverse-link-hover-color:           #fff;
+@navbar-inverse-link-hover-bg:              transparent;
+@navbar-inverse-link-active-color:          @navbar-inverse-link-hover-color;
+@navbar-inverse-link-active-bg:             darken(@navbar-inverse-bg, 10%);
+@navbar-inverse-link-disabled-color:        #444;
+@navbar-inverse-link-disabled-bg:           transparent;
 
-@navbarInverseSearchBackground:          lighten(@navbarInverseBackground, 25%);
-@navbarInverseSearchBackgroundFocus:     @white;
-@navbarInverseSearchBorder:              @navbarInverseBackground;
-@navbarInverseSearchPlaceholderColor:    #ccc;
+// Inverted navbar brand label
+@navbar-inverse-brand-color:                @navbar-inverse-link-color;
+@navbar-inverse-brand-hover-color:          #fff;
+@navbar-inverse-brand-hover-bg:             transparent;
 
-@navbarInverseBrandColor:                @navbarInverseLinkColor;
+// Inverted navbar search
+// Normal navbar needs no special styles or vars
+@navbar-inverse-search-bg:                  lighten(@navbar-inverse-bg, 25%);
+@navbar-inverse-search-bg-focus:            #fff;
+@navbar-inverse-search-border:              @navbar-inverse-bg;
+@navbar-inverse-search-placeholder-color:   #ccc;
+
+// Inverted navbar toggle
+@navbar-inverse-toggle-hover-bg:            #333;
+@navbar-inverse-toggle-icon-bar-bg:         #fff;
+@navbar-inverse-toggle-border-color:        #333;
+
+
+// Navs
+// -------------------------
+
+@nav-link-padding:                          10px 15px;
+@nav-link-hover-bg:                         @gray-lighter;
+
+@nav-disabled-link-color:                   @gray-light;
+@nav-disabled-link-hover-color:             @gray-light;
+
+@nav-open-link-hover-color:                 #fff;
+@nav-open-caret-border-color:               #fff;
+
+// Tabs
+@nav-tabs-border-color:                     #ddd;
+
+@nav-tabs-link-hover-border-color:          @gray-lighter;
+
+@nav-tabs-active-link-hover-bg:             @body-bg;
+@nav-tabs-active-link-hover-color:          @gray;
+@nav-tabs-active-link-hover-border-color:   #ddd;
+
+@nav-tabs-justified-link-border-color:            #ddd;
+@nav-tabs-justified-active-link-border-color:     @body-bg;
+
+// Pills
+@nav-pills-active-link-hover-bg:            @component-active-bg;
+@nav-pills-active-link-hover-color:         #fff;
 
 
 // Pagination
 // -------------------------
-@paginationBackground:                #fff;
-@paginationBorder:                    #ddd;
-@paginationActiveBackground:          #f5f5f5;
+
+@pagination-bg:                        #fff;
+@pagination-border:                    #ddd;
+
+@pagination-hover-bg:                  @gray-lighter;
+
+@pagination-active-bg:                 @brand-primary;
+@pagination-active-color:              #fff;
+
+@pagination-disabled-color:            @gray-light;
 
 
-// Hero unit
+// Pager
 // -------------------------
-@heroUnitBackground:              @grayLighter;
-@heroUnitHeadingColor:            inherit;
-@heroUnitLeadColor:               inherit;
+
+@pager-border-radius:                  15px;
+@pager-disabled-color:                 @gray-light;
+
+
+// Jumbotron
+// -------------------------
+
+@jumbotron-padding:              30px;
+@jumbotron-color:                inherit;
+@jumbotron-bg:                   @gray-lighter;
+
+@jumbotron-heading-color:        inherit;
 
 
 // Form states and alerts
 // -------------------------
-@warningText:             #c09853;
-@warningBackground:       #fcf8e3;
-@warningBorder:           darken(spin(@warningBackground, -10), 3%);
 
-@errorText:               #b94a48;
-@errorBackground:         #f2dede;
-@errorBorder:             darken(spin(@errorBackground, -10), 3%);
+@state-warning-text:             #c09853;
+@state-warning-bg:               #fcf8e3;
+@state-warning-border:           darken(spin(@state-warning-bg, -10), 3%);
 
-@successText:             #468847;
-@successBackground:       #dff0d8;
-@successBorder:           darken(spin(@successBackground, -10), 5%);
+@state-danger-text:              #b94a48;
+@state-danger-bg:                #f2dede;
+@state-danger-border:            darken(spin(@state-danger-bg, -10), 3%);
 
-@infoText:                #3a87ad;
-@infoBackground:          #d9edf7;
-@infoBorder:              darken(spin(@infoBackground, -10), 7%);
+@state-success-text:             #468847;
+@state-success-bg:               #dff0d8;
+@state-success-border:           darken(spin(@state-success-bg, -10), 5%);
+
+@state-info-text:                #3a87ad;
+@state-info-bg:                  #d9edf7;
+@state-info-border:              darken(spin(@state-info-bg, -10), 7%);
 
 
-// Tooltips and popovers
+// Tooltips
 // -------------------------
-@tooltipColor:            #fff;
-@tooltipBackground:       #000;
-@tooltipArrowWidth:       5px;
-@tooltipArrowColor:       @tooltipBackground;
+@tooltip-max-width:           200px;
+@tooltip-color:               #fff;
+@tooltip-bg:                  #000;
 
-@popoverBackground:       #fff;
-@popoverArrowWidth:       10px;
-@popoverArrowColor:       #fff;
-@popoverTitleBackground:  darken(@popoverBackground, 3%);
-
-// Special enhancement for popovers
-@popoverArrowOuterWidth:  @popoverArrowWidth + 1;
-@popoverArrowOuterColor:  rgba(0,0,0,.25);
+@tooltip-arrow-width:         5px;
+@tooltip-arrow-color:         @tooltip-bg;
 
 
+// Popovers
+// -------------------------
+@popover-bg:                          #fff;
+@popover-max-width:                   276px;
+@popover-border-color:                rgba(0,0,0,.2);
+@popover-fallback-border-color:       #ccc;
 
-// GRID
+@popover-title-bg:                    darken(@popover-bg, 3%);
+
+@popover-arrow-width:                 10px;
+@popover-arrow-color:                 #fff;
+
+@popover-arrow-outer-width:           (@popover-arrow-width + 1);
+@popover-arrow-outer-color:           rgba(0,0,0,.25);
+@popover-arrow-outer-fallback-color:  #999;
+
+
+// Labels
+// -------------------------
+
+@label-default-bg:            @gray-light;
+@label-primary-bg:            @brand-primary;
+@label-success-bg:            @brand-success;
+@label-info-bg:               @brand-info;
+@label-warning-bg:            @brand-warning;
+@label-danger-bg:             @brand-danger;
+
+@label-color:                 #fff;
+@label-link-hover-color:      #fff;
+
+
+// Modals
+// -------------------------
+@modal-inner-padding:         20px;
+
+@modal-title-padding:         15px;
+@modal-title-line-height:     @line-height-base;
+
+@modal-content-bg:                             #fff;
+@modal-content-border-color:                   rgba(0,0,0,.2);
+@modal-content-fallback-border-color:          #999;
+
+@modal-backdrop-bg:           #000;
+@modal-header-border-color:   #e5e5e5;
+@modal-footer-border-color:   @modal-header-border-color;
+
+
+// Alerts
+// -------------------------
+@alert-padding:               15px;
+@alert-border-radius:         @border-radius-base;
+@alert-link-font-weight:      bold;
+
+@alert-success-bg:            @state-success-bg;
+@alert-success-text:          @state-success-text;
+@alert-success-border:        @state-success-border;
+
+@alert-info-bg:               @state-info-bg;
+@alert-info-text:             @state-info-text;
+@alert-info-border:           @state-info-border;
+
+@alert-warning-bg:            @state-warning-bg;
+@alert-warning-text:          @state-warning-text;
+@alert-warning-border:        @state-warning-border;
+
+@alert-danger-bg:             @state-danger-bg;
+@alert-danger-text:           @state-danger-text;
+@alert-danger-border:         @state-danger-border;
+
+
+// Progress bars
+// -------------------------
+@progress-bg:                 #f5f5f5;
+@progress-bar-color:          #fff;
+
+@progress-bar-bg:             @brand-primary;
+@progress-bar-success-bg:     @brand-success;
+@progress-bar-warning-bg:     @brand-warning;
+@progress-bar-danger-bg:      @brand-danger;
+@progress-bar-info-bg:        @brand-info;
+
+
+// List group
+// -------------------------
+@list-group-bg:               #fff;
+@list-group-border:           #ddd;
+@list-group-border-radius:    @border-radius-base;
+
+@list-group-hover-bg:         #f5f5f5;
+@list-group-active-color:     #fff;
+@list-group-active-bg:        @component-active-bg;
+@list-group-active-border:    @list-group-active-bg;
+
+@list-group-link-color:          #555;
+@list-group-link-heading-color:  #333;
+
+
+// Panels
+// -------------------------
+@panel-bg:                    #fff;
+@panel-inner-border:          #ddd;
+@panel-border-radius:         @border-radius-base;
+@panel-footer-bg:             #f5f5f5;
+
+@panel-default-text:          @gray-dark;
+@panel-default-border:        #ddd;
+@panel-default-heading-bg:    #f5f5f5;
+
+@panel-primary-text:          #fff;
+@panel-primary-border:        @brand-primary;
+@panel-primary-heading-bg:    @brand-primary;
+
+@panel-success-text:          @state-success-text;
+@panel-success-border:        @state-success-border;
+@panel-success-heading-bg:    @state-success-bg;
+
+@panel-warning-text:          @state-warning-text;
+@panel-warning-border:        @state-warning-border;
+@panel-warning-heading-bg:    @state-warning-bg;
+
+@panel-danger-text:           @state-danger-text;
+@panel-danger-border:         @state-danger-border;
+@panel-danger-heading-bg:     @state-danger-bg;
+
+@panel-info-text:             @state-info-text;
+@panel-info-border:           @state-info-border;
+@panel-info-heading-bg:       @state-info-bg;
+
+
+// Thumbnails
+// -------------------------
+@thumbnail-padding:           4px;
+@thumbnail-bg:                @body-bg;
+@thumbnail-border:            #ddd;
+@thumbnail-border-radius:     @border-radius-base;
+
+@thumbnail-caption-color:     @text-color;
+@thumbnail-caption-padding:   9px;
+
+
+// Wells
+// -------------------------
+@well-bg:                     #f5f5f5;
+
+
+// Badges
+// -------------------------
+@badge-color:                 #fff;
+@badge-link-hover-color:      #fff;
+@badge-bg:                    @gray-light;
+
+@badge-active-color:          @link-color;
+@badge-active-bg:             #fff;
+
+@badge-font-weight:           bold;
+@badge-line-height:           1;
+@badge-border-radius:         10px;
+
+
+// Breadcrumbs
+// -------------------------
+@breadcrumb-bg:               #f5f5f5;
+@breadcrumb-color:            #ccc;
+@breadcrumb-active-color:     @gray-light;
+
+
+// Carousel
+// ------------------------
+
+@carousel-text-shadow:                        0 1px 2px rgba(0,0,0,.6);
+
+@carousel-control-color:                      #fff;
+@carousel-control-width:                      15%;
+@carousel-control-opacity:                    .5;
+@carousel-control-font-size:                  20px;
+
+@carousel-indicator-active-bg:                #fff;
+@carousel-indicator-border-color:             #fff;
+
+@carousel-caption-color:                      #fff;
+
+
+// Close
+// ------------------------
+@close-color:                 #000;
+@close-font-weight:           bold;
+@close-text-shadow:           0 1px 0 #fff;
+
+
+// Code
+// ------------------------
+@code-color:                  #c7254e;
+@code-bg:                     #f9f2f4;
+
+@pre-bg:                      #f5f5f5;
+@pre-color:                   @gray-dark;
+@pre-border-color:            #ccc;
+@pre-scrollable-max-height:   340px;
+
+// Type
+// ------------------------
+@text-muted:                  @gray-light;
+@abbr-border-color:           @gray-light;
+@headings-small-color:        @gray-light;
+@blockquote-small-color:      @gray-light;
+@blockquote-border-color:     @gray-lighter;
+@page-header-border-color:    @gray-lighter;
+
+// Miscellaneous
+// -------------------------
+
+// Hr border color
+@hr-border:                   @gray-lighter;
+
+// Horizontal forms & lists
+@component-offset-horizontal: 180px;
+
+
+// Container sizes
 // --------------------------------------------------
 
+// Small screen / tablet
+@container-tablet:            ((720px + @grid-gutter-width));
 
-// Default 940px grid
-// -------------------------
-@gridColumns:             12;
-@gridColumnWidth:         60px;
-@gridGutterWidth:         20px;
-@gridRowWidth:            (@gridColumns * @gridColumnWidth) + (@gridGutterWidth * (@gridColumns - 1));
+// Medium screen / desktop
+@container-desktop:           ((940px + @grid-gutter-width));
 
-// 1200px min
-@gridColumnWidth1200:     70px;
-@gridGutterWidth1200:     30px;
-@gridRowWidth1200:        (@gridColumns * @gridColumnWidth1200) + (@gridGutterWidth1200 * (@gridColumns - 1));
-
-// 768px-979px
-@gridColumnWidth768:      42px;
-@gridGutterWidth768:      20px;
-@gridRowWidth768:         (@gridColumns * @gridColumnWidth768) + (@gridGutterWidth768 * (@gridColumns - 1));
-
-
-// Fluid grid
-// -------------------------
-@fluidGridColumnWidth:    percentage(@gridColumnWidth/@gridRowWidth);
-@fluidGridGutterWidth:    percentage(@gridGutterWidth/@gridRowWidth);
-
-// 1200px min
-@fluidGridColumnWidth1200:     percentage(@gridColumnWidth1200/@gridRowWidth1200);
-@fluidGridGutterWidth1200:     percentage(@gridGutterWidth1200/@gridRowWidth1200);
-
-// 768px-979px
-@fluidGridColumnWidth768:      percentage(@gridColumnWidth768/@gridRowWidth768);
-@fluidGridGutterWidth768:      percentage(@gridGutterWidth768/@gridRowWidth768);
+// Large screen / wide desktop
+@container-lg-desktop:        ((1140px + @grid-gutter-width));
diff --git a/docs/theme/docker/static/img/container3.png b/docs/theme/docker/static/img/container3.png
new file mode 100644
index 0000000..0e8b59f
--- /dev/null
+++ b/docs/theme/docker/static/img/container3.png
Binary files differ
diff --git a/docs/sources/static_files/dockerlogo-h.png b/docs/theme/docker/static/img/dockerlogo-h.png
similarity index 100%
rename from docs/sources/static_files/dockerlogo-h.png
rename to docs/theme/docker/static/img/dockerlogo-h.png
Binary files differ
diff --git a/docs/theme/docker/static/img/menu_arrow_down.gif b/docs/theme/docker/static/img/menu_arrow_down.gif
new file mode 100644
index 0000000..8257c38
--- /dev/null
+++ b/docs/theme/docker/static/img/menu_arrow_down.gif
Binary files differ
diff --git a/docs/theme/docker/static/img/menu_arrow_right.gif b/docs/theme/docker/static/img/menu_arrow_right.gif
new file mode 100644
index 0000000..7dd7253
--- /dev/null
+++ b/docs/theme/docker/static/img/menu_arrow_right.gif
Binary files differ
diff --git a/docs/theme/docker/static/js/docs.js b/docs/theme/docker/static/js/docs.js
index 4c1f25b..769922f 100755
--- a/docs/theme/docker/static/js/docs.js
+++ b/docs/theme/docker/static/js/docs.js
@@ -1,37 +1,98 @@
 
+// This script should be included at the END of the document. 
+// For the fastest loading it does not inlude $(document).ready()
+
+// This Document contains a few helper functions for the documentation to display the current version,
+// collapse and expand the menu etc.
+
+
+// Function to make the sticky header possible
+function shiftWindow() { 
+    scrollBy(0, -70);
+    console.log("window shifted")
+}
+
+window.addEventListener("hashchange", shiftWindow);
+
+function loadShift() {
+    if (window.location.hash) {
+        console.log("window has hash");
+        shiftWindow();
+    }
+}
+
+$(window).load(function() {
+    loadShift();
+});
+
 $(function(){
 
-    // init multi-vers stuff
-    $('.tabswitcher').each(function(i, multi_vers){
-        var tabs = $('<ul></ul>');
-        $(multi_vers).prepend(tabs);
-        $(multi_vers).children('.tab').each(function(j, vers_content){
-            vers = $(vers_content).children(':first').text();
-            var id = 'multi_vers_' + '_' + i + '_' + j;
-            $(vers_content).attr('id', id);
-            $(tabs).append('<li><a href="#' + id + '">' + vers + '</a></li>');
-        });
+    // sidebar accordian-ing
+    // don't apply on last object (it should be the FAQ) or the first (it should be introduction)
+
+    // define an array to which all opened items should be added
+    var openmenus = [];
+
+    var elements = $('.toctree-l2');
+    // for (var i = 0; i < elements.length; i += 1) { var current = $(elements[i]); current.children('ul').hide();}
+
+
+    // set initial collapsed state
+    var elements = $('.toctree-l1');
+    for (var i = 0; i < elements.length; i += 1) {
+        var current = $(elements[i]);
+        if (current.hasClass('current')) {
+            current.addClass('open');
+            currentlink = current.children('a')[0].href;
+            openmenus.push(currentlink);
+
+            // do nothing
+        } else {
+            // collapse children
+            current.children('ul').hide();
+        }
+    }
+
+    if (doc_version == "") {
+        $('.version-flyer ul').html('<li class="alternative active-slug"><a href="" title="Switch to local">Local</a></li>');
+    }
+
+    // mark the active documentation in the version widget
+    $(".version-flyer a:contains('" + doc_version + "')").parent().addClass('active-slug');
+
+
+    // attached handler on click
+    // Do not attach to first element or last (intro, faq) so that
+    // first and last link directly instead of accordian
+    $('.sidebar > ul > li > a').not(':last').not(':first').click(function(){
+
+        var index = $.inArray(this.href, openmenus)
+
+        if (index > -1) {
+            console.log(index);
+            openmenus.splice(index, 1);
+
+
+            $(this).parent().children('ul').slideUp(200, function() {
+                $(this).parent().removeClass('open'); // toggle after effect
+            });
+        }
+        else {
+            openmenus.push(this.href);
+
+            var current = $(this);
+
+            setTimeout(function() {
+                // $('.sidebar > ul > li').removeClass('current');
+                current.parent().addClass('current').addClass('open'); // toggle before effect
+                current.parent().children('ul').hide();
+                current.parent().children('ul').slideDown(200);
+            }, 100);
+        }
+        return false;
     });
-    $( ".tabswitcher" ).tabs();
-    
-    // sidebar acordian-ing
-    // don't apply on last object (it should be the FAQ)
-   $('nav > ul > li > a').not(':last').click(function(){
-	if ($(this).parent().hasClass('current')) {
-	    $(this).parent().children('ul').slideUp(200, function() {
-		$(this).parent().removeClass('current'); // toggle after effect
-	    });
-	} else {
-	    $('nav > ul > li > ul').slideUp(100);
-	    var current = $(this);
-	    setTimeout(function() {      
-		$('nav > ul > li').removeClass('current');
-		current.parent().addClass('current'); // toggle before effect
-		current.parent().children('ul').hide();
-		current.parent().children('ul').slideDown(200);
-	    }, 100);
-	}
-	return false;
-     });
-  
+
+    // add class to all those which have children
+    $('.sidebar > ul > li').not(':last').not(':first').addClass('has-children');
+
 });
\ No newline at end of file
diff --git a/docs/theme/docker/static/js/jquery.ba-bbq.min.js b/docs/theme/docker/static/js/jquery.ba-bbq.min.js
deleted file mode 100755
index bcbf248..0000000
--- a/docs/theme/docker/static/js/jquery.ba-bbq.min.js
+++ /dev/null
@@ -1,18 +0,0 @@
-/*
- * jQuery BBQ: Back Button & Query Library - v1.2.1 - 2/17/2010
- * http://benalman.com/projects/jquery-bbq-plugin/
- * 
- * Copyright (c) 2010 "Cowboy" Ben Alman
- * Dual licensed under the MIT and GPL licenses.
- * http://benalman.com/about/license/
- */
-(function($,p){var i,m=Array.prototype.slice,r=decodeURIComponent,a=$.param,c,l,v,b=$.bbq=$.bbq||{},q,u,j,e=$.event.special,d="hashchange",A="querystring",D="fragment",y="elemUrlAttr",g="location",k="href",t="src",x=/^.*\?|#.*$/g,w=/^.*\#/,h,C={};function E(F){return typeof F==="string"}function B(G){var F=m.call(arguments,1);return function(){return G.apply(this,F.concat(m.call(arguments)))}}function n(F){return F.replace(/^[^#]*#?(.*)$/,"$1")}function o(F){return F.replace(/(?:^[^?#]*\?([^#]*).*$)?.*/,"$1")}function f(H,M,F,I,G){var O,L,K,N,J;if(I!==i){K=F.match(H?/^([^#]*)\#?(.*)$/:/^([^#?]*)\??([^#]*)(#?.*)/);J=K[3]||"";if(G===2&&E(I)){L=I.replace(H?w:x,"")}else{N=l(K[2]);I=E(I)?l[H?D:A](I):I;L=G===2?I:G===1?$.extend({},I,N):$.extend({},N,I);L=a(L);if(H){L=L.replace(h,r)}}O=K[1]+(H?"#":L||!K[1]?"?":"")+L+J}else{O=M(F!==i?F:p[g][k])}return O}a[A]=B(f,0,o);a[D]=c=B(f,1,n);c.noEscape=function(G){G=G||"";var F=$.map(G.split(""),encodeURIComponent);h=new RegExp(F.join("|"),"g")};c.noEscape(",/");$.deparam=l=function(I,F){var H={},G={"true":!0,"false":!1,"null":null};$.each(I.replace(/\+/g," ").split("&"),function(L,Q){var K=Q.split("="),P=r(K[0]),J,O=H,M=0,R=P.split("]["),N=R.length-1;if(/\[/.test(R[0])&&/\]$/.test(R[N])){R[N]=R[N].replace(/\]$/,"");R=R.shift().split("[").concat(R);N=R.length-1}else{N=0}if(K.length===2){J=r(K[1]);if(F){J=J&&!isNaN(J)?+J:J==="undefined"?i:G[J]!==i?G[J]:J}if(N){for(;M<=N;M++){P=R[M]===""?O.length:R[M];O=O[P]=M<N?O[P]||(R[M+1]&&isNaN(R[M+1])?{}:[]):J}}else{if($.isArray(H[P])){H[P].push(J)}else{if(H[P]!==i){H[P]=[H[P],J]}else{H[P]=J}}}}else{if(P){H[P]=F?i:""}}});return H};function z(H,F,G){if(F===i||typeof F==="boolean"){G=F;F=a[H?D:A]()}else{F=E(F)?F.replace(H?w:x,""):F}return l(F,G)}l[A]=B(z,0);l[D]=v=B(z,1);$[y]||($[y]=function(F){return $.extend(C,F)})({a:k,base:k,iframe:t,img:t,input:t,form:"action",link:k,script:t});j=$[y];function s(I,G,H,F){if(!E(H)&&typeof H!=="object"){F=H;H=G;G=i}return this.each(function(){var L=$(this),J=G||j()[(this.nodeName||"").toLowerCase()]||"",K=J&&L.attr(J)||"";L.attr(J,a[I](K,H,F))})}$.fn[A]=B(s,A);$.fn[D]=B(s,D);b.pushState=q=function(I,F){if(E(I)&&/^#/.test(I)&&F===i){F=2}var H=I!==i,G=c(p[g][k],H?I:{},H?F:2);p[g][k]=G+(/#/.test(G)?"":"#")};b.getState=u=function(F,G){return F===i||typeof F==="boolean"?v(F):v(G)[F]};b.removeState=function(F){var G={};if(F!==i){G=u();$.each($.isArray(F)?F:arguments,function(I,H){delete G[H]})}q(G,2)};e[d]=$.extend(e[d],{add:function(F){var H;function G(J){var I=J[D]=c();J.getState=function(K,L){return K===i||typeof K==="boolean"?l(I,K):l(I,L)[K]};H.apply(this,arguments)}if($.isFunction(F)){H=F;return G}else{H=F.handler;F.handler=G}}})})(jQuery,this);
-/*
- * jQuery hashchange event - v1.2 - 2/11/2010
- * http://benalman.com/projects/jquery-hashchange-plugin/
- * 
- * Copyright (c) 2010 "Cowboy" Ben Alman
- * Dual licensed under the MIT and GPL licenses.
- * http://benalman.com/about/license/
- */
-(function($,i,b){var j,k=$.event.special,c="location",d="hashchange",l="href",f=$.browser,g=document.documentMode,h=f.msie&&(g===b||g<8),e="on"+d in i&&!h;function a(m){m=m||i[c][l];return m.replace(/^[^#]*#?(.*)$/,"$1")}$[d+"Delay"]=100;k[d]=$.extend(k[d],{setup:function(){if(e){return false}$(j.start)},teardown:function(){if(e){return false}$(j.stop)}});j=(function(){var m={},r,n,o,q;function p(){o=q=function(s){return s};if(h){n=$('<iframe src="javascript:0"/>').hide().insertAfter("body")[0].contentWindow;q=function(){return a(n.document[c][l])};o=function(u,s){if(u!==s){var t=n.document;t.open().close();t[c].hash="#"+u}};o(a())}}m.start=function(){if(r){return}var t=a();o||p();(function s(){var v=a(),u=q(t);if(v!==t){o(t=v,u);$(i).trigger(d)}else{if(u!==t){i[c][l]=i[c][l].replace(/#.*/,"")+"#"+u}}r=setTimeout(s,$[d+"Delay"])})()};m.stop=function(){if(!n){r&&clearTimeout(r);r=0}};return m})()})(jQuery,this);
\ No newline at end of file
diff --git a/docs/theme/docker/static/js/jquery.ba-urlinternal.min.js b/docs/theme/docker/static/js/jquery.ba-urlinternal.min.js
deleted file mode 100755
index 921b7d7..0000000
--- a/docs/theme/docker/static/js/jquery.ba-urlinternal.min.js
+++ /dev/null
@@ -1,9 +0,0 @@
-/*
- * urlInternal - v1.0 - 10/7/2009
- * http://benalman.com/projects/jquery-urlinternal-plugin/
- * 
- * Copyright (c) 2009 "Cowboy" Ben Alman
- * Dual licensed under the MIT and GPL licenses.
- * http://benalman.com/about/license/
- */
-(function($){var g,i=!0,r=!1,m=window.location,h=Array.prototype.slice,b=m.href.match(/^((https?:\/\/.*?\/)?[^#]*)#?.*$/),u=b[1]+"#",t=b[2],e,l,f,q,c,j,x="elemUrlAttr",k="href",y="src",p="urlInternal",d="urlExternal",n="urlFragment",a,s={};function w(A){var z=h.call(arguments,1);return function(){return A.apply(this,z.concat(h.call(arguments)))}}$.isUrlInternal=q=function(z){if(!z||j(z)){return g}if(a.test(z)){return i}if(/^(?:https?:)?\/\//i.test(z)){return r}if(/^[a-z\d.-]+:/i.test(z)){return g}return i};$.isUrlExternal=c=function(z){var A=q(z);return typeof A==="boolean"?!A:A};$.isUrlFragment=j=function(z){var A=(z||"").match(/^([^#]?)([^#]*#).*$/);return !!A&&(A[2]==="#"||z.indexOf(u)===0||(A[1]==="/"?t+A[2]===u:!/^https?:\/\//i.test(z)&&$('<a href="'+z+'"/>')[0].href.indexOf(u)===0))};function v(A,z){return this.filter(":"+A+(z?"("+z+")":""))}$.fn[p]=w(v,p);$.fn[d]=w(v,d);$.fn[n]=w(v,n);function o(D,C,B,A){var z=A[3]||e()[(C.nodeName||"").toLowerCase()]||"";return z?!!D(C.getAttribute(z)):r}$.expr[":"][p]=w(o,q);$.expr[":"][d]=w(o,c);$.expr[":"][n]=w(o,j);$[x]||($[x]=function(z){return $.extend(s,z)})({a:k,base:k,iframe:y,img:y,input:y,form:"action",link:k,script:y});e=$[x];$.urlInternalHost=l=function(B){B=B?"(?:(?:"+Array.prototype.join.call(arguments,"|")+")\\.)?":"";var A=new RegExp("^"+B+"(.*)","i"),z="^(?:"+m.protocol+")?//"+m.hostname.replace(A,B+"$1").replace(/\\?\./g,"\\.")+(m.port?":"+m.port:"")+"/";return f(z)};$.urlInternalRegExp=f=function(z){if(z){a=typeof z==="string"?new RegExp(z,"i"):z}return a};l("www")})(jQuery);
\ No newline at end of file
diff --git a/docs/theme/docker/static/js/main.js b/docs/theme/docker/static/js/main.js
deleted file mode 100755
index 8b13789..0000000
--- a/docs/theme/docker/static/js/main.js
+++ /dev/null
@@ -1 +0,0 @@
-
diff --git a/docs/theme/docker/static/js/vendor/bootstrap.js b/docs/theme/docker/static/js/vendor/bootstrap.js
deleted file mode 100755
index a81171b..0000000
--- a/docs/theme/docker/static/js/vendor/bootstrap.js
+++ /dev/null
@@ -1,2268 +0,0 @@
-/* ===================================================
- * bootstrap-transition.js v2.3.0
- * http://twitter.github.com/bootstrap/javascript.html#transitions
- * ===================================================
- * Copyright 2012 Twitter, Inc.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- * ========================================================== */
-
-
-!function ($) {
-
-  "use strict"; // jshint ;_;
-
-
-  /* CSS TRANSITION SUPPORT (http://www.modernizr.com/)
-   * ======================================================= */
-
-  $(function () {
-
-    $.support.transition = (function () {
-
-      var transitionEnd = (function () {
-
-        var el = document.createElement('bootstrap')
-          , transEndEventNames = {
-               'WebkitTransition' : 'webkitTransitionEnd'
-            ,  'MozTransition'    : 'transitionend'
-            ,  'OTransition'      : 'oTransitionEnd otransitionend'
-            ,  'transition'       : 'transitionend'
-            }
-          , name
-
-        for (name in transEndEventNames){
-          if (el.style[name] !== undefined) {
-            return transEndEventNames[name]
-          }
-        }
-
-      }())
-
-      return transitionEnd && {
-        end: transitionEnd
-      }
-
-    })()
-
-  })
-
-}(window.jQuery);/* ==========================================================
- * bootstrap-alert.js v2.3.0
- * http://twitter.github.com/bootstrap/javascript.html#alerts
- * ==========================================================
- * Copyright 2012 Twitter, Inc.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- * ========================================================== */
-
-
-!function ($) {
-
-  "use strict"; // jshint ;_;
-
-
- /* ALERT CLASS DEFINITION
-  * ====================== */
-
-  var dismiss = '[data-dismiss="alert"]'
-    , Alert = function (el) {
-        $(el).on('click', dismiss, this.close)
-      }
-
-  Alert.prototype.close = function (e) {
-    var $this = $(this)
-      , selector = $this.attr('data-target')
-      , $parent
-
-    if (!selector) {
-      selector = $this.attr('href')
-      selector = selector && selector.replace(/.*(?=#[^\s]*$)/, '') //strip for ie7
-    }
-
-    $parent = $(selector)
-
-    e && e.preventDefault()
-
-    $parent.length || ($parent = $this.hasClass('alert') ? $this : $this.parent())
-
-    $parent.trigger(e = $.Event('close'))
-
-    if (e.isDefaultPrevented()) return
-
-    $parent.removeClass('in')
-
-    function removeElement() {
-      $parent
-        .trigger('closed')
-        .remove()
-    }
-
-    $.support.transition && $parent.hasClass('fade') ?
-      $parent.on($.support.transition.end, removeElement) :
-      removeElement()
-  }
-
-
- /* ALERT PLUGIN DEFINITION
-  * ======================= */
-
-  var old = $.fn.alert
-
-  $.fn.alert = function (option) {
-    return this.each(function () {
-      var $this = $(this)
-        , data = $this.data('alert')
-      if (!data) $this.data('alert', (data = new Alert(this)))
-      if (typeof option == 'string') data[option].call($this)
-    })
-  }
-
-  $.fn.alert.Constructor = Alert
-
-
- /* ALERT NO CONFLICT
-  * ================= */
-
-  $.fn.alert.noConflict = function () {
-    $.fn.alert = old
-    return this
-  }
-
-
- /* ALERT DATA-API
-  * ============== */
-
-  $(document).on('click.alert.data-api', dismiss, Alert.prototype.close)
-
-}(window.jQuery);/* ============================================================
- * bootstrap-button.js v2.3.0
- * http://twitter.github.com/bootstrap/javascript.html#buttons
- * ============================================================
- * Copyright 2012 Twitter, Inc.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- * ============================================================ */
-
-
-!function ($) {
-
-  "use strict"; // jshint ;_;
-
-
- /* BUTTON PUBLIC CLASS DEFINITION
-  * ============================== */
-
-  var Button = function (element, options) {
-    this.$element = $(element)
-    this.options = $.extend({}, $.fn.button.defaults, options)
-  }
-
-  Button.prototype.setState = function (state) {
-    var d = 'disabled'
-      , $el = this.$element
-      , data = $el.data()
-      , val = $el.is('input') ? 'val' : 'html'
-
-    state = state + 'Text'
-    data.resetText || $el.data('resetText', $el[val]())
-
-    $el[val](data[state] || this.options[state])
-
-    // push to event loop to allow forms to submit
-    setTimeout(function () {
-      state == 'loadingText' ?
-        $el.addClass(d).attr(d, d) :
-        $el.removeClass(d).removeAttr(d)
-    }, 0)
-  }
-
-  Button.prototype.toggle = function () {
-    var $parent = this.$element.closest('[data-toggle="buttons-radio"]')
-
-    $parent && $parent
-      .find('.active')
-      .removeClass('active')
-
-    this.$element.toggleClass('active')
-  }
-
-
- /* BUTTON PLUGIN DEFINITION
-  * ======================== */
-
-  var old = $.fn.button
-
-  $.fn.button = function (option) {
-    return this.each(function () {
-      var $this = $(this)
-        , data = $this.data('button')
-        , options = typeof option == 'object' && option
-      if (!data) $this.data('button', (data = new Button(this, options)))
-      if (option == 'toggle') data.toggle()
-      else if (option) data.setState(option)
-    })
-  }
-
-  $.fn.button.defaults = {
-    loadingText: 'loading...'
-  }
-
-  $.fn.button.Constructor = Button
-
-
- /* BUTTON NO CONFLICT
-  * ================== */
-
-  $.fn.button.noConflict = function () {
-    $.fn.button = old
-    return this
-  }
-
-
- /* BUTTON DATA-API
-  * =============== */
-
-  $(document).on('click.button.data-api', '[data-toggle^=button]', function (e) {
-    var $btn = $(e.target)
-    if (!$btn.hasClass('btn')) $btn = $btn.closest('.btn')
-    $btn.button('toggle')
-  })
-
-}(window.jQuery);/* ==========================================================
- * bootstrap-carousel.js v2.3.0
- * http://twitter.github.com/bootstrap/javascript.html#carousel
- * ==========================================================
- * Copyright 2012 Twitter, Inc.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- * ========================================================== */
-
-
-!function ($) {
-
-  "use strict"; // jshint ;_;
-
-
- /* CAROUSEL CLASS DEFINITION
-  * ========================= */
-
-  var Carousel = function (element, options) {
-    this.$element = $(element)
-    this.$indicators = this.$element.find('.carousel-indicators')
-    this.options = options
-    this.options.pause == 'hover' && this.$element
-      .on('mouseenter', $.proxy(this.pause, this))
-      .on('mouseleave', $.proxy(this.cycle, this))
-  }
-
-  Carousel.prototype = {
-
-    cycle: function (e) {
-      if (!e) this.paused = false
-      if (this.interval) clearInterval(this.interval);
-      this.options.interval
-        && !this.paused
-        && (this.interval = setInterval($.proxy(this.next, this), this.options.interval))
-      return this
-    }
-
-  , getActiveIndex: function () {
-      this.$active = this.$element.find('.item.active')
-      this.$items = this.$active.parent().children()
-      return this.$items.index(this.$active)
-    }
-
-  , to: function (pos) {
-      var activeIndex = this.getActiveIndex()
-        , that = this
-
-      if (pos > (this.$items.length - 1) || pos < 0) return
-
-      if (this.sliding) {
-        return this.$element.one('slid', function () {
-          that.to(pos)
-        })
-      }
-
-      if (activeIndex == pos) {
-        return this.pause().cycle()
-      }
-
-      return this.slide(pos > activeIndex ? 'next' : 'prev', $(this.$items[pos]))
-    }
-
-  , pause: function (e) {
-      if (!e) this.paused = true
-      if (this.$element.find('.next, .prev').length && $.support.transition.end) {
-        this.$element.trigger($.support.transition.end)
-        this.cycle()
-      }
-      clearInterval(this.interval)
-      this.interval = null
-      return this
-    }
-
-  , next: function () {
-      if (this.sliding) return
-      return this.slide('next')
-    }
-
-  , prev: function () {
-      if (this.sliding) return
-      return this.slide('prev')
-    }
-
-  , slide: function (type, next) {
-      var $active = this.$element.find('.item.active')
-        , $next = next || $active[type]()
-        , isCycling = this.interval
-        , direction = type == 'next' ? 'left' : 'right'
-        , fallback  = type == 'next' ? 'first' : 'last'
-        , that = this
-        , e
-
-      this.sliding = true
-
-      isCycling && this.pause()
-
-      $next = $next.length ? $next : this.$element.find('.item')[fallback]()
-
-      e = $.Event('slide', {
-        relatedTarget: $next[0]
-      , direction: direction
-      })
-
-      if ($next.hasClass('active')) return
-
-      if (this.$indicators.length) {
-        this.$indicators.find('.active').removeClass('active')
-        this.$element.one('slid', function () {
-          var $nextIndicator = $(that.$indicators.children()[that.getActiveIndex()])
-          $nextIndicator && $nextIndicator.addClass('active')
-        })
-      }
-
-      if ($.support.transition && this.$element.hasClass('slide')) {
-        this.$element.trigger(e)
-        if (e.isDefaultPrevented()) return
-        $next.addClass(type)
-        $next[0].offsetWidth // force reflow
-        $active.addClass(direction)
-        $next.addClass(direction)
-        this.$element.one($.support.transition.end, function () {
-          $next.removeClass([type, direction].join(' ')).addClass('active')
-          $active.removeClass(['active', direction].join(' '))
-          that.sliding = false
-          setTimeout(function () { that.$element.trigger('slid') }, 0)
-        })
-      } else {
-        this.$element.trigger(e)
-        if (e.isDefaultPrevented()) return
-        $active.removeClass('active')
-        $next.addClass('active')
-        this.sliding = false
-        this.$element.trigger('slid')
-      }
-
-      isCycling && this.cycle()
-
-      return this
-    }
-
-  }
-
-
- /* CAROUSEL PLUGIN DEFINITION
-  * ========================== */
-
-  var old = $.fn.carousel
-
-  $.fn.carousel = function (option) {
-    return this.each(function () {
-      var $this = $(this)
-        , data = $this.data('carousel')
-        , options = $.extend({}, $.fn.carousel.defaults, typeof option == 'object' && option)
-        , action = typeof option == 'string' ? option : options.slide
-      if (!data) $this.data('carousel', (data = new Carousel(this, options)))
-      if (typeof option == 'number') data.to(option)
-      else if (action) data[action]()
-      else if (options.interval) data.pause().cycle()
-    })
-  }
-
-  $.fn.carousel.defaults = {
-    interval: 5000
-  , pause: 'hover'
-  }
-
-  $.fn.carousel.Constructor = Carousel
-
-
- /* CAROUSEL NO CONFLICT
-  * ==================== */
-
-  $.fn.carousel.noConflict = function () {
-    $.fn.carousel = old
-    return this
-  }
-
- /* CAROUSEL DATA-API
-  * ================= */
-
-  $(document).on('click.carousel.data-api', '[data-slide], [data-slide-to]', function (e) {
-    var $this = $(this), href
-      , $target = $($this.attr('data-target') || (href = $this.attr('href')) && href.replace(/.*(?=#[^\s]+$)/, '')) //strip for ie7
-      , options = $.extend({}, $target.data(), $this.data())
-      , slideIndex
-
-    $target.carousel(options)
-
-    if (slideIndex = $this.attr('data-slide-to')) {
-      $target.data('carousel').pause().to(slideIndex).cycle()
-    }
-
-    e.preventDefault()
-  })
-
-}(window.jQuery);/* =============================================================
- * bootstrap-collapse.js v2.3.0
- * http://twitter.github.com/bootstrap/javascript.html#collapse
- * =============================================================
- * Copyright 2012 Twitter, Inc.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- * ============================================================ */
-
-
-!function ($) {
-
-  "use strict"; // jshint ;_;
-
-
- /* COLLAPSE PUBLIC CLASS DEFINITION
-  * ================================ */
-
-  var Collapse = function (element, options) {
-    this.$element = $(element)
-    this.options = $.extend({}, $.fn.collapse.defaults, options)
-
-    if (this.options.parent) {
-      this.$parent = $(this.options.parent)
-    }
-
-    this.options.toggle && this.toggle()
-  }
-
-  Collapse.prototype = {
-
-    constructor: Collapse
-
-  , dimension: function () {
-      var hasWidth = this.$element.hasClass('width')
-      return hasWidth ? 'width' : 'height'
-    }
-
-  , show: function () {
-      var dimension
-        , scroll
-        , actives
-        , hasData
-
-      if (this.transitioning || this.$element.hasClass('in')) return
-
-      dimension = this.dimension()
-      scroll = $.camelCase(['scroll', dimension].join('-'))
-      actives = this.$parent && this.$parent.find('> .accordion-group > .in')
-
-      if (actives && actives.length) {
-        hasData = actives.data('collapse')
-        if (hasData && hasData.transitioning) return
-        actives.collapse('hide')
-        hasData || actives.data('collapse', null)
-      }
-
-      this.$element[dimension](0)
-      this.transition('addClass', $.Event('show'), 'shown')
-      $.support.transition && this.$element[dimension](this.$element[0][scroll])
-    }
-
-  , hide: function () {
-      var dimension
-      if (this.transitioning || !this.$element.hasClass('in')) return
-      dimension = this.dimension()
-      this.reset(this.$element[dimension]())
-      this.transition('removeClass', $.Event('hide'), 'hidden')
-      this.$element[dimension](0)
-    }
-
-  , reset: function (size) {
-      var dimension = this.dimension()
-
-      this.$element
-        .removeClass('collapse')
-        [dimension](size || 'auto')
-        [0].offsetWidth
-
-      this.$element[size !== null ? 'addClass' : 'removeClass']('collapse')
-
-      return this
-    }
-
-  , transition: function (method, startEvent, completeEvent) {
-      var that = this
-        , complete = function () {
-            if (startEvent.type == 'show') that.reset()
-            that.transitioning = 0
-            that.$element.trigger(completeEvent)
-          }
-
-      this.$element.trigger(startEvent)
-
-      if (startEvent.isDefaultPrevented()) return
-
-      this.transitioning = 1
-
-      this.$element[method]('in')
-
-      $.support.transition && this.$element.hasClass('collapse') ?
-        this.$element.one($.support.transition.end, complete) :
-        complete()
-    }
-
-  , toggle: function () {
-      this[this.$element.hasClass('in') ? 'hide' : 'show']()
-    }
-
-  }
-
-
- /* COLLAPSE PLUGIN DEFINITION
-  * ========================== */
-
-  var old = $.fn.collapse
-
-  $.fn.collapse = function (option) {
-    return this.each(function () {
-      var $this = $(this)
-        , data = $this.data('collapse')
-        , options = $.extend({}, $.fn.collapse.defaults, $this.data(), typeof option == 'object' && option)
-      if (!data) $this.data('collapse', (data = new Collapse(this, options)))
-      if (typeof option == 'string') data[option]()
-    })
-  }
-
-  $.fn.collapse.defaults = {
-    toggle: true
-  }
-
-  $.fn.collapse.Constructor = Collapse
-
-
- /* COLLAPSE NO CONFLICT
-  * ==================== */
-
-  $.fn.collapse.noConflict = function () {
-    $.fn.collapse = old
-    return this
-  }
-
-
- /* COLLAPSE DATA-API
-  * ================= */
-
-  $(document).on('click.collapse.data-api', '[data-toggle=collapse]', function (e) {
-    var $this = $(this), href
-      , target = $this.attr('data-target')
-        || e.preventDefault()
-        || (href = $this.attr('href')) && href.replace(/.*(?=#[^\s]+$)/, '') //strip for ie7
-      , option = $(target).data('collapse') ? 'toggle' : $this.data()
-    $this[$(target).hasClass('in') ? 'addClass' : 'removeClass']('collapsed')
-    $(target).collapse(option)
-  })
-
-}(window.jQuery);/* ============================================================
- * bootstrap-dropdown.js v2.3.0
- * http://twitter.github.com/bootstrap/javascript.html#dropdowns
- * ============================================================
- * Copyright 2012 Twitter, Inc.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- * ============================================================ */
-
-
-!function ($) {
-
-  "use strict"; // jshint ;_;
-
-
- /* DROPDOWN CLASS DEFINITION
-  * ========================= */
-
-  var toggle = '[data-toggle=dropdown]'
-    , Dropdown = function (element) {
-        var $el = $(element).on('click.dropdown.data-api', this.toggle)
-        $('html').on('click.dropdown.data-api', function () {
-          $el.parent().removeClass('open')
-        })
-      }
-
-  Dropdown.prototype = {
-
-    constructor: Dropdown
-
-  , toggle: function (e) {
-      var $this = $(this)
-        , $parent
-        , isActive
-
-      if ($this.is('.disabled, :disabled')) return
-
-      $parent = getParent($this)
-
-      isActive = $parent.hasClass('open')
-
-      clearMenus()
-
-      if (!isActive) {
-        $parent.toggleClass('open')
-      }
-
-      $this.focus()
-
-      return false
-    }
-
-  , keydown: function (e) {
-      var $this
-        , $items
-        , $active
-        , $parent
-        , isActive
-        , index
-
-      if (!/(38|40|27)/.test(e.keyCode)) return
-
-      $this = $(this)
-
-      e.preventDefault()
-      e.stopPropagation()
-
-      if ($this.is('.disabled, :disabled')) return
-
-      $parent = getParent($this)
-
-      isActive = $parent.hasClass('open')
-
-      if (!isActive || (isActive && e.keyCode == 27)) {
-        if (e.which == 27) $parent.find(toggle).focus()
-        return $this.click()
-      }
-
-      $items = $('[role=menu] li:not(.divider):visible a', $parent)
-
-      if (!$items.length) return
-
-      index = $items.index($items.filter(':focus'))
-
-      if (e.keyCode == 38 && index > 0) index--                                        // up
-      if (e.keyCode == 40 && index < $items.length - 1) index++                        // down
-      if (!~index) index = 0
-
-      $items
-        .eq(index)
-        .focus()
-    }
-
-  }
-
-  function clearMenus() {
-    $(toggle).each(function () {
-      getParent($(this)).removeClass('open')
-    })
-  }
-
-  function getParent($this) {
-    var selector = $this.attr('data-target')
-      , $parent
-
-    if (!selector) {
-      selector = $this.attr('href')
-      selector = selector && /#/.test(selector) && selector.replace(/.*(?=#[^\s]*$)/, '') //strip for ie7
-    }
-
-    $parent = selector && $(selector)
-
-    if (!$parent || !$parent.length) $parent = $this.parent()
-
-    return $parent
-  }
-
-
-  /* DROPDOWN PLUGIN DEFINITION
-   * ========================== */
-
-  var old = $.fn.dropdown
-
-  $.fn.dropdown = function (option) {
-    return this.each(function () {
-      var $this = $(this)
-        , data = $this.data('dropdown')
-      if (!data) $this.data('dropdown', (data = new Dropdown(this)))
-      if (typeof option == 'string') data[option].call($this)
-    })
-  }
-
-  $.fn.dropdown.Constructor = Dropdown
-
-
- /* DROPDOWN NO CONFLICT
-  * ==================== */
-
-  $.fn.dropdown.noConflict = function () {
-    $.fn.dropdown = old
-    return this
-  }
-
-
-  /* APPLY TO STANDARD DROPDOWN ELEMENTS
-   * =================================== */
-
-  $(document)
-    .on('click.dropdown.data-api', clearMenus)
-    .on('click.dropdown.data-api', '.dropdown form', function (e) { e.stopPropagation() })
-    .on('.dropdown-menu', function (e) { e.stopPropagation() })
-    .on('click.dropdown.data-api'  , toggle, Dropdown.prototype.toggle)
-    .on('keydown.dropdown.data-api', toggle + ', [role=menu]' , Dropdown.prototype.keydown)
-
-}(window.jQuery);
-/* =========================================================
- * bootstrap-modal.js v2.3.0
- * http://twitter.github.com/bootstrap/javascript.html#modals
- * =========================================================
- * Copyright 2012 Twitter, Inc.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- * ========================================================= */
-
-
-!function ($) {
-
-  "use strict"; // jshint ;_;
-
-
- /* MODAL CLASS DEFINITION
-  * ====================== */
-
-  var Modal = function (element, options) {
-    this.options = options
-    this.$element = $(element)
-      .delegate('[data-dismiss="modal"]', 'click.dismiss.modal', $.proxy(this.hide, this))
-    this.options.remote && this.$element.find('.modal-body').load(this.options.remote)
-  }
-
-  Modal.prototype = {
-
-      constructor: Modal
-
-    , toggle: function () {
-        return this[!this.isShown ? 'show' : 'hide']()
-      }
-
-    , show: function () {
-        var that = this
-          , e = $.Event('show')
-
-        this.$element.trigger(e)
-
-        if (this.isShown || e.isDefaultPrevented()) return
-
-        this.isShown = true
-
-        this.escape()
-
-        this.backdrop(function () {
-          var transition = $.support.transition && that.$element.hasClass('fade')
-
-          if (!that.$element.parent().length) {
-            that.$element.appendTo(document.body) //don't move modals dom position
-          }
-
-          that.$element.show()
-
-          if (transition) {
-            that.$element[0].offsetWidth // force reflow
-          }
-
-          that.$element
-            .addClass('in')
-            .attr('aria-hidden', false)
-
-          that.enforceFocus()
-
-          transition ?
-            that.$element.one($.support.transition.end, function () { that.$element.focus().trigger('shown') }) :
-            that.$element.focus().trigger('shown')
-
-        })
-      }
-
-    , hide: function (e) {
-        e && e.preventDefault()
-
-        var that = this
-
-        e = $.Event('hide')
-
-        this.$element.trigger(e)
-
-        if (!this.isShown || e.isDefaultPrevented()) return
-
-        this.isShown = false
-
-        this.escape()
-
-        $(document).off('focusin.modal')
-
-        this.$element
-          .removeClass('in')
-          .attr('aria-hidden', true)
-
-        $.support.transition && this.$element.hasClass('fade') ?
-          this.hideWithTransition() :
-          this.hideModal()
-      }
-
-    , enforceFocus: function () {
-        var that = this
-        $(document).on('focusin.modal', function (e) {
-          if (that.$element[0] !== e.target && !that.$element.has(e.target).length) {
-            that.$element.focus()
-          }
-        })
-      }
-
-    , escape: function () {
-        var that = this
-        if (this.isShown && this.options.keyboard) {
-          this.$element.on('keyup.dismiss.modal', function ( e ) {
-            e.which == 27 && that.hide()
-          })
-        } else if (!this.isShown) {
-          this.$element.off('keyup.dismiss.modal')
-        }
-      }
-
-    , hideWithTransition: function () {
-        var that = this
-          , timeout = setTimeout(function () {
-              that.$element.off($.support.transition.end)
-              that.hideModal()
-            }, 500)
-
-        this.$element.one($.support.transition.end, function () {
-          clearTimeout(timeout)
-          that.hideModal()
-        })
-      }
-
-    , hideModal: function () {
-        var that = this
-        this.$element.hide()
-        this.backdrop(function () {
-          that.removeBackdrop()
-          that.$element.trigger('hidden')
-        })
-      }
-
-    , removeBackdrop: function () {
-        this.$backdrop.remove()
-        this.$backdrop = null
-      }
-
-    , backdrop: function (callback) {
-        var that = this
-          , animate = this.$element.hasClass('fade') ? 'fade' : ''
-
-        if (this.isShown && this.options.backdrop) {
-          var doAnimate = $.support.transition && animate
-
-          this.$backdrop = $('<div class="modal-backdrop ' + animate + '" />')
-            .appendTo(document.body)
-
-          this.$backdrop.click(
-            this.options.backdrop == 'static' ?
-              $.proxy(this.$element[0].focus, this.$element[0])
-            : $.proxy(this.hide, this)
-          )
-
-          if (doAnimate) this.$backdrop[0].offsetWidth // force reflow
-
-          this.$backdrop.addClass('in')
-
-          if (!callback) return
-
-          doAnimate ?
-            this.$backdrop.one($.support.transition.end, callback) :
-            callback()
-
-        } else if (!this.isShown && this.$backdrop) {
-          this.$backdrop.removeClass('in')
-
-          $.support.transition && this.$element.hasClass('fade')?
-            this.$backdrop.one($.support.transition.end, callback) :
-            callback()
-
-        } else if (callback) {
-          callback()
-        }
-      }
-  }
-
-
- /* MODAL PLUGIN DEFINITION
-  * ======================= */
-
-  var old = $.fn.modal
-
-  $.fn.modal = function (option) {
-    return this.each(function () {
-      var $this = $(this)
-        , data = $this.data('modal')
-        , options = $.extend({}, $.fn.modal.defaults, $this.data(), typeof option == 'object' && option)
-      if (!data) $this.data('modal', (data = new Modal(this, options)))
-      if (typeof option == 'string') data[option]()
-      else if (options.show) data.show()
-    })
-  }
-
-  $.fn.modal.defaults = {
-      backdrop: true
-    , keyboard: true
-    , show: true
-  }
-
-  $.fn.modal.Constructor = Modal
-
-
- /* MODAL NO CONFLICT
-  * ================= */
-
-  $.fn.modal.noConflict = function () {
-    $.fn.modal = old
-    return this
-  }
-
-
- /* MODAL DATA-API
-  * ============== */
-
-  $(document).on('click.modal.data-api', '[data-toggle="modal"]', function (e) {
-    var $this = $(this)
-      , href = $this.attr('href')
-      , $target = $($this.attr('data-target') || (href && href.replace(/.*(?=#[^\s]+$)/, ''))) //strip for ie7
-      , option = $target.data('modal') ? 'toggle' : $.extend({ remote:!/#/.test(href) && href }, $target.data(), $this.data())
-
-    e.preventDefault()
-
-    $target
-      .modal(option)
-      .one('hide', function () {
-        $this.focus()
-      })
-  })
-
-}(window.jQuery);
-/* ===========================================================
- * bootstrap-tooltip.js v2.3.0
- * http://twitter.github.com/bootstrap/javascript.html#tooltips
- * Inspired by the original jQuery.tipsy by Jason Frame
- * ===========================================================
- * Copyright 2012 Twitter, Inc.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- * ========================================================== */
-
-
-!function ($) {
-
-  "use strict"; // jshint ;_;
-
-
- /* TOOLTIP PUBLIC CLASS DEFINITION
-  * =============================== */
-
-  var Tooltip = function (element, options) {
-    this.init('tooltip', element, options)
-  }
-
-  Tooltip.prototype = {
-
-    constructor: Tooltip
-
-  , init: function (type, element, options) {
-      var eventIn
-        , eventOut
-        , triggers
-        , trigger
-        , i
-
-      this.type = type
-      this.$element = $(element)
-      this.options = this.getOptions(options)
-      this.enabled = true
-
-      triggers = this.options.trigger.split(' ')
-
-      for (i = triggers.length; i--;) {
-        trigger = triggers[i]
-        if (trigger == 'click') {
-          this.$element.on('click.' + this.type, this.options.selector, $.proxy(this.toggle, this))
-        } else if (trigger != 'manual') {
-          eventIn = trigger == 'hover' ? 'mouseenter' : 'focus'
-          eventOut = trigger == 'hover' ? 'mouseleave' : 'blur'
-          this.$element.on(eventIn + '.' + this.type, this.options.selector, $.proxy(this.enter, this))
-          this.$element.on(eventOut + '.' + this.type, this.options.selector, $.proxy(this.leave, this))
-        }
-      }
-
-      this.options.selector ?
-        (this._options = $.extend({}, this.options, { trigger: 'manual', selector: '' })) :
-        this.fixTitle()
-    }
-
-  , getOptions: function (options) {
-      options = $.extend({}, $.fn[this.type].defaults, this.$element.data(), options)
-
-      if (options.delay && typeof options.delay == 'number') {
-        options.delay = {
-          show: options.delay
-        , hide: options.delay
-        }
-      }
-
-      return options
-    }
-
-  , enter: function (e) {
-      var self = $(e.currentTarget)[this.type](this._options).data(this.type)
-
-      if (!self.options.delay || !self.options.delay.show) return self.show()
-
-      clearTimeout(this.timeout)
-      self.hoverState = 'in'
-      this.timeout = setTimeout(function() {
-        if (self.hoverState == 'in') self.show()
-      }, self.options.delay.show)
-    }
-
-  , leave: function (e) {
-      var self = $(e.currentTarget)[this.type](this._options).data(this.type)
-
-      if (this.timeout) clearTimeout(this.timeout)
-      if (!self.options.delay || !self.options.delay.hide) return self.hide()
-
-      self.hoverState = 'out'
-      this.timeout = setTimeout(function() {
-        if (self.hoverState == 'out') self.hide()
-      }, self.options.delay.hide)
-    }
-
-  , show: function () {
-      var $tip
-        , pos
-        , actualWidth
-        , actualHeight
-        , placement
-        , tp
-        , e = $.Event('show')
-
-      if (this.hasContent() && this.enabled) {
-        this.$element.trigger(e)
-        if (e.isDefaultPrevented()) return
-        $tip = this.tip()
-        this.setContent()
-
-        if (this.options.animation) {
-          $tip.addClass('fade')
-        }
-
-        placement = typeof this.options.placement == 'function' ?
-          this.options.placement.call(this, $tip[0], this.$element[0]) :
-          this.options.placement
-
-        $tip
-          .detach()
-          .css({ top: 0, left: 0, display: 'block' })
-
-        this.options.container ? $tip.appendTo(this.options.container) : $tip.insertAfter(this.$element)
-
-        pos = this.getPosition()
-
-        actualWidth = $tip[0].offsetWidth
-        actualHeight = $tip[0].offsetHeight
-
-        switch (placement) {
-          case 'bottom':
-            tp = {top: pos.top + pos.height, left: pos.left + pos.width / 2 - actualWidth / 2}
-            break
-          case 'top':
-            tp = {top: pos.top - actualHeight, left: pos.left + pos.width / 2 - actualWidth / 2}
-            break
-          case 'left':
-            tp = {top: pos.top + pos.height / 2 - actualHeight / 2, left: pos.left - actualWidth}
-            break
-          case 'right':
-            tp = {top: pos.top + pos.height / 2 - actualHeight / 2, left: pos.left + pos.width}
-            break
-        }
-
-        this.applyPlacement(tp, placement)
-        this.$element.trigger('shown')
-      }
-    }
-
-  , applyPlacement: function(offset, placement){
-      var $tip = this.tip()
-        , width = $tip[0].offsetWidth
-        , height = $tip[0].offsetHeight
-        , actualWidth
-        , actualHeight
-        , delta
-        , replace
-
-      $tip
-        .offset(offset)
-        .addClass(placement)
-        .addClass('in')
-
-      actualWidth = $tip[0].offsetWidth
-      actualHeight = $tip[0].offsetHeight
-
-      if (placement == 'top' && actualHeight != height) {
-        offset.top = offset.top + height - actualHeight
-        replace = true
-      }
-
-      if (placement == 'bottom' || placement == 'top') {
-        delta = 0
-
-        if (offset.left < 0){
-          delta = offset.left * -2
-          offset.left = 0
-          $tip.offset(offset)
-          actualWidth = $tip[0].offsetWidth
-          actualHeight = $tip[0].offsetHeight
-        }
-
-        this.replaceArrow(delta - width + actualWidth, actualWidth, 'left')
-      } else {
-        this.replaceArrow(actualHeight - height, actualHeight, 'top')
-      }
-
-      if (replace) $tip.offset(offset)
-    }
-
-  , replaceArrow: function(delta, dimension, position){
-      this
-        .arrow()
-        .css(position, delta ? (50 * (1 - delta / dimension) + "%") : '')
-    }
-
-  , setContent: function () {
-      var $tip = this.tip()
-        , title = this.getTitle()
-
-      $tip.find('.tooltip-inner')[this.options.html ? 'html' : 'text'](title)
-      $tip.removeClass('fade in top bottom left right')
-    }
-
-  , hide: function () {
-      var that = this
-        , $tip = this.tip()
-        , e = $.Event('hide')
-
-      this.$element.trigger(e)
-      if (e.isDefaultPrevented()) return
-
-      $tip.removeClass('in')
-
-      function removeWithAnimation() {
-        var timeout = setTimeout(function () {
-          $tip.off($.support.transition.end).detach()
-        }, 500)
-
-        $tip.one($.support.transition.end, function () {
-          clearTimeout(timeout)
-          $tip.detach()
-        })
-      }
-
-      $.support.transition && this.$tip.hasClass('fade') ?
-        removeWithAnimation() :
-        $tip.detach()
-
-      this.$element.trigger('hidden')
-
-      return this
-    }
-
-  , fixTitle: function () {
-      var $e = this.$element
-      if ($e.attr('title') || typeof($e.attr('data-original-title')) != 'string') {
-        $e.attr('data-original-title', $e.attr('title') || '').attr('title', '')
-      }
-    }
-
-  , hasContent: function () {
-      return this.getTitle()
-    }
-
-  , getPosition: function () {
-      var el = this.$element[0]
-      return $.extend({}, (typeof el.getBoundingClientRect == 'function') ? el.getBoundingClientRect() : {
-        width: el.offsetWidth
-      , height: el.offsetHeight
-      }, this.$element.offset())
-    }
-
-  , getTitle: function () {
-      var title
-        , $e = this.$element
-        , o = this.options
-
-      title = $e.attr('data-original-title')
-        || (typeof o.title == 'function' ? o.title.call($e[0]) :  o.title)
-
-      return title
-    }
-
-  , tip: function () {
-      return this.$tip = this.$tip || $(this.options.template)
-    }
-
-  , arrow: function(){
-      return this.$arrow = this.$arrow || this.tip().find(".tooltip-arrow")
-    }
-
-  , validate: function () {
-      if (!this.$element[0].parentNode) {
-        this.hide()
-        this.$element = null
-        this.options = null
-      }
-    }
-
-  , enable: function () {
-      this.enabled = true
-    }
-
-  , disable: function () {
-      this.enabled = false
-    }
-
-  , toggleEnabled: function () {
-      this.enabled = !this.enabled
-    }
-
-  , toggle: function (e) {
-      var self = e ? $(e.currentTarget)[this.type](this._options).data(this.type) : this
-      self.tip().hasClass('in') ? self.hide() : self.show()
-    }
-
-  , destroy: function () {
-      this.hide().$element.off('.' + this.type).removeData(this.type)
-    }
-
-  }
-
-
- /* TOOLTIP PLUGIN DEFINITION
-  * ========================= */
-
-  var old = $.fn.tooltip
-
-  $.fn.tooltip = function ( option ) {
-    return this.each(function () {
-      var $this = $(this)
-        , data = $this.data('tooltip')
-        , options = typeof option == 'object' && option
-      if (!data) $this.data('tooltip', (data = new Tooltip(this, options)))
-      if (typeof option == 'string') data[option]()
-    })
-  }
-
-  $.fn.tooltip.Constructor = Tooltip
-
-  $.fn.tooltip.defaults = {
-    animation: true
-  , placement: 'top'
-  , selector: false
-  , template: '<div class="tooltip"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>'
-  , trigger: 'hover focus'
-  , title: ''
-  , delay: 0
-  , html: false
-  , container: false
-  }
-
-
- /* TOOLTIP NO CONFLICT
-  * =================== */
-
-  $.fn.tooltip.noConflict = function () {
-    $.fn.tooltip = old
-    return this
-  }
-
-}(window.jQuery);
-/* ===========================================================
- * bootstrap-popover.js v2.3.0
- * http://twitter.github.com/bootstrap/javascript.html#popovers
- * ===========================================================
- * Copyright 2012 Twitter, Inc.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- * =========================================================== */
-
-
-!function ($) {
-
-  "use strict"; // jshint ;_;
-
-
- /* POPOVER PUBLIC CLASS DEFINITION
-  * =============================== */
-
-  var Popover = function (element, options) {
-    this.init('popover', element, options)
-  }
-
-
-  /* NOTE: POPOVER EXTENDS BOOTSTRAP-TOOLTIP.js
-     ========================================== */
-
-  Popover.prototype = $.extend({}, $.fn.tooltip.Constructor.prototype, {
-
-    constructor: Popover
-
-  , setContent: function () {
-      var $tip = this.tip()
-        , title = this.getTitle()
-        , content = this.getContent()
-
-      $tip.find('.popover-title')[this.options.html ? 'html' : 'text'](title)
-      $tip.find('.popover-content')[this.options.html ? 'html' : 'text'](content)
-
-      $tip.removeClass('fade top bottom left right in')
-    }
-
-  , hasContent: function () {
-      return this.getTitle() || this.getContent()
-    }
-
-  , getContent: function () {
-      var content
-        , $e = this.$element
-        , o = this.options
-
-      content = (typeof o.content == 'function' ? o.content.call($e[0]) :  o.content)
-        || $e.attr('data-content')
-
-      return content
-    }
-
-  , tip: function () {
-      if (!this.$tip) {
-        this.$tip = $(this.options.template)
-      }
-      return this.$tip
-    }
-
-  , destroy: function () {
-      this.hide().$element.off('.' + this.type).removeData(this.type)
-    }
-
-  })
-
-
- /* POPOVER PLUGIN DEFINITION
-  * ======================= */
-
-  var old = $.fn.popover
-
-  $.fn.popover = function (option) {
-    return this.each(function () {
-      var $this = $(this)
-        , data = $this.data('popover')
-        , options = typeof option == 'object' && option
-      if (!data) $this.data('popover', (data = new Popover(this, options)))
-      if (typeof option == 'string') data[option]()
-    })
-  }
-
-  $.fn.popover.Constructor = Popover
-
-  $.fn.popover.defaults = $.extend({} , $.fn.tooltip.defaults, {
-    placement: 'right'
-  , trigger: 'click'
-  , content: ''
-  , template: '<div class="popover"><div class="arrow"></div><h3 class="popover-title"></h3><div class="popover-content"></div></div>'
-  })
-
-
- /* POPOVER NO CONFLICT
-  * =================== */
-
-  $.fn.popover.noConflict = function () {
-    $.fn.popover = old
-    return this
-  }
-
-}(window.jQuery);
-/* =============================================================
- * bootstrap-scrollspy.js v2.3.0
- * http://twitter.github.com/bootstrap/javascript.html#scrollspy
- * =============================================================
- * Copyright 2012 Twitter, Inc.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- * ============================================================== */
-
-
-!function ($) {
-
-  "use strict"; // jshint ;_;
-
-
- /* SCROLLSPY CLASS DEFINITION
-  * ========================== */
-
-  function ScrollSpy(element, options) {
-    var process = $.proxy(this.process, this)
-      , $element = $(element).is('body') ? $(window) : $(element)
-      , href
-    this.options = $.extend({}, $.fn.scrollspy.defaults, options)
-    this.$scrollElement = $element.on('scroll.scroll-spy.data-api', process)
-    this.selector = (this.options.target
-      || ((href = $(element).attr('href')) && href.replace(/.*(?=#[^\s]+$)/, '')) //strip for ie7
-      || '') + ' .nav li > a'
-    this.$body = $('body')
-    this.refresh()
-    this.process()
-  }
-
-  ScrollSpy.prototype = {
-
-      constructor: ScrollSpy
-
-    , refresh: function () {
-        var self = this
-          , $targets
-
-        this.offsets = $([])
-        this.targets = $([])
-
-        $targets = this.$body
-          .find(this.selector)
-          .map(function () {
-            var $el = $(this)
-              , href = $el.data('target') || $el.attr('href')
-              , $href = /^#\w/.test(href) && $(href)
-            return ( $href
-              && $href.length
-              && [[ $href.position().top + (!$.isWindow(self.$scrollElement.get(0)) && self.$scrollElement.scrollTop()), href ]] ) || null
-          })
-          .sort(function (a, b) { return a[0] - b[0] })
-          .each(function () {
-            self.offsets.push(this[0])
-            self.targets.push(this[1])
-          })
-      }
-
-    , process: function () {
-        var scrollTop = this.$scrollElement.scrollTop() + this.options.offset
-          , scrollHeight = this.$scrollElement[0].scrollHeight || this.$body[0].scrollHeight
-          , maxScroll = scrollHeight - this.$scrollElement.height()
-          , offsets = this.offsets
-          , targets = this.targets
-          , activeTarget = this.activeTarget
-          , i
-
-        if (scrollTop >= maxScroll) {
-          return activeTarget != (i = targets.last()[0])
-            && this.activate ( i )
-        }
-
-        for (i = offsets.length; i--;) {
-          activeTarget != targets[i]
-            && scrollTop >= offsets[i]
-            && (!offsets[i + 1] || scrollTop <= offsets[i + 1])
-            && this.activate( targets[i] )
-        }
-      }
-
-    , activate: function (target) {
-        var active
-          , selector
-
-        this.activeTarget = target
-
-        $(this.selector)
-          .parent('.active')
-          .removeClass('active')
-
-        selector = this.selector
-          + '[data-target="' + target + '"],'
-          + this.selector + '[href="' + target + '"]'
-
-        active = $(selector)
-          .parent('li')
-          .addClass('active')
-
-        if (active.parent('.dropdown-menu').length)  {
-          active = active.closest('li.dropdown').addClass('active')
-        }
-
-        active.trigger('activate')
-      }
-
-  }
-
-
- /* SCROLLSPY PLUGIN DEFINITION
-  * =========================== */
-
-  var old = $.fn.scrollspy
-
-  $.fn.scrollspy = function (option) {
-    return this.each(function () {
-      var $this = $(this)
-        , data = $this.data('scrollspy')
-        , options = typeof option == 'object' && option
-      if (!data) $this.data('scrollspy', (data = new ScrollSpy(this, options)))
-      if (typeof option == 'string') data[option]()
-    })
-  }
-
-  $.fn.scrollspy.Constructor = ScrollSpy
-
-  $.fn.scrollspy.defaults = {
-    offset: 10
-  }
-
-
- /* SCROLLSPY NO CONFLICT
-  * ===================== */
-
-  $.fn.scrollspy.noConflict = function () {
-    $.fn.scrollspy = old
-    return this
-  }
-
-
- /* SCROLLSPY DATA-API
-  * ================== */
-
-  $(window).on('load', function () {
-    $('[data-spy="scroll"]').each(function () {
-      var $spy = $(this)
-      $spy.scrollspy($spy.data())
-    })
-  })
-
-}(window.jQuery);/* ========================================================
- * bootstrap-tab.js v2.3.0
- * http://twitter.github.com/bootstrap/javascript.html#tabs
- * ========================================================
- * Copyright 2012 Twitter, Inc.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- * ======================================================== */
-
-
-!function ($) {
-
-  "use strict"; // jshint ;_;
-
-
- /* TAB CLASS DEFINITION
-  * ==================== */
-
-  var Tab = function (element) {
-    this.element = $(element)
-  }
-
-  Tab.prototype = {
-
-    constructor: Tab
-
-  , show: function () {
-      var $this = this.element
-        , $ul = $this.closest('ul:not(.dropdown-menu)')
-        , selector = $this.attr('data-target')
-        , previous
-        , $target
-        , e
-
-      if (!selector) {
-        selector = $this.attr('href')
-        selector = selector && selector.replace(/.*(?=#[^\s]*$)/, '') //strip for ie7
-      }
-
-      if ( $this.parent('li').hasClass('active') ) return
-
-      previous = $ul.find('.active:last a')[0]
-
-      e = $.Event('show', {
-        relatedTarget: previous
-      })
-
-      $this.trigger(e)
-
-      if (e.isDefaultPrevented()) return
-
-      $target = $(selector)
-
-      this.activate($this.parent('li'), $ul)
-      this.activate($target, $target.parent(), function () {
-        $this.trigger({
-          type: 'shown'
-        , relatedTarget: previous
-        })
-      })
-    }
-
-  , activate: function ( element, container, callback) {
-      var $active = container.find('> .active')
-        , transition = callback
-            && $.support.transition
-            && $active.hasClass('fade')
-
-      function next() {
-        $active
-          .removeClass('active')
-          .find('> .dropdown-menu > .active')
-          .removeClass('active')
-
-        element.addClass('active')
-
-        if (transition) {
-          element[0].offsetWidth // reflow for transition
-          element.addClass('in')
-        } else {
-          element.removeClass('fade')
-        }
-
-        if ( element.parent('.dropdown-menu') ) {
-          element.closest('li.dropdown').addClass('active')
-        }
-
-        callback && callback()
-      }
-
-      transition ?
-        $active.one($.support.transition.end, next) :
-        next()
-
-      $active.removeClass('in')
-    }
-  }
-
-
- /* TAB PLUGIN DEFINITION
-  * ===================== */
-
-  var old = $.fn.tab
-
-  $.fn.tab = function ( option ) {
-    return this.each(function () {
-      var $this = $(this)
-        , data = $this.data('tab')
-      if (!data) $this.data('tab', (data = new Tab(this)))
-      if (typeof option == 'string') data[option]()
-    })
-  }
-
-  $.fn.tab.Constructor = Tab
-
-
- /* TAB NO CONFLICT
-  * =============== */
-
-  $.fn.tab.noConflict = function () {
-    $.fn.tab = old
-    return this
-  }
-
-
- /* TAB DATA-API
-  * ============ */
-
-  $(document).on('click.tab.data-api', '[data-toggle="tab"], [data-toggle="pill"]', function (e) {
-    e.preventDefault()
-    $(this).tab('show')
-  })
-
-}(window.jQuery);/* =============================================================
- * bootstrap-typeahead.js v2.3.0
- * http://twitter.github.com/bootstrap/javascript.html#typeahead
- * =============================================================
- * Copyright 2012 Twitter, Inc.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- * ============================================================ */
-
-
-!function($){
-
-  "use strict"; // jshint ;_;
-
-
- /* TYPEAHEAD PUBLIC CLASS DEFINITION
-  * ================================= */
-
-  var Typeahead = function (element, options) {
-    this.$element = $(element)
-    this.options = $.extend({}, $.fn.typeahead.defaults, options)
-    this.matcher = this.options.matcher || this.matcher
-    this.sorter = this.options.sorter || this.sorter
-    this.highlighter = this.options.highlighter || this.highlighter
-    this.updater = this.options.updater || this.updater
-    this.source = this.options.source
-    this.$menu = $(this.options.menu)
-    this.shown = false
-    this.listen()
-  }
-
-  Typeahead.prototype = {
-
-    constructor: Typeahead
-
-  , select: function () {
-      var val = this.$menu.find('.active').attr('data-value')
-      this.$element
-        .val(this.updater(val))
-        .change()
-      return this.hide()
-    }
-
-  , updater: function (item) {
-      return item
-    }
-
-  , show: function () {
-      var pos = $.extend({}, this.$element.position(), {
-        height: this.$element[0].offsetHeight
-      })
-
-      this.$menu
-        .insertAfter(this.$element)
-        .css({
-          top: pos.top + pos.height
-        , left: pos.left
-        })
-        .show()
-
-      this.shown = true
-      return this
-    }
-
-  , hide: function () {
-      this.$menu.hide()
-      this.shown = false
-      return this
-    }
-
-  , lookup: function (event) {
-      var items
-
-      this.query = this.$element.val()
-
-      if (!this.query || this.query.length < this.options.minLength) {
-        return this.shown ? this.hide() : this
-      }
-
-      items = $.isFunction(this.source) ? this.source(this.query, $.proxy(this.process, this)) : this.source
-
-      return items ? this.process(items) : this
-    }
-
-  , process: function (items) {
-      var that = this
-
-      items = $.grep(items, function (item) {
-        return that.matcher(item)
-      })
-
-      items = this.sorter(items)
-
-      if (!items.length) {
-        return this.shown ? this.hide() : this
-      }
-
-      return this.render(items.slice(0, this.options.items)).show()
-    }
-
-  , matcher: function (item) {
-      return ~item.toLowerCase().indexOf(this.query.toLowerCase())
-    }
-
-  , sorter: function (items) {
-      var beginswith = []
-        , caseSensitive = []
-        , caseInsensitive = []
-        , item
-
-      while (item = items.shift()) {
-        if (!item.toLowerCase().indexOf(this.query.toLowerCase())) beginswith.push(item)
-        else if (~item.indexOf(this.query)) caseSensitive.push(item)
-        else caseInsensitive.push(item)
-      }
-
-      return beginswith.concat(caseSensitive, caseInsensitive)
-    }
-
-  , highlighter: function (item) {
-      var query = this.query.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g, '\\$&')
-      return item.replace(new RegExp('(' + query + ')', 'ig'), function ($1, match) {
-        return '<strong>' + match + '</strong>'
-      })
-    }
-
-  , render: function (items) {
-      var that = this
-
-      items = $(items).map(function (i, item) {
-        i = $(that.options.item).attr('data-value', item)
-        i.find('a').html(that.highlighter(item))
-        return i[0]
-      })
-
-      items.first().addClass('active')
-      this.$menu.html(items)
-      return this
-    }
-
-  , next: function (event) {
-      var active = this.$menu.find('.active').removeClass('active')
-        , next = active.next()
-
-      if (!next.length) {
-        next = $(this.$menu.find('li')[0])
-      }
-
-      next.addClass('active')
-    }
-
-  , prev: function (event) {
-      var active = this.$menu.find('.active').removeClass('active')
-        , prev = active.prev()
-
-      if (!prev.length) {
-        prev = this.$menu.find('li').last()
-      }
-
-      prev.addClass('active')
-    }
-
-  , listen: function () {
-      this.$element
-        .on('focus',    $.proxy(this.focus, this))
-        .on('blur',     $.proxy(this.blur, this))
-        .on('keypress', $.proxy(this.keypress, this))
-        .on('keyup',    $.proxy(this.keyup, this))
-
-      if (this.eventSupported('keydown')) {
-        this.$element.on('keydown', $.proxy(this.keydown, this))
-      }
-
-      this.$menu
-        .on('click', $.proxy(this.click, this))
-        .on('mouseenter', 'li', $.proxy(this.mouseenter, this))
-        .on('mouseleave', 'li', $.proxy(this.mouseleave, this))
-    }
-
-  , eventSupported: function(eventName) {
-      var isSupported = eventName in this.$element
-      if (!isSupported) {
-        this.$element.setAttribute(eventName, 'return;')
-        isSupported = typeof this.$element[eventName] === 'function'
-      }
-      return isSupported
-    }
-
-  , move: function (e) {
-      if (!this.shown) return
-
-      switch(e.keyCode) {
-        case 9: // tab
-        case 13: // enter
-        case 27: // escape
-          e.preventDefault()
-          break
-
-        case 38: // up arrow
-          e.preventDefault()
-          this.prev()
-          break
-
-        case 40: // down arrow
-          e.preventDefault()
-          this.next()
-          break
-      }
-
-      e.stopPropagation()
-    }
-
-  , keydown: function (e) {
-      this.suppressKeyPressRepeat = ~$.inArray(e.keyCode, [40,38,9,13,27])
-      this.move(e)
-    }
-
-  , keypress: function (e) {
-      if (this.suppressKeyPressRepeat) return
-      this.move(e)
-    }
-
-  , keyup: function (e) {
-      switch(e.keyCode) {
-        case 40: // down arrow
-        case 38: // up arrow
-        case 16: // shift
-        case 17: // ctrl
-        case 18: // alt
-          break
-
-        case 9: // tab
-        case 13: // enter
-          if (!this.shown) return
-          this.select()
-          break
-
-        case 27: // escape
-          if (!this.shown) return
-          this.hide()
-          break
-
-        default:
-          this.lookup()
-      }
-
-      e.stopPropagation()
-      e.preventDefault()
-  }
-
-  , focus: function (e) {
-      this.focused = true
-    }
-
-  , blur: function (e) {
-      this.focused = false
-      if (!this.mousedover && this.shown) this.hide()
-    }
-
-  , click: function (e) {
-      e.stopPropagation()
-      e.preventDefault()
-      this.select()
-      this.$element.focus()
-    }
-
-  , mouseenter: function (e) {
-      this.mousedover = true
-      this.$menu.find('.active').removeClass('active')
-      $(e.currentTarget).addClass('active')
-    }
-
-  , mouseleave: function (e) {
-      this.mousedover = false
-      if (!this.focused && this.shown) this.hide()
-    }
-
-  }
-
-
-  /* TYPEAHEAD PLUGIN DEFINITION
-   * =========================== */
-
-  var old = $.fn.typeahead
-
-  $.fn.typeahead = function (option) {
-    return this.each(function () {
-      var $this = $(this)
-        , data = $this.data('typeahead')
-        , options = typeof option == 'object' && option
-      if (!data) $this.data('typeahead', (data = new Typeahead(this, options)))
-      if (typeof option == 'string') data[option]()
-    })
-  }
-
-  $.fn.typeahead.defaults = {
-    source: []
-  , items: 8
-  , menu: '<ul class="typeahead dropdown-menu"></ul>'
-  , item: '<li><a href="#"></a></li>'
-  , minLength: 1
-  }
-
-  $.fn.typeahead.Constructor = Typeahead
-
-
- /* TYPEAHEAD NO CONFLICT
-  * =================== */
-
-  $.fn.typeahead.noConflict = function () {
-    $.fn.typeahead = old
-    return this
-  }
-
-
- /* TYPEAHEAD DATA-API
-  * ================== */
-
-  $(document).on('focus.typeahead.data-api', '[data-provide="typeahead"]', function (e) {
-    var $this = $(this)
-    if ($this.data('typeahead')) return
-    $this.typeahead($this.data())
-  })
-
-}(window.jQuery);
-/* ==========================================================
- * bootstrap-affix.js v2.3.0
- * http://twitter.github.com/bootstrap/javascript.html#affix
- * ==========================================================
- * Copyright 2012 Twitter, Inc.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- * ========================================================== */
-
-
-!function ($) {
-
-  "use strict"; // jshint ;_;
-
-
- /* AFFIX CLASS DEFINITION
-  * ====================== */
-
-  var Affix = function (element, options) {
-    this.options = $.extend({}, $.fn.affix.defaults, options)
-    this.$window = $(window)
-      .on('scroll.affix.data-api', $.proxy(this.checkPosition, this))
-      .on('click.affix.data-api',  $.proxy(function () { setTimeout($.proxy(this.checkPosition, this), 1) }, this))
-    this.$element = $(element)
-    this.checkPosition()
-  }
-
-  Affix.prototype.checkPosition = function () {
-    if (!this.$element.is(':visible')) return
-
-    var scrollHeight = $(document).height()
-      , scrollTop = this.$window.scrollTop()
-      , position = this.$element.offset()
-      , offset = this.options.offset
-      , offsetBottom = offset.bottom
-      , offsetTop = offset.top
-      , reset = 'affix affix-top affix-bottom'
-      , affix
-
-    if (typeof offset != 'object') offsetBottom = offsetTop = offset
-    if (typeof offsetTop == 'function') offsetTop = offset.top()
-    if (typeof offsetBottom == 'function') offsetBottom = offset.bottom()
-
-    affix = this.unpin != null && (scrollTop + this.unpin <= position.top) ?
-      false    : offsetBottom != null && (position.top + this.$element.height() >= scrollHeight - offsetBottom) ?
-      'bottom' : offsetTop != null && scrollTop <= offsetTop ?
-      'top'    : false
-
-    if (this.affixed === affix) return
-
-    this.affixed = affix
-    this.unpin = affix == 'bottom' ? position.top - scrollTop : null
-
-    this.$element.removeClass(reset).addClass('affix' + (affix ? '-' + affix : ''))
-  }
-
-
- /* AFFIX PLUGIN DEFINITION
-  * ======================= */
-
-  var old = $.fn.affix
-
-  $.fn.affix = function (option) {
-    return this.each(function () {
-      var $this = $(this)
-        , data = $this.data('affix')
-        , options = typeof option == 'object' && option
-      if (!data) $this.data('affix', (data = new Affix(this, options)))
-      if (typeof option == 'string') data[option]()
-    })
-  }
-
-  $.fn.affix.Constructor = Affix
-
-  $.fn.affix.defaults = {
-    offset: 0
-  }
-
-
- /* AFFIX NO CONFLICT
-  * ================= */
-
-  $.fn.affix.noConflict = function () {
-    $.fn.affix = old
-    return this
-  }
-
-
- /* AFFIX DATA-API
-  * ============== */
-
-  $(window).on('load', function () {
-    $('[data-spy="affix"]').each(function () {
-      var $spy = $(this)
-        , data = $spy.data()
-
-      data.offset = data.offset || {}
-
-      data.offsetBottom && (data.offset.bottom = data.offsetBottom)
-      data.offsetTop && (data.offset.top = data.offsetTop)
-
-      $spy.affix(data)
-    })
-  })
-
-
-}(window.jQuery);
\ No newline at end of file
diff --git a/docs/theme/docker/static/js/vendor/bootstrap.min.js b/docs/theme/docker/static/js/vendor/bootstrap.min.js
deleted file mode 100755
index e05923d..0000000
--- a/docs/theme/docker/static/js/vendor/bootstrap.min.js
+++ /dev/null
@@ -1,6 +0,0 @@
-/*!
-* Bootstrap.js by @fat & @mdo
-* Copyright 2012 Twitter, Inc.
-* http://www.apache.org/licenses/LICENSE-2.0.txt
-*/
-!function(e){"use strict";e(function(){e.support.transition=function(){var e=function(){var e=document.createElement("bootstrap"),t={WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"oTransitionEnd otransitionend",transition:"transitionend"},n;for(n in t)if(e.style[n]!==undefined)return t[n]}();return e&&{end:e}}()})}(window.jQuery),!function(e){"use strict";var t='[data-dismiss="alert"]',n=function(n){e(n).on("click",t,this.close)};n.prototype.close=function(t){function s(){i.trigger("closed").remove()}var n=e(this),r=n.attr("data-target"),i;r||(r=n.attr("href"),r=r&&r.replace(/.*(?=#[^\s]*$)/,"")),i=e(r),t&&t.preventDefault(),i.length||(i=n.hasClass("alert")?n:n.parent()),i.trigger(t=e.Event("close"));if(t.isDefaultPrevented())return;i.removeClass("in"),e.support.transition&&i.hasClass("fade")?i.on(e.support.transition.end,s):s()};var r=e.fn.alert;e.fn.alert=function(t){return this.each(function(){var r=e(this),i=r.data("alert");i||r.data("alert",i=new n(this)),typeof t=="string"&&i[t].call(r)})},e.fn.alert.Constructor=n,e.fn.alert.noConflict=function(){return e.fn.alert=r,this},e(document).on("click.alert.data-api",t,n.prototype.close)}(window.jQuery),!function(e){"use strict";var t=function(t,n){this.$element=e(t),this.options=e.extend({},e.fn.button.defaults,n)};t.prototype.setState=function(e){var t="disabled",n=this.$element,r=n.data(),i=n.is("input")?"val":"html";e+="Text",r.resetText||n.data("resetText",n[i]()),n[i](r[e]||this.options[e]),setTimeout(function(){e=="loadingText"?n.addClass(t).attr(t,t):n.removeClass(t).removeAttr(t)},0)},t.prototype.toggle=function(){var e=this.$element.closest('[data-toggle="buttons-radio"]');e&&e.find(".active").removeClass("active"),this.$element.toggleClass("active")};var n=e.fn.button;e.fn.button=function(n){return this.each(function(){var r=e(this),i=r.data("button"),s=typeof n=="object"&&n;i||r.data("button",i=new t(this,s)),n=="toggle"?i.toggle():n&&i.setState(n)})},e.fn.button.defaults={loadingText:"loading..."},e.fn.button.Constructor=t,e.fn.button.noConflict=function(){return e.fn.button=n,this},e(document).on("click.button.data-api","[data-toggle^=button]",function(t){var n=e(t.target);n.hasClass("btn")||(n=n.closest(".btn")),n.button("toggle")})}(window.jQuery),!function(e){"use strict";var t=function(t,n){this.$element=e(t),this.$indicators=this.$element.find(".carousel-indicators"),this.options=n,this.options.pause=="hover"&&this.$element.on("mouseenter",e.proxy(this.pause,this)).on("mouseleave",e.proxy(this.cycle,this))};t.prototype={cycle:function(t){return t||(this.paused=!1),this.interval&&clearInterval(this.interval),this.options.interval&&!this.paused&&(this.interval=setInterval(e.proxy(this.next,this),this.options.interval)),this},getActiveIndex:function(){return this.$active=this.$element.find(".item.active"),this.$items=this.$active.parent().children(),this.$items.index(this.$active)},to:function(t){var n=this.getActiveIndex(),r=this;if(t>this.$items.length-1||t<0)return;return this.sliding?this.$element.one("slid",function(){r.to(t)}):n==t?this.pause().cycle():this.slide(t>n?"next":"prev",e(this.$items[t]))},pause:function(t){return t||(this.paused=!0),this.$element.find(".next, .prev").length&&e.support.transition.end&&(this.$element.trigger(e.support.transition.end),this.cycle()),clearInterval(this.interval),this.interval=null,this},next:function(){if(this.sliding)return;return this.slide("next")},prev:function(){if(this.sliding)return;return this.slide("prev")},slide:function(t,n){var r=this.$element.find(".item.active"),i=n||r[t](),s=this.interval,o=t=="next"?"left":"right",u=t=="next"?"first":"last",a=this,f;this.sliding=!0,s&&this.pause(),i=i.length?i:this.$element.find(".item")[u](),f=e.Event("slide",{relatedTarget:i[0],direction:o});if(i.hasClass("active"))return;this.$indicators.length&&(this.$indicators.find(".active").removeClass("active"),this.$element.one("slid",function(){var t=e(a.$indicators.children()[a.getActiveIndex()]);t&&t.addClass("active")}));if(e.support.transition&&this.$element.hasClass("slide")){this.$element.trigger(f);if(f.isDefaultPrevented())return;i.addClass(t),i[0].offsetWidth,r.addClass(o),i.addClass(o),this.$element.one(e.support.transition.end,function(){i.removeClass([t,o].join(" ")).addClass("active"),r.removeClass(["active",o].join(" ")),a.sliding=!1,setTimeout(function(){a.$element.trigger("slid")},0)})}else{this.$element.trigger(f);if(f.isDefaultPrevented())return;r.removeClass("active"),i.addClass("active"),this.sliding=!1,this.$element.trigger("slid")}return s&&this.cycle(),this}};var n=e.fn.carousel;e.fn.carousel=function(n){return this.each(function(){var r=e(this),i=r.data("carousel"),s=e.extend({},e.fn.carousel.defaults,typeof n=="object"&&n),o=typeof n=="string"?n:s.slide;i||r.data("carousel",i=new t(this,s)),typeof n=="number"?i.to(n):o?i[o]():s.interval&&i.pause().cycle()})},e.fn.carousel.defaults={interval:5e3,pause:"hover"},e.fn.carousel.Constructor=t,e.fn.carousel.noConflict=function(){return e.fn.carousel=n,this},e(document).on("click.carousel.data-api","[data-slide], [data-slide-to]",function(t){var n=e(this),r,i=e(n.attr("data-target")||(r=n.attr("href"))&&r.replace(/.*(?=#[^\s]+$)/,"")),s=e.extend({},i.data(),n.data()),o;i.carousel(s),(o=n.attr("data-slide-to"))&&i.data("carousel").pause().to(o).cycle(),t.preventDefault()})}(window.jQuery),!function(e){"use strict";var t=function(t,n){this.$element=e(t),this.options=e.extend({},e.fn.collapse.defaults,n),this.options.parent&&(this.$parent=e(this.options.parent)),this.options.toggle&&this.toggle()};t.prototype={constructor:t,dimension:function(){var e=this.$element.hasClass("width");return e?"width":"height"},show:function(){var t,n,r,i;if(this.transitioning||this.$element.hasClass("in"))return;t=this.dimension(),n=e.camelCase(["scroll",t].join("-")),r=this.$parent&&this.$parent.find("> .accordion-group > .in");if(r&&r.length){i=r.data("collapse");if(i&&i.transitioning)return;r.collapse("hide"),i||r.data("collapse",null)}this.$element[t](0),this.transition("addClass",e.Event("show"),"shown"),e.support.transition&&this.$element[t](this.$element[0][n])},hide:function(){var t;if(this.transitioning||!this.$element.hasClass("in"))return;t=this.dimension(),this.reset(this.$element[t]()),this.transition("removeClass",e.Event("hide"),"hidden"),this.$element[t](0)},reset:function(e){var t=this.dimension();return this.$element.removeClass("collapse")[t](e||"auto")[0].offsetWidth,this.$element[e!==null?"addClass":"removeClass"]("collapse"),this},transition:function(t,n,r){var i=this,s=function(){n.type=="show"&&i.reset(),i.transitioning=0,i.$element.trigger(r)};this.$element.trigger(n);if(n.isDefaultPrevented())return;this.transitioning=1,this.$element[t]("in"),e.support.transition&&this.$element.hasClass("collapse")?this.$element.one(e.support.transition.end,s):s()},toggle:function(){this[this.$element.hasClass("in")?"hide":"show"]()}};var n=e.fn.collapse;e.fn.collapse=function(n){return this.each(function(){var r=e(this),i=r.data("collapse"),s=e.extend({},e.fn.collapse.defaults,r.data(),typeof n=="object"&&n);i||r.data("collapse",i=new t(this,s)),typeof n=="string"&&i[n]()})},e.fn.collapse.defaults={toggle:!0},e.fn.collapse.Constructor=t,e.fn.collapse.noConflict=function(){return e.fn.collapse=n,this},e(document).on("click.collapse.data-api","[data-toggle=collapse]",function(t){var n=e(this),r,i=n.attr("data-target")||t.preventDefault()||(r=n.attr("href"))&&r.replace(/.*(?=#[^\s]+$)/,""),s=e(i).data("collapse")?"toggle":n.data();n[e(i).hasClass("in")?"addClass":"removeClass"]("collapsed"),e(i).collapse(s)})}(window.jQuery),!function(e){"use strict";function r(){e(t).each(function(){i(e(this)).removeClass("open")})}function i(t){var n=t.attr("data-target"),r;n||(n=t.attr("href"),n=n&&/#/.test(n)&&n.replace(/.*(?=#[^\s]*$)/,"")),r=n&&e(n);if(!r||!r.length)r=t.parent();return r}var t="[data-toggle=dropdown]",n=function(t){var n=e(t).on("click.dropdown.data-api",this.toggle);e("html").on("click.dropdown.data-api",function(){n.parent().removeClass("open")})};n.prototype={constructor:n,toggle:function(t){var n=e(this),s,o;if(n.is(".disabled, :disabled"))return;return s=i(n),o=s.hasClass("open"),r(),o||s.toggleClass("open"),n.focus(),!1},keydown:function(n){var r,s,o,u,a,f;if(!/(38|40|27)/.test(n.keyCode))return;r=e(this),n.preventDefault(),n.stopPropagation();if(r.is(".disabled, :disabled"))return;u=i(r),a=u.hasClass("open");if(!a||a&&n.keyCode==27)return n.which==27&&u.find(t).focus(),r.click();s=e("[role=menu] li:not(.divider):visible a",u);if(!s.length)return;f=s.index(s.filter(":focus")),n.keyCode==38&&f>0&&f--,n.keyCode==40&&f<s.length-1&&f++,~f||(f=0),s.eq(f).focus()}};var s=e.fn.dropdown;e.fn.dropdown=function(t){return this.each(function(){var r=e(this),i=r.data("dropdown");i||r.data("dropdown",i=new n(this)),typeof t=="string"&&i[t].call(r)})},e.fn.dropdown.Constructor=n,e.fn.dropdown.noConflict=function(){return e.fn.dropdown=s,this},e(document).on("click.dropdown.data-api",r).on("click.dropdown.data-api",".dropdown form",function(e){e.stopPropagation()}).on(".dropdown-menu",function(e){e.stopPropagation()}).on("click.dropdown.data-api",t,n.prototype.toggle).on("keydown.dropdown.data-api",t+", [role=menu]",n.prototype.keydown)}(window.jQuery),!function(e){"use strict";var t=function(t,n){this.options=n,this.$element=e(t).delegate('[data-dismiss="modal"]',"click.dismiss.modal",e.proxy(this.hide,this)),this.options.remote&&this.$element.find(".modal-body").load(this.options.remote)};t.prototype={constructor:t,toggle:function(){return this[this.isShown?"hide":"show"]()},show:function(){var t=this,n=e.Event("show");this.$element.trigger(n);if(this.isShown||n.isDefaultPrevented())return;this.isShown=!0,this.escape(),this.backdrop(function(){var n=e.support.transition&&t.$element.hasClass("fade");t.$element.parent().length||t.$element.appendTo(document.body),t.$element.show(),n&&t.$element[0].offsetWidth,t.$element.addClass("in").attr("aria-hidden",!1),t.enforceFocus(),n?t.$element.one(e.support.transition.end,function(){t.$element.focus().trigger("shown")}):t.$element.focus().trigger("shown")})},hide:function(t){t&&t.preventDefault();var n=this;t=e.Event("hide"),this.$element.trigger(t);if(!this.isShown||t.isDefaultPrevented())return;this.isShown=!1,this.escape(),e(document).off("focusin.modal"),this.$element.removeClass("in").attr("aria-hidden",!0),e.support.transition&&this.$element.hasClass("fade")?this.hideWithTransition():this.hideModal()},enforceFocus:function(){var t=this;e(document).on("focusin.modal",function(e){t.$element[0]!==e.target&&!t.$element.has(e.target).length&&t.$element.focus()})},escape:function(){var e=this;this.isShown&&this.options.keyboard?this.$element.on("keyup.dismiss.modal",function(t){t.which==27&&e.hide()}):this.isShown||this.$element.off("keyup.dismiss.modal")},hideWithTransition:function(){var t=this,n=setTimeout(function(){t.$element.off(e.support.transition.end),t.hideModal()},500);this.$element.one(e.support.transition.end,function(){clearTimeout(n),t.hideModal()})},hideModal:function(){var e=this;this.$element.hide(),this.backdrop(function(){e.removeBackdrop(),e.$element.trigger("hidden")})},removeBackdrop:function(){this.$backdrop.remove(),this.$backdrop=null},backdrop:function(t){var n=this,r=this.$element.hasClass("fade")?"fade":"";if(this.isShown&&this.options.backdrop){var i=e.support.transition&&r;this.$backdrop=e('<div class="modal-backdrop '+r+'" />').appendTo(document.body),this.$backdrop.click(this.options.backdrop=="static"?e.proxy(this.$element[0].focus,this.$element[0]):e.proxy(this.hide,this)),i&&this.$backdrop[0].offsetWidth,this.$backdrop.addClass("in");if(!t)return;i?this.$backdrop.one(e.support.transition.end,t):t()}else!this.isShown&&this.$backdrop?(this.$backdrop.removeClass("in"),e.support.transition&&this.$element.hasClass("fade")?this.$backdrop.one(e.support.transition.end,t):t()):t&&t()}};var n=e.fn.modal;e.fn.modal=function(n){return this.each(function(){var r=e(this),i=r.data("modal"),s=e.extend({},e.fn.modal.defaults,r.data(),typeof n=="object"&&n);i||r.data("modal",i=new t(this,s)),typeof n=="string"?i[n]():s.show&&i.show()})},e.fn.modal.defaults={backdrop:!0,keyboard:!0,show:!0},e.fn.modal.Constructor=t,e.fn.modal.noConflict=function(){return e.fn.modal=n,this},e(document).on("click.modal.data-api",'[data-toggle="modal"]',function(t){var n=e(this),r=n.attr("href"),i=e(n.attr("data-target")||r&&r.replace(/.*(?=#[^\s]+$)/,"")),s=i.data("modal")?"toggle":e.extend({remote:!/#/.test(r)&&r},i.data(),n.data());t.preventDefault(),i.modal(s).one("hide",function(){n.focus()})})}(window.jQuery),!function(e){"use strict";var t=function(e,t){this.init("tooltip",e,t)};t.prototype={constructor:t,init:function(t,n,r){var i,s,o,u,a;this.type=t,this.$element=e(n),this.options=this.getOptions(r),this.enabled=!0,o=this.options.trigger.split(" ");for(a=o.length;a--;)u=o[a],u=="click"?this.$element.on("click."+this.type,this.options.selector,e.proxy(this.toggle,this)):u!="manual"&&(i=u=="hover"?"mouseenter":"focus",s=u=="hover"?"mouseleave":"blur",this.$element.on(i+"."+this.type,this.options.selector,e.proxy(this.enter,this)),this.$element.on(s+"."+this.type,this.options.selector,e.proxy(this.leave,this)));this.options.selector?this._options=e.extend({},this.options,{trigger:"manual",selector:""}):this.fixTitle()},getOptions:function(t){return t=e.extend({},e.fn[this.type].defaults,this.$element.data(),t),t.delay&&typeof t.delay=="number"&&(t.delay={show:t.delay,hide:t.delay}),t},enter:function(t){var n=e(t.currentTarget)[this.type](this._options).data(this.type);if(!n.options.delay||!n.options.delay.show)return n.show();clearTimeout(this.timeout),n.hoverState="in",this.timeout=setTimeout(function(){n.hoverState=="in"&&n.show()},n.options.delay.show)},leave:function(t){var n=e(t.currentTarget)[this.type](this._options).data(this.type);this.timeout&&clearTimeout(this.timeout);if(!n.options.delay||!n.options.delay.hide)return n.hide();n.hoverState="out",this.timeout=setTimeout(function(){n.hoverState=="out"&&n.hide()},n.options.delay.hide)},show:function(){var t,n,r,i,s,o,u=e.Event("show");if(this.hasContent()&&this.enabled){this.$element.trigger(u);if(u.isDefaultPrevented())return;t=this.tip(),this.setContent(),this.options.animation&&t.addClass("fade"),s=typeof this.options.placement=="function"?this.options.placement.call(this,t[0],this.$element[0]):this.options.placement,t.detach().css({top:0,left:0,display:"block"}),this.options.container?t.appendTo(this.options.container):t.insertAfter(this.$element),n=this.getPosition(),r=t[0].offsetWidth,i=t[0].offsetHeight;switch(s){case"bottom":o={top:n.top+n.height,left:n.left+n.width/2-r/2};break;case"top":o={top:n.top-i,left:n.left+n.width/2-r/2};break;case"left":o={top:n.top+n.height/2-i/2,left:n.left-r};break;case"right":o={top:n.top+n.height/2-i/2,left:n.left+n.width}}this.applyPlacement(o,s),this.$element.trigger("shown")}},applyPlacement:function(e,t){var n=this.tip(),r=n[0].offsetWidth,i=n[0].offsetHeight,s,o,u,a;n.offset(e).addClass(t).addClass("in"),s=n[0].offsetWidth,o=n[0].offsetHeight,t=="top"&&o!=i&&(e.top=e.top+i-o,a=!0),t=="bottom"||t=="top"?(u=0,e.left<0&&(u=e.left*-2,e.left=0,n.offset(e),s=n[0].offsetWidth,o=n[0].offsetHeight),this.replaceArrow(u-r+s,s,"left")):this.replaceArrow(o-i,o,"top"),a&&n.offset(e)},replaceArrow:function(e,t,n){this.arrow().css(n,e?50*(1-e/t)+"%":"")},setContent:function(){var e=this.tip(),t=this.getTitle();e.find(".tooltip-inner")[this.options.html?"html":"text"](t),e.removeClass("fade in top bottom left right")},hide:function(){function i(){var t=setTimeout(function(){n.off(e.support.transition.end).detach()},500);n.one(e.support.transition.end,function(){clearTimeout(t),n.detach()})}var t=this,n=this.tip(),r=e.Event("hide");this.$element.trigger(r);if(r.isDefaultPrevented())return;return n.removeClass("in"),e.support.transition&&this.$tip.hasClass("fade")?i():n.detach(),this.$element.trigger("hidden"),this},fixTitle:function(){var e=this.$element;(e.attr("title")||typeof e.attr("data-original-title")!="string")&&e.attr("data-original-title",e.attr("title")||"").attr("title","")},hasContent:function(){return this.getTitle()},getPosition:function(){var t=this.$element[0];return e.extend({},typeof t.getBoundingClientRect=="function"?t.getBoundingClientRect():{width:t.offsetWidth,height:t.offsetHeight},this.$element.offset())},getTitle:function(){var e,t=this.$element,n=this.options;return e=t.attr("data-original-title")||(typeof n.title=="function"?n.title.call(t[0]):n.title),e},tip:function(){return this.$tip=this.$tip||e(this.options.template)},arrow:function(){return this.$arrow=this.$arrow||this.tip().find(".tooltip-arrow")},validate:function(){this.$element[0].parentNode||(this.hide(),this.$element=null,this.options=null)},enable:function(){this.enabled=!0},disable:function(){this.enabled=!1},toggleEnabled:function(){this.enabled=!this.enabled},toggle:function(t){var n=t?e(t.currentTarget)[this.type](this._options).data(this.type):this;n.tip().hasClass("in")?n.hide():n.show()},destroy:function(){this.hide().$element.off("."+this.type).removeData(this.type)}};var n=e.fn.tooltip;e.fn.tooltip=function(n){return this.each(function(){var r=e(this),i=r.data("tooltip"),s=typeof n=="object"&&n;i||r.data("tooltip",i=new t(this,s)),typeof n=="string"&&i[n]()})},e.fn.tooltip.Constructor=t,e.fn.tooltip.defaults={animation:!0,placement:"top",selector:!1,template:'<div class="tooltip"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>',trigger:"hover focus",title:"",delay:0,html:!1,container:!1},e.fn.tooltip.noConflict=function(){return e.fn.tooltip=n,this}}(window.jQuery),!function(e){"use strict";var t=function(e,t){this.init("popover",e,t)};t.prototype=e.extend({},e.fn.tooltip.Constructor.prototype,{constructor:t,setContent:function(){var e=this.tip(),t=this.getTitle(),n=this.getContent();e.find(".popover-title")[this.options.html?"html":"text"](t),e.find(".popover-content")[this.options.html?"html":"text"](n),e.removeClass("fade top bottom left right in")},hasContent:function(){return this.getTitle()||this.getContent()},getContent:function(){var e,t=this.$element,n=this.options;return e=(typeof n.content=="function"?n.content.call(t[0]):n.content)||t.attr("data-content"),e},tip:function(){return this.$tip||(this.$tip=e(this.options.template)),this.$tip},destroy:function(){this.hide().$element.off("."+this.type).removeData(this.type)}});var n=e.fn.popover;e.fn.popover=function(n){return this.each(function(){var r=e(this),i=r.data("popover"),s=typeof n=="object"&&n;i||r.data("popover",i=new t(this,s)),typeof n=="string"&&i[n]()})},e.fn.popover.Constructor=t,e.fn.popover.defaults=e.extend({},e.fn.tooltip.defaults,{placement:"right",trigger:"click",content:"",template:'<div class="popover"><div class="arrow"></div><h3 class="popover-title"></h3><div class="popover-content"></div></div>'}),e.fn.popover.noConflict=function(){return e.fn.popover=n,this}}(window.jQuery),!function(e){"use strict";function t(t,n){var r=e.proxy(this.process,this),i=e(t).is("body")?e(window):e(t),s;this.options=e.extend({},e.fn.scrollspy.defaults,n),this.$scrollElement=i.on("scroll.scroll-spy.data-api",r),this.selector=(this.options.target||(s=e(t).attr("href"))&&s.replace(/.*(?=#[^\s]+$)/,"")||"")+" .nav li > a",this.$body=e("body"),this.refresh(),this.process()}t.prototype={constructor:t,refresh:function(){var t=this,n;this.offsets=e([]),this.targets=e([]),n=this.$body.find(this.selector).map(function(){var n=e(this),r=n.data("target")||n.attr("href"),i=/^#\w/.test(r)&&e(r);return i&&i.length&&[[i.position().top+(!e.isWindow(t.$scrollElement.get(0))&&t.$scrollElement.scrollTop()),r]]||null}).sort(function(e,t){return e[0]-t[0]}).each(function(){t.offsets.push(this[0]),t.targets.push(this[1])})},process:function(){var e=this.$scrollElement.scrollTop()+this.options.offset,t=this.$scrollElement[0].scrollHeight||this.$body[0].scrollHeight,n=t-this.$scrollElement.height(),r=this.offsets,i=this.targets,s=this.activeTarget,o;if(e>=n)return s!=(o=i.last()[0])&&this.activate(o);for(o=r.length;o--;)s!=i[o]&&e>=r[o]&&(!r[o+1]||e<=r[o+1])&&this.activate(i[o])},activate:function(t){var n,r;this.activeTarget=t,e(this.selector).parent(".active").removeClass("active"),r=this.selector+'[data-target="'+t+'"],'+this.selector+'[href="'+t+'"]',n=e(r).parent("li").addClass("active"),n.parent(".dropdown-menu").length&&(n=n.closest("li.dropdown").addClass("active")),n.trigger("activate")}};var n=e.fn.scrollspy;e.fn.scrollspy=function(n){return this.each(function(){var r=e(this),i=r.data("scrollspy"),s=typeof n=="object"&&n;i||r.data("scrollspy",i=new t(this,s)),typeof n=="string"&&i[n]()})},e.fn.scrollspy.Constructor=t,e.fn.scrollspy.defaults={offset:10},e.fn.scrollspy.noConflict=function(){return e.fn.scrollspy=n,this},e(window).on("load",function(){e('[data-spy="scroll"]').each(function(){var t=e(this);t.scrollspy(t.data())})})}(window.jQuery),!function(e){"use strict";var t=function(t){this.element=e(t)};t.prototype={constructor:t,show:function(){var t=this.element,n=t.closest("ul:not(.dropdown-menu)"),r=t.attr("data-target"),i,s,o;r||(r=t.attr("href"),r=r&&r.replace(/.*(?=#[^\s]*$)/,""));if(t.parent("li").hasClass("active"))return;i=n.find(".active:last a")[0],o=e.Event("show",{relatedTarget:i}),t.trigger(o);if(o.isDefaultPrevented())return;s=e(r),this.activate(t.parent("li"),n),this.activate(s,s.parent(),function(){t.trigger({type:"shown",relatedTarget:i})})},activate:function(t,n,r){function o(){i.removeClass("active").find("> .dropdown-menu > .active").removeClass("active"),t.addClass("active"),s?(t[0].offsetWidth,t.addClass("in")):t.removeClass("fade"),t.parent(".dropdown-menu")&&t.closest("li.dropdown").addClass("active"),r&&r()}var i=n.find("> .active"),s=r&&e.support.transition&&i.hasClass("fade");s?i.one(e.support.transition.end,o):o(),i.removeClass("in")}};var n=e.fn.tab;e.fn.tab=function(n){return this.each(function(){var r=e(this),i=r.data("tab");i||r.data("tab",i=new t(this)),typeof n=="string"&&i[n]()})},e.fn.tab.Constructor=t,e.fn.tab.noConflict=function(){return e.fn.tab=n,this},e(document).on("click.tab.data-api",'[data-toggle="tab"], [data-toggle="pill"]',function(t){t.preventDefault(),e(this).tab("show")})}(window.jQuery),!function(e){"use strict";var t=function(t,n){this.$element=e(t),this.options=e.extend({},e.fn.typeahead.defaults,n),this.matcher=this.options.matcher||this.matcher,this.sorter=this.options.sorter||this.sorter,this.highlighter=this.options.highlighter||this.highlighter,this.updater=this.options.updater||this.updater,this.source=this.options.source,this.$menu=e(this.options.menu),this.shown=!1,this.listen()};t.prototype={constructor:t,select:function(){var e=this.$menu.find(".active").attr("data-value");return this.$element.val(this.updater(e)).change(),this.hide()},updater:function(e){return e},show:function(){var t=e.extend({},this.$element.position(),{height:this.$element[0].offsetHeight});return this.$menu.insertAfter(this.$element).css({top:t.top+t.height,left:t.left}).show(),this.shown=!0,this},hide:function(){return this.$menu.hide(),this.shown=!1,this},lookup:function(t){var n;return this.query=this.$element.val(),!this.query||this.query.length<this.options.minLength?this.shown?this.hide():this:(n=e.isFunction(this.source)?this.source(this.query,e.proxy(this.process,this)):this.source,n?this.process(n):this)},process:function(t){var n=this;return t=e.grep(t,function(e){return n.matcher(e)}),t=this.sorter(t),t.length?this.render(t.slice(0,this.options.items)).show():this.shown?this.hide():this},matcher:function(e){return~e.toLowerCase().indexOf(this.query.toLowerCase())},sorter:function(e){var t=[],n=[],r=[],i;while(i=e.shift())i.toLowerCase().indexOf(this.query.toLowerCase())?~i.indexOf(this.query)?n.push(i):r.push(i):t.push(i);return t.concat(n,r)},highlighter:function(e){var t=this.query.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&");return e.replace(new RegExp("("+t+")","ig"),function(e,t){return"<strong>"+t+"</strong>"})},render:function(t){var n=this;return t=e(t).map(function(t,r){return t=e(n.options.item).attr("data-value",r),t.find("a").html(n.highlighter(r)),t[0]}),t.first().addClass("active"),this.$menu.html(t),this},next:function(t){var n=this.$menu.find(".active").removeClass("active"),r=n.next();r.length||(r=e(this.$menu.find("li")[0])),r.addClass("active")},prev:function(e){var t=this.$menu.find(".active").removeClass("active"),n=t.prev();n.length||(n=this.$menu.find("li").last()),n.addClass("active")},listen:function(){this.$element.on("focus",e.proxy(this.focus,this)).on("blur",e.proxy(this.blur,this)).on("keypress",e.proxy(this.keypress,this)).on("keyup",e.proxy(this.keyup,this)),this.eventSupported("keydown")&&this.$element.on("keydown",e.proxy(this.keydown,this)),this.$menu.on("click",e.proxy(this.click,this)).on("mouseenter","li",e.proxy(this.mouseenter,this)).on("mouseleave","li",e.proxy(this.mouseleave,this))},eventSupported:function(e){var t=e in this.$element;return t||(this.$element.setAttribute(e,"return;"),t=typeof this.$element[e]=="function"),t},move:function(e){if(!this.shown)return;switch(e.keyCode){case 9:case 13:case 27:e.preventDefault();break;case 38:e.preventDefault(),this.prev();break;case 40:e.preventDefault(),this.next()}e.stopPropagation()},keydown:function(t){this.suppressKeyPressRepeat=~e.inArray(t.keyCode,[40,38,9,13,27]),this.move(t)},keypress:function(e){if(this.suppressKeyPressRepeat)return;this.move(e)},keyup:function(e){switch(e.keyCode){case 40:case 38:case 16:case 17:case 18:break;case 9:case 13:if(!this.shown)return;this.select();break;case 27:if(!this.shown)return;this.hide();break;default:this.lookup()}e.stopPropagation(),e.preventDefault()},focus:function(e){this.focused=!0},blur:function(e){this.focused=!1,!this.mousedover&&this.shown&&this.hide()},click:function(e){e.stopPropagation(),e.preventDefault(),this.select(),this.$element.focus()},mouseenter:function(t){this.mousedover=!0,this.$menu.find(".active").removeClass("active"),e(t.currentTarget).addClass("active")},mouseleave:function(e){this.mousedover=!1,!this.focused&&this.shown&&this.hide()}};var n=e.fn.typeahead;e.fn.typeahead=function(n){return this.each(function(){var r=e(this),i=r.data("typeahead"),s=typeof n=="object"&&n;i||r.data("typeahead",i=new t(this,s)),typeof n=="string"&&i[n]()})},e.fn.typeahead.defaults={source:[],items:8,menu:'<ul class="typeahead dropdown-menu"></ul>',item:'<li><a href="#"></a></li>',minLength:1},e.fn.typeahead.Constructor=t,e.fn.typeahead.noConflict=function(){return e.fn.typeahead=n,this},e(document).on("focus.typeahead.data-api",'[data-provide="typeahead"]',function(t){var n=e(this);if(n.data("typeahead"))return;n.typeahead(n.data())})}(window.jQuery),!function(e){"use strict";var t=function(t,n){this.options=e.extend({},e.fn.affix.defaults,n),this.$window=e(window).on("scroll.affix.data-api",e.proxy(this.checkPosition,this)).on("click.affix.data-api",e.proxy(function(){setTimeout(e.proxy(this.checkPosition,this),1)},this)),this.$element=e(t),this.checkPosition()};t.prototype.checkPosition=function(){if(!this.$element.is(":visible"))return;var t=e(document).height(),n=this.$window.scrollTop(),r=this.$element.offset(),i=this.options.offset,s=i.bottom,o=i.top,u="affix affix-top affix-bottom",a;typeof i!="object"&&(s=o=i),typeof o=="function"&&(o=i.top()),typeof s=="function"&&(s=i.bottom()),a=this.unpin!=null&&n+this.unpin<=r.top?!1:s!=null&&r.top+this.$element.height()>=t-s?"bottom":o!=null&&n<=o?"top":!1;if(this.affixed===a)return;this.affixed=a,this.unpin=a=="bottom"?r.top-n:null,this.$element.removeClass(u).addClass("affix"+(a?"-"+a:""))};var n=e.fn.affix;e.fn.affix=function(n){return this.each(function(){var r=e(this),i=r.data("affix"),s=typeof n=="object"&&n;i||r.data("affix",i=new t(this,s)),typeof n=="string"&&i[n]()})},e.fn.affix.Constructor=t,e.fn.affix.defaults={offset:0},e.fn.affix.noConflict=function(){return e.fn.affix=n,this},e(window).on("load",function(){e('[data-spy="affix"]').each(function(){var t=e(this),n=t.data();n.offset=n.offset||{},n.offsetBottom&&(n.offset.bottom=n.offsetBottom),n.offsetTop&&(n.offset.top=n.offsetTop),t.affix(n)})})}(window.jQuery);
\ No newline at end of file
diff --git a/docs/theme/docker/static/js/vendor/jquery-1.9.1.min.js b/docs/theme/docker/static/js/vendor/jquery-1.9.1.min.js
deleted file mode 100755
index 006e953..0000000
--- a/docs/theme/docker/static/js/vendor/jquery-1.9.1.min.js
+++ /dev/null
@@ -1,5 +0,0 @@
-/*! jQuery v1.9.1 | (c) 2005, 2012 jQuery Foundation, Inc. | jquery.org/license
-//@ sourceMappingURL=jquery.min.map
-*/(function(e,t){var n,r,i=typeof t,o=e.document,a=e.location,s=e.jQuery,u=e.$,l={},c=[],p="1.9.1",f=c.concat,d=c.push,h=c.slice,g=c.indexOf,m=l.toString,y=l.hasOwnProperty,v=p.trim,b=function(e,t){return new b.fn.init(e,t,r)},x=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,w=/\S+/g,T=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,N=/^(?:(<[\w\W]+>)[^>]*|#([\w-]*))$/,C=/^<(\w+)\s*\/?>(?:<\/\1>|)$/,k=/^[\],:{}\s]*$/,E=/(?:^|:|,)(?:\s*\[)+/g,S=/\\(?:["\\\/bfnrt]|u[\da-fA-F]{4})/g,A=/"[^"\\\r\n]*"|true|false|null|-?(?:\d+\.|)\d+(?:[eE][+-]?\d+|)/g,j=/^-ms-/,D=/-([\da-z])/gi,L=function(e,t){return t.toUpperCase()},H=function(e){(o.addEventListener||"load"===e.type||"complete"===o.readyState)&&(q(),b.ready())},q=function(){o.addEventListener?(o.removeEventListener("DOMContentLoaded",H,!1),e.removeEventListener("load",H,!1)):(o.detachEvent("onreadystatechange",H),e.detachEvent("onload",H))};b.fn=b.prototype={jquery:p,constructor:b,init:function(e,n,r){var i,a;if(!e)return this;if("string"==typeof e){if(i="<"===e.charAt(0)&&">"===e.charAt(e.length-1)&&e.length>=3?[null,e,null]:N.exec(e),!i||!i[1]&&n)return!n||n.jquery?(n||r).find(e):this.constructor(n).find(e);if(i[1]){if(n=n instanceof b?n[0]:n,b.merge(this,b.parseHTML(i[1],n&&n.nodeType?n.ownerDocument||n:o,!0)),C.test(i[1])&&b.isPlainObject(n))for(i in n)b.isFunction(this[i])?this[i](n[i]):this.attr(i,n[i]);return this}if(a=o.getElementById(i[2]),a&&a.parentNode){if(a.id!==i[2])return r.find(e);this.length=1,this[0]=a}return this.context=o,this.selector=e,this}return e.nodeType?(this.context=this[0]=e,this.length=1,this):b.isFunction(e)?r.ready(e):(e.selector!==t&&(this.selector=e.selector,this.context=e.context),b.makeArray(e,this))},selector:"",length:0,size:function(){return this.length},toArray:function(){return h.call(this)},get:function(e){return null==e?this.toArray():0>e?this[this.length+e]:this[e]},pushStack:function(e){var t=b.merge(this.constructor(),e);return t.prevObject=this,t.context=this.context,t},each:function(e,t){return b.each(this,e,t)},ready:function(e){return b.ready.promise().done(e),this},slice:function(){return this.pushStack(h.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(e){var t=this.length,n=+e+(0>e?t:0);return this.pushStack(n>=0&&t>n?[this[n]]:[])},map:function(e){return this.pushStack(b.map(this,function(t,n){return e.call(t,n,t)}))},end:function(){return this.prevObject||this.constructor(null)},push:d,sort:[].sort,splice:[].splice},b.fn.init.prototype=b.fn,b.extend=b.fn.extend=function(){var e,n,r,i,o,a,s=arguments[0]||{},u=1,l=arguments.length,c=!1;for("boolean"==typeof s&&(c=s,s=arguments[1]||{},u=2),"object"==typeof s||b.isFunction(s)||(s={}),l===u&&(s=this,--u);l>u;u++)if(null!=(o=arguments[u]))for(i in o)e=s[i],r=o[i],s!==r&&(c&&r&&(b.isPlainObject(r)||(n=b.isArray(r)))?(n?(n=!1,a=e&&b.isArray(e)?e:[]):a=e&&b.isPlainObject(e)?e:{},s[i]=b.extend(c,a,r)):r!==t&&(s[i]=r));return s},b.extend({noConflict:function(t){return e.$===b&&(e.$=u),t&&e.jQuery===b&&(e.jQuery=s),b},isReady:!1,readyWait:1,holdReady:function(e){e?b.readyWait++:b.ready(!0)},ready:function(e){if(e===!0?!--b.readyWait:!b.isReady){if(!o.body)return setTimeout(b.ready);b.isReady=!0,e!==!0&&--b.readyWait>0||(n.resolveWith(o,[b]),b.fn.trigger&&b(o).trigger("ready").off("ready"))}},isFunction:function(e){return"function"===b.type(e)},isArray:Array.isArray||function(e){return"array"===b.type(e)},isWindow:function(e){return null!=e&&e==e.window},isNumeric:function(e){return!isNaN(parseFloat(e))&&isFinite(e)},type:function(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?l[m.call(e)]||"object":typeof e},isPlainObject:function(e){if(!e||"object"!==b.type(e)||e.nodeType||b.isWindow(e))return!1;try{if(e.constructor&&!y.call(e,"constructor")&&!y.call(e.constructor.prototype,"isPrototypeOf"))return!1}catch(n){return!1}var r;for(r in e);return r===t||y.call(e,r)},isEmptyObject:function(e){var t;for(t in e)return!1;return!0},error:function(e){throw Error(e)},parseHTML:function(e,t,n){if(!e||"string"!=typeof e)return null;"boolean"==typeof t&&(n=t,t=!1),t=t||o;var r=C.exec(e),i=!n&&[];return r?[t.createElement(r[1])]:(r=b.buildFragment([e],t,i),i&&b(i).remove(),b.merge([],r.childNodes))},parseJSON:function(n){return e.JSON&&e.JSON.parse?e.JSON.parse(n):null===n?n:"string"==typeof n&&(n=b.trim(n),n&&k.test(n.replace(S,"@").replace(A,"]").replace(E,"")))?Function("return "+n)():(b.error("Invalid JSON: "+n),t)},parseXML:function(n){var r,i;if(!n||"string"!=typeof n)return null;try{e.DOMParser?(i=new DOMParser,r=i.parseFromString(n,"text/xml")):(r=new ActiveXObject("Microsoft.XMLDOM"),r.async="false",r.loadXML(n))}catch(o){r=t}return r&&r.documentElement&&!r.getElementsByTagName("parsererror").length||b.error("Invalid XML: "+n),r},noop:function(){},globalEval:function(t){t&&b.trim(t)&&(e.execScript||function(t){e.eval.call(e,t)})(t)},camelCase:function(e){return e.replace(j,"ms-").replace(D,L)},nodeName:function(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()},each:function(e,t,n){var r,i=0,o=e.length,a=M(e);if(n){if(a){for(;o>i;i++)if(r=t.apply(e[i],n),r===!1)break}else for(i in e)if(r=t.apply(e[i],n),r===!1)break}else if(a){for(;o>i;i++)if(r=t.call(e[i],i,e[i]),r===!1)break}else for(i in e)if(r=t.call(e[i],i,e[i]),r===!1)break;return e},trim:v&&!v.call("\ufeff\u00a0")?function(e){return null==e?"":v.call(e)}:function(e){return null==e?"":(e+"").replace(T,"")},makeArray:function(e,t){var n=t||[];return null!=e&&(M(Object(e))?b.merge(n,"string"==typeof e?[e]:e):d.call(n,e)),n},inArray:function(e,t,n){var r;if(t){if(g)return g.call(t,e,n);for(r=t.length,n=n?0>n?Math.max(0,r+n):n:0;r>n;n++)if(n in t&&t[n]===e)return n}return-1},merge:function(e,n){var r=n.length,i=e.length,o=0;if("number"==typeof r)for(;r>o;o++)e[i++]=n[o];else while(n[o]!==t)e[i++]=n[o++];return e.length=i,e},grep:function(e,t,n){var r,i=[],o=0,a=e.length;for(n=!!n;a>o;o++)r=!!t(e[o],o),n!==r&&i.push(e[o]);return i},map:function(e,t,n){var r,i=0,o=e.length,a=M(e),s=[];if(a)for(;o>i;i++)r=t(e[i],i,n),null!=r&&(s[s.length]=r);else for(i in e)r=t(e[i],i,n),null!=r&&(s[s.length]=r);return f.apply([],s)},guid:1,proxy:function(e,n){var r,i,o;return"string"==typeof n&&(o=e[n],n=e,e=o),b.isFunction(e)?(r=h.call(arguments,2),i=function(){return e.apply(n||this,r.concat(h.call(arguments)))},i.guid=e.guid=e.guid||b.guid++,i):t},access:function(e,n,r,i,o,a,s){var u=0,l=e.length,c=null==r;if("object"===b.type(r)){o=!0;for(u in r)b.access(e,n,u,r[u],!0,a,s)}else if(i!==t&&(o=!0,b.isFunction(i)||(s=!0),c&&(s?(n.call(e,i),n=null):(c=n,n=function(e,t,n){return c.call(b(e),n)})),n))for(;l>u;u++)n(e[u],r,s?i:i.call(e[u],u,n(e[u],r)));return o?e:c?n.call(e):l?n(e[0],r):a},now:function(){return(new Date).getTime()}}),b.ready.promise=function(t){if(!n)if(n=b.Deferred(),"complete"===o.readyState)setTimeout(b.ready);else if(o.addEventListener)o.addEventListener("DOMContentLoaded",H,!1),e.addEventListener("load",H,!1);else{o.attachEvent("onreadystatechange",H),e.attachEvent("onload",H);var r=!1;try{r=null==e.frameElement&&o.documentElement}catch(i){}r&&r.doScroll&&function a(){if(!b.isReady){try{r.doScroll("left")}catch(e){return setTimeout(a,50)}q(),b.ready()}}()}return n.promise(t)},b.each("Boolean Number String Function Array Date RegExp Object Error".split(" "),function(e,t){l["[object "+t+"]"]=t.toLowerCase()});function M(e){var t=e.length,n=b.type(e);return b.isWindow(e)?!1:1===e.nodeType&&t?!0:"array"===n||"function"!==n&&(0===t||"number"==typeof t&&t>0&&t-1 in e)}r=b(o);var _={};function F(e){var t=_[e]={};return b.each(e.match(w)||[],function(e,n){t[n]=!0}),t}b.Callbacks=function(e){e="string"==typeof e?_[e]||F(e):b.extend({},e);var n,r,i,o,a,s,u=[],l=!e.once&&[],c=function(t){for(r=e.memory&&t,i=!0,a=s||0,s=0,o=u.length,n=!0;u&&o>a;a++)if(u[a].apply(t[0],t[1])===!1&&e.stopOnFalse){r=!1;break}n=!1,u&&(l?l.length&&c(l.shift()):r?u=[]:p.disable())},p={add:function(){if(u){var t=u.length;(function i(t){b.each(t,function(t,n){var r=b.type(n);"function"===r?e.unique&&p.has(n)||u.push(n):n&&n.length&&"string"!==r&&i(n)})})(arguments),n?o=u.length:r&&(s=t,c(r))}return this},remove:function(){return u&&b.each(arguments,function(e,t){var r;while((r=b.inArray(t,u,r))>-1)u.splice(r,1),n&&(o>=r&&o--,a>=r&&a--)}),this},has:function(e){return e?b.inArray(e,u)>-1:!(!u||!u.length)},empty:function(){return u=[],this},disable:function(){return u=l=r=t,this},disabled:function(){return!u},lock:function(){return l=t,r||p.disable(),this},locked:function(){return!l},fireWith:function(e,t){return t=t||[],t=[e,t.slice?t.slice():t],!u||i&&!l||(n?l.push(t):c(t)),this},fire:function(){return p.fireWith(this,arguments),this},fired:function(){return!!i}};return p},b.extend({Deferred:function(e){var t=[["resolve","done",b.Callbacks("once memory"),"resolved"],["reject","fail",b.Callbacks("once memory"),"rejected"],["notify","progress",b.Callbacks("memory")]],n="pending",r={state:function(){return n},always:function(){return i.done(arguments).fail(arguments),this},then:function(){var e=arguments;return b.Deferred(function(n){b.each(t,function(t,o){var a=o[0],s=b.isFunction(e[t])&&e[t];i[o[1]](function(){var e=s&&s.apply(this,arguments);e&&b.isFunction(e.promise)?e.promise().done(n.resolve).fail(n.reject).progress(n.notify):n[a+"With"](this===r?n.promise():this,s?[e]:arguments)})}),e=null}).promise()},promise:function(e){return null!=e?b.extend(e,r):r}},i={};return r.pipe=r.then,b.each(t,function(e,o){var a=o[2],s=o[3];r[o[1]]=a.add,s&&a.add(function(){n=s},t[1^e][2].disable,t[2][2].lock),i[o[0]]=function(){return i[o[0]+"With"](this===i?r:this,arguments),this},i[o[0]+"With"]=a.fireWith}),r.promise(i),e&&e.call(i,i),i},when:function(e){var t=0,n=h.call(arguments),r=n.length,i=1!==r||e&&b.isFunction(e.promise)?r:0,o=1===i?e:b.Deferred(),a=function(e,t,n){return function(r){t[e]=this,n[e]=arguments.length>1?h.call(arguments):r,n===s?o.notifyWith(t,n):--i||o.resolveWith(t,n)}},s,u,l;if(r>1)for(s=Array(r),u=Array(r),l=Array(r);r>t;t++)n[t]&&b.isFunction(n[t].promise)?n[t].promise().done(a(t,l,n)).fail(o.reject).progress(a(t,u,s)):--i;return i||o.resolveWith(l,n),o.promise()}}),b.support=function(){var t,n,r,a,s,u,l,c,p,f,d=o.createElement("div");if(d.setAttribute("className","t"),d.innerHTML="  <link/><table></table><a href='/a'>a</a><input type='checkbox'/>",n=d.getElementsByTagName("*"),r=d.getElementsByTagName("a")[0],!n||!r||!n.length)return{};s=o.createElement("select"),l=s.appendChild(o.createElement("option")),a=d.getElementsByTagName("input")[0],r.style.cssText="top:1px;float:left;opacity:.5",t={getSetAttribute:"t"!==d.className,leadingWhitespace:3===d.firstChild.nodeType,tbody:!d.getElementsByTagName("tbody").length,htmlSerialize:!!d.getElementsByTagName("link").length,style:/top/.test(r.getAttribute("style")),hrefNormalized:"/a"===r.getAttribute("href"),opacity:/^0.5/.test(r.style.opacity),cssFloat:!!r.style.cssFloat,checkOn:!!a.value,optSelected:l.selected,enctype:!!o.createElement("form").enctype,html5Clone:"<:nav></:nav>"!==o.createElement("nav").cloneNode(!0).outerHTML,boxModel:"CSS1Compat"===o.compatMode,deleteExpando:!0,noCloneEvent:!0,inlineBlockNeedsLayout:!1,shrinkWrapBlocks:!1,reliableMarginRight:!0,boxSizingReliable:!0,pixelPosition:!1},a.checked=!0,t.noCloneChecked=a.cloneNode(!0).checked,s.disabled=!0,t.optDisabled=!l.disabled;try{delete d.test}catch(h){t.deleteExpando=!1}a=o.createElement("input"),a.setAttribute("value",""),t.input=""===a.getAttribute("value"),a.value="t",a.setAttribute("type","radio"),t.radioValue="t"===a.value,a.setAttribute("checked","t"),a.setAttribute("name","t"),u=o.createDocumentFragment(),u.appendChild(a),t.appendChecked=a.checked,t.checkClone=u.cloneNode(!0).cloneNode(!0).lastChild.checked,d.attachEvent&&(d.attachEvent("onclick",function(){t.noCloneEvent=!1}),d.cloneNode(!0).click());for(f in{submit:!0,change:!0,focusin:!0})d.setAttribute(c="on"+f,"t"),t[f+"Bubbles"]=c in e||d.attributes[c].expando===!1;return d.style.backgroundClip="content-box",d.cloneNode(!0).style.backgroundClip="",t.clearCloneStyle="content-box"===d.style.backgroundClip,b(function(){var n,r,a,s="padding:0;margin:0;border:0;display:block;box-sizing:content-box;-moz-box-sizing:content-box;-webkit-box-sizing:content-box;",u=o.getElementsByTagName("body")[0];u&&(n=o.createElement("div"),n.style.cssText="border:0;width:0;height:0;position:absolute;top:0;left:-9999px;margin-top:1px",u.appendChild(n).appendChild(d),d.innerHTML="<table><tr><td></td><td>t</td></tr></table>",a=d.getElementsByTagName("td"),a[0].style.cssText="padding:0;margin:0;border:0;display:none",p=0===a[0].offsetHeight,a[0].style.display="",a[1].style.display="none",t.reliableHiddenOffsets=p&&0===a[0].offsetHeight,d.innerHTML="",d.style.cssText="box-sizing:border-box;-moz-box-sizing:border-box;-webkit-box-sizing:border-box;padding:1px;border:1px;display:block;width:4px;margin-top:1%;position:absolute;top:1%;",t.boxSizing=4===d.offsetWidth,t.doesNotIncludeMarginInBodyOffset=1!==u.offsetTop,e.getComputedStyle&&(t.pixelPosition="1%"!==(e.getComputedStyle(d,null)||{}).top,t.boxSizingReliable="4px"===(e.getComputedStyle(d,null)||{width:"4px"}).width,r=d.appendChild(o.createElement("div")),r.style.cssText=d.style.cssText=s,r.style.marginRight=r.style.width="0",d.style.width="1px",t.reliableMarginRight=!parseFloat((e.getComputedStyle(r,null)||{}).marginRight)),typeof d.style.zoom!==i&&(d.innerHTML="",d.style.cssText=s+"width:1px;padding:1px;display:inline;zoom:1",t.inlineBlockNeedsLayout=3===d.offsetWidth,d.style.display="block",d.innerHTML="<div></div>",d.firstChild.style.width="5px",t.shrinkWrapBlocks=3!==d.offsetWidth,t.inlineBlockNeedsLayout&&(u.style.zoom=1)),u.removeChild(n),n=d=a=r=null)}),n=s=u=l=r=a=null,t}();var O=/(?:\{[\s\S]*\}|\[[\s\S]*\])$/,B=/([A-Z])/g;function P(e,n,r,i){if(b.acceptData(e)){var o,a,s=b.expando,u="string"==typeof n,l=e.nodeType,p=l?b.cache:e,f=l?e[s]:e[s]&&s;if(f&&p[f]&&(i||p[f].data)||!u||r!==t)return f||(l?e[s]=f=c.pop()||b.guid++:f=s),p[f]||(p[f]={},l||(p[f].toJSON=b.noop)),("object"==typeof n||"function"==typeof n)&&(i?p[f]=b.extend(p[f],n):p[f].data=b.extend(p[f].data,n)),o=p[f],i||(o.data||(o.data={}),o=o.data),r!==t&&(o[b.camelCase(n)]=r),u?(a=o[n],null==a&&(a=o[b.camelCase(n)])):a=o,a}}function R(e,t,n){if(b.acceptData(e)){var r,i,o,a=e.nodeType,s=a?b.cache:e,u=a?e[b.expando]:b.expando;if(s[u]){if(t&&(o=n?s[u]:s[u].data)){b.isArray(t)?t=t.concat(b.map(t,b.camelCase)):t in o?t=[t]:(t=b.camelCase(t),t=t in o?[t]:t.split(" "));for(r=0,i=t.length;i>r;r++)delete o[t[r]];if(!(n?$:b.isEmptyObject)(o))return}(n||(delete s[u].data,$(s[u])))&&(a?b.cleanData([e],!0):b.support.deleteExpando||s!=s.window?delete s[u]:s[u]=null)}}}b.extend({cache:{},expando:"jQuery"+(p+Math.random()).replace(/\D/g,""),noData:{embed:!0,object:"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000",applet:!0},hasData:function(e){return e=e.nodeType?b.cache[e[b.expando]]:e[b.expando],!!e&&!$(e)},data:function(e,t,n){return P(e,t,n)},removeData:function(e,t){return R(e,t)},_data:function(e,t,n){return P(e,t,n,!0)},_removeData:function(e,t){return R(e,t,!0)},acceptData:function(e){if(e.nodeType&&1!==e.nodeType&&9!==e.nodeType)return!1;var t=e.nodeName&&b.noData[e.nodeName.toLowerCase()];return!t||t!==!0&&e.getAttribute("classid")===t}}),b.fn.extend({data:function(e,n){var r,i,o=this[0],a=0,s=null;if(e===t){if(this.length&&(s=b.data(o),1===o.nodeType&&!b._data(o,"parsedAttrs"))){for(r=o.attributes;r.length>a;a++)i=r[a].name,i.indexOf("data-")||(i=b.camelCase(i.slice(5)),W(o,i,s[i]));b._data(o,"parsedAttrs",!0)}return s}return"object"==typeof e?this.each(function(){b.data(this,e)}):b.access(this,function(n){return n===t?o?W(o,e,b.data(o,e)):null:(this.each(function(){b.data(this,e,n)}),t)},null,n,arguments.length>1,null,!0)},removeData:function(e){return this.each(function(){b.removeData(this,e)})}});function W(e,n,r){if(r===t&&1===e.nodeType){var i="data-"+n.replace(B,"-$1").toLowerCase();if(r=e.getAttribute(i),"string"==typeof r){try{r="true"===r?!0:"false"===r?!1:"null"===r?null:+r+""===r?+r:O.test(r)?b.parseJSON(r):r}catch(o){}b.data(e,n,r)}else r=t}return r}function $(e){var t;for(t in e)if(("data"!==t||!b.isEmptyObject(e[t]))&&"toJSON"!==t)return!1;return!0}b.extend({queue:function(e,n,r){var i;return e?(n=(n||"fx")+"queue",i=b._data(e,n),r&&(!i||b.isArray(r)?i=b._data(e,n,b.makeArray(r)):i.push(r)),i||[]):t},dequeue:function(e,t){t=t||"fx";var n=b.queue(e,t),r=n.length,i=n.shift(),o=b._queueHooks(e,t),a=function(){b.dequeue(e,t)};"inprogress"===i&&(i=n.shift(),r--),o.cur=i,i&&("fx"===t&&n.unshift("inprogress"),delete o.stop,i.call(e,a,o)),!r&&o&&o.empty.fire()},_queueHooks:function(e,t){var n=t+"queueHooks";return b._data(e,n)||b._data(e,n,{empty:b.Callbacks("once memory").add(function(){b._removeData(e,t+"queue"),b._removeData(e,n)})})}}),b.fn.extend({queue:function(e,n){var r=2;return"string"!=typeof e&&(n=e,e="fx",r--),r>arguments.length?b.queue(this[0],e):n===t?this:this.each(function(){var t=b.queue(this,e,n);b._queueHooks(this,e),"fx"===e&&"inprogress"!==t[0]&&b.dequeue(this,e)})},dequeue:function(e){return this.each(function(){b.dequeue(this,e)})},delay:function(e,t){return e=b.fx?b.fx.speeds[e]||e:e,t=t||"fx",this.queue(t,function(t,n){var r=setTimeout(t,e);n.stop=function(){clearTimeout(r)}})},clearQueue:function(e){return this.queue(e||"fx",[])},promise:function(e,n){var r,i=1,o=b.Deferred(),a=this,s=this.length,u=function(){--i||o.resolveWith(a,[a])};"string"!=typeof e&&(n=e,e=t),e=e||"fx";while(s--)r=b._data(a[s],e+"queueHooks"),r&&r.empty&&(i++,r.empty.add(u));return u(),o.promise(n)}});var I,z,X=/[\t\r\n]/g,U=/\r/g,V=/^(?:input|select|textarea|button|object)$/i,Y=/^(?:a|area)$/i,J=/^(?:checked|selected|autofocus|autoplay|async|controls|defer|disabled|hidden|loop|multiple|open|readonly|required|scoped)$/i,G=/^(?:checked|selected)$/i,Q=b.support.getSetAttribute,K=b.support.input;b.fn.extend({attr:function(e,t){return b.access(this,b.attr,e,t,arguments.length>1)},removeAttr:function(e){return this.each(function(){b.removeAttr(this,e)})},prop:function(e,t){return b.access(this,b.prop,e,t,arguments.length>1)},removeProp:function(e){return e=b.propFix[e]||e,this.each(function(){try{this[e]=t,delete this[e]}catch(n){}})},addClass:function(e){var t,n,r,i,o,a=0,s=this.length,u="string"==typeof e&&e;if(b.isFunction(e))return this.each(function(t){b(this).addClass(e.call(this,t,this.className))});if(u)for(t=(e||"").match(w)||[];s>a;a++)if(n=this[a],r=1===n.nodeType&&(n.className?(" "+n.className+" ").replace(X," "):" ")){o=0;while(i=t[o++])0>r.indexOf(" "+i+" ")&&(r+=i+" ");n.className=b.trim(r)}return this},removeClass:function(e){var t,n,r,i,o,a=0,s=this.length,u=0===arguments.length||"string"==typeof e&&e;if(b.isFunction(e))return this.each(function(t){b(this).removeClass(e.call(this,t,this.className))});if(u)for(t=(e||"").match(w)||[];s>a;a++)if(n=this[a],r=1===n.nodeType&&(n.className?(" "+n.className+" ").replace(X," "):"")){o=0;while(i=t[o++])while(r.indexOf(" "+i+" ")>=0)r=r.replace(" "+i+" "," ");n.className=e?b.trim(r):""}return this},toggleClass:function(e,t){var n=typeof e,r="boolean"==typeof t;return b.isFunction(e)?this.each(function(n){b(this).toggleClass(e.call(this,n,this.className,t),t)}):this.each(function(){if("string"===n){var o,a=0,s=b(this),u=t,l=e.match(w)||[];while(o=l[a++])u=r?u:!s.hasClass(o),s[u?"addClass":"removeClass"](o)}else(n===i||"boolean"===n)&&(this.className&&b._data(this,"__className__",this.className),this.className=this.className||e===!1?"":b._data(this,"__className__")||"")})},hasClass:function(e){var t=" "+e+" ",n=0,r=this.length;for(;r>n;n++)if(1===this[n].nodeType&&(" "+this[n].className+" ").replace(X," ").indexOf(t)>=0)return!0;return!1},val:function(e){var n,r,i,o=this[0];{if(arguments.length)return i=b.isFunction(e),this.each(function(n){var o,a=b(this);1===this.nodeType&&(o=i?e.call(this,n,a.val()):e,null==o?o="":"number"==typeof o?o+="":b.isArray(o)&&(o=b.map(o,function(e){return null==e?"":e+""})),r=b.valHooks[this.type]||b.valHooks[this.nodeName.toLowerCase()],r&&"set"in r&&r.set(this,o,"value")!==t||(this.value=o))});if(o)return r=b.valHooks[o.type]||b.valHooks[o.nodeName.toLowerCase()],r&&"get"in r&&(n=r.get(o,"value"))!==t?n:(n=o.value,"string"==typeof n?n.replace(U,""):null==n?"":n)}}}),b.extend({valHooks:{option:{get:function(e){var t=e.attributes.value;return!t||t.specified?e.value:e.text}},select:{get:function(e){var t,n,r=e.options,i=e.selectedIndex,o="select-one"===e.type||0>i,a=o?null:[],s=o?i+1:r.length,u=0>i?s:o?i:0;for(;s>u;u++)if(n=r[u],!(!n.selected&&u!==i||(b.support.optDisabled?n.disabled:null!==n.getAttribute("disabled"))||n.parentNode.disabled&&b.nodeName(n.parentNode,"optgroup"))){if(t=b(n).val(),o)return t;a.push(t)}return a},set:function(e,t){var n=b.makeArray(t);return b(e).find("option").each(function(){this.selected=b.inArray(b(this).val(),n)>=0}),n.length||(e.selectedIndex=-1),n}}},attr:function(e,n,r){var o,a,s,u=e.nodeType;if(e&&3!==u&&8!==u&&2!==u)return typeof e.getAttribute===i?b.prop(e,n,r):(a=1!==u||!b.isXMLDoc(e),a&&(n=n.toLowerCase(),o=b.attrHooks[n]||(J.test(n)?z:I)),r===t?o&&a&&"get"in o&&null!==(s=o.get(e,n))?s:(typeof e.getAttribute!==i&&(s=e.getAttribute(n)),null==s?t:s):null!==r?o&&a&&"set"in o&&(s=o.set(e,r,n))!==t?s:(e.setAttribute(n,r+""),r):(b.removeAttr(e,n),t))},removeAttr:function(e,t){var n,r,i=0,o=t&&t.match(w);if(o&&1===e.nodeType)while(n=o[i++])r=b.propFix[n]||n,J.test(n)?!Q&&G.test(n)?e[b.camelCase("default-"+n)]=e[r]=!1:e[r]=!1:b.attr(e,n,""),e.removeAttribute(Q?n:r)},attrHooks:{type:{set:function(e,t){if(!b.support.radioValue&&"radio"===t&&b.nodeName(e,"input")){var n=e.value;return e.setAttribute("type",t),n&&(e.value=n),t}}}},propFix:{tabindex:"tabIndex",readonly:"readOnly","for":"htmlFor","class":"className",maxlength:"maxLength",cellspacing:"cellSpacing",cellpadding:"cellPadding",rowspan:"rowSpan",colspan:"colSpan",usemap:"useMap",frameborder:"frameBorder",contenteditable:"contentEditable"},prop:function(e,n,r){var i,o,a,s=e.nodeType;if(e&&3!==s&&8!==s&&2!==s)return a=1!==s||!b.isXMLDoc(e),a&&(n=b.propFix[n]||n,o=b.propHooks[n]),r!==t?o&&"set"in o&&(i=o.set(e,r,n))!==t?i:e[n]=r:o&&"get"in o&&null!==(i=o.get(e,n))?i:e[n]},propHooks:{tabIndex:{get:function(e){var n=e.getAttributeNode("tabindex");return n&&n.specified?parseInt(n.value,10):V.test(e.nodeName)||Y.test(e.nodeName)&&e.href?0:t}}}}),z={get:function(e,n){var r=b.prop(e,n),i="boolean"==typeof r&&e.getAttribute(n),o="boolean"==typeof r?K&&Q?null!=i:G.test(n)?e[b.camelCase("default-"+n)]:!!i:e.getAttributeNode(n);return o&&o.value!==!1?n.toLowerCase():t},set:function(e,t,n){return t===!1?b.removeAttr(e,n):K&&Q||!G.test(n)?e.setAttribute(!Q&&b.propFix[n]||n,n):e[b.camelCase("default-"+n)]=e[n]=!0,n}},K&&Q||(b.attrHooks.value={get:function(e,n){var r=e.getAttributeNode(n);return b.nodeName(e,"input")?e.defaultValue:r&&r.specified?r.value:t},set:function(e,n,r){return b.nodeName(e,"input")?(e.defaultValue=n,t):I&&I.set(e,n,r)}}),Q||(I=b.valHooks.button={get:function(e,n){var r=e.getAttributeNode(n);return r&&("id"===n||"name"===n||"coords"===n?""!==r.value:r.specified)?r.value:t},set:function(e,n,r){var i=e.getAttributeNode(r);return i||e.setAttributeNode(i=e.ownerDocument.createAttribute(r)),i.value=n+="","value"===r||n===e.getAttribute(r)?n:t}},b.attrHooks.contenteditable={get:I.get,set:function(e,t,n){I.set(e,""===t?!1:t,n)}},b.each(["width","height"],function(e,n){b.attrHooks[n]=b.extend(b.attrHooks[n],{set:function(e,r){return""===r?(e.setAttribute(n,"auto"),r):t}})})),b.support.hrefNormalized||(b.each(["href","src","width","height"],function(e,n){b.attrHooks[n]=b.extend(b.attrHooks[n],{get:function(e){var r=e.getAttribute(n,2);return null==r?t:r}})}),b.each(["href","src"],function(e,t){b.propHooks[t]={get:function(e){return e.getAttribute(t,4)}}})),b.support.style||(b.attrHooks.style={get:function(e){return e.style.cssText||t},set:function(e,t){return e.style.cssText=t+""}}),b.support.optSelected||(b.propHooks.selected=b.extend(b.propHooks.selected,{get:function(e){var t=e.parentNode;return t&&(t.selectedIndex,t.parentNode&&t.parentNode.selectedIndex),null}})),b.support.enctype||(b.propFix.enctype="encoding"),b.support.checkOn||b.each(["radio","checkbox"],function(){b.valHooks[this]={get:function(e){return null===e.getAttribute("value")?"on":e.value}}}),b.each(["radio","checkbox"],function(){b.valHooks[this]=b.extend(b.valHooks[this],{set:function(e,n){return b.isArray(n)?e.checked=b.inArray(b(e).val(),n)>=0:t}})});var Z=/^(?:input|select|textarea)$/i,et=/^key/,tt=/^(?:mouse|contextmenu)|click/,nt=/^(?:focusinfocus|focusoutblur)$/,rt=/^([^.]*)(?:\.(.+)|)$/;function it(){return!0}function ot(){return!1}b.event={global:{},add:function(e,n,r,o,a){var s,u,l,c,p,f,d,h,g,m,y,v=b._data(e);if(v){r.handler&&(c=r,r=c.handler,a=c.selector),r.guid||(r.guid=b.guid++),(u=v.events)||(u=v.events={}),(f=v.handle)||(f=v.handle=function(e){return typeof b===i||e&&b.event.triggered===e.type?t:b.event.dispatch.apply(f.elem,arguments)},f.elem=e),n=(n||"").match(w)||[""],l=n.length;while(l--)s=rt.exec(n[l])||[],g=y=s[1],m=(s[2]||"").split(".").sort(),p=b.event.special[g]||{},g=(a?p.delegateType:p.bindType)||g,p=b.event.special[g]||{},d=b.extend({type:g,origType:y,data:o,handler:r,guid:r.guid,selector:a,needsContext:a&&b.expr.match.needsContext.test(a),namespace:m.join(".")},c),(h=u[g])||(h=u[g]=[],h.delegateCount=0,p.setup&&p.setup.call(e,o,m,f)!==!1||(e.addEventListener?e.addEventListener(g,f,!1):e.attachEvent&&e.attachEvent("on"+g,f))),p.add&&(p.add.call(e,d),d.handler.guid||(d.handler.guid=r.guid)),a?h.splice(h.delegateCount++,0,d):h.push(d),b.event.global[g]=!0;e=null}},remove:function(e,t,n,r,i){var o,a,s,u,l,c,p,f,d,h,g,m=b.hasData(e)&&b._data(e);if(m&&(c=m.events)){t=(t||"").match(w)||[""],l=t.length;while(l--)if(s=rt.exec(t[l])||[],d=g=s[1],h=(s[2]||"").split(".").sort(),d){p=b.event.special[d]||{},d=(r?p.delegateType:p.bindType)||d,f=c[d]||[],s=s[2]&&RegExp("(^|\\.)"+h.join("\\.(?:.*\\.|)")+"(\\.|$)"),u=o=f.length;while(o--)a=f[o],!i&&g!==a.origType||n&&n.guid!==a.guid||s&&!s.test(a.namespace)||r&&r!==a.selector&&("**"!==r||!a.selector)||(f.splice(o,1),a.selector&&f.delegateCount--,p.remove&&p.remove.call(e,a));u&&!f.length&&(p.teardown&&p.teardown.call(e,h,m.handle)!==!1||b.removeEvent(e,d,m.handle),delete c[d])}else for(d in c)b.event.remove(e,d+t[l],n,r,!0);b.isEmptyObject(c)&&(delete m.handle,b._removeData(e,"events"))}},trigger:function(n,r,i,a){var s,u,l,c,p,f,d,h=[i||o],g=y.call(n,"type")?n.type:n,m=y.call(n,"namespace")?n.namespace.split("."):[];if(l=f=i=i||o,3!==i.nodeType&&8!==i.nodeType&&!nt.test(g+b.event.triggered)&&(g.indexOf(".")>=0&&(m=g.split("."),g=m.shift(),m.sort()),u=0>g.indexOf(":")&&"on"+g,n=n[b.expando]?n:new b.Event(g,"object"==typeof n&&n),n.isTrigger=!0,n.namespace=m.join("."),n.namespace_re=n.namespace?RegExp("(^|\\.)"+m.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,n.result=t,n.target||(n.target=i),r=null==r?[n]:b.makeArray(r,[n]),p=b.event.special[g]||{},a||!p.trigger||p.trigger.apply(i,r)!==!1)){if(!a&&!p.noBubble&&!b.isWindow(i)){for(c=p.delegateType||g,nt.test(c+g)||(l=l.parentNode);l;l=l.parentNode)h.push(l),f=l;f===(i.ownerDocument||o)&&h.push(f.defaultView||f.parentWindow||e)}d=0;while((l=h[d++])&&!n.isPropagationStopped())n.type=d>1?c:p.bindType||g,s=(b._data(l,"events")||{})[n.type]&&b._data(l,"handle"),s&&s.apply(l,r),s=u&&l[u],s&&b.acceptData(l)&&s.apply&&s.apply(l,r)===!1&&n.preventDefault();if(n.type=g,!(a||n.isDefaultPrevented()||p._default&&p._default.apply(i.ownerDocument,r)!==!1||"click"===g&&b.nodeName(i,"a")||!b.acceptData(i)||!u||!i[g]||b.isWindow(i))){f=i[u],f&&(i[u]=null),b.event.triggered=g;try{i[g]()}catch(v){}b.event.triggered=t,f&&(i[u]=f)}return n.result}},dispatch:function(e){e=b.event.fix(e);var n,r,i,o,a,s=[],u=h.call(arguments),l=(b._data(this,"events")||{})[e.type]||[],c=b.event.special[e.type]||{};if(u[0]=e,e.delegateTarget=this,!c.preDispatch||c.preDispatch.call(this,e)!==!1){s=b.event.handlers.call(this,e,l),n=0;while((o=s[n++])&&!e.isPropagationStopped()){e.currentTarget=o.elem,a=0;while((i=o.handlers[a++])&&!e.isImmediatePropagationStopped())(!e.namespace_re||e.namespace_re.test(i.namespace))&&(e.handleObj=i,e.data=i.data,r=((b.event.special[i.origType]||{}).handle||i.handler).apply(o.elem,u),r!==t&&(e.result=r)===!1&&(e.preventDefault(),e.stopPropagation()))}return c.postDispatch&&c.postDispatch.call(this,e),e.result}},handlers:function(e,n){var r,i,o,a,s=[],u=n.delegateCount,l=e.target;if(u&&l.nodeType&&(!e.button||"click"!==e.type))for(;l!=this;l=l.parentNode||this)if(1===l.nodeType&&(l.disabled!==!0||"click"!==e.type)){for(o=[],a=0;u>a;a++)i=n[a],r=i.selector+" ",o[r]===t&&(o[r]=i.needsContext?b(r,this).index(l)>=0:b.find(r,this,null,[l]).length),o[r]&&o.push(i);o.length&&s.push({elem:l,handlers:o})}return n.length>u&&s.push({elem:this,handlers:n.slice(u)}),s},fix:function(e){if(e[b.expando])return e;var t,n,r,i=e.type,a=e,s=this.fixHooks[i];s||(this.fixHooks[i]=s=tt.test(i)?this.mouseHooks:et.test(i)?this.keyHooks:{}),r=s.props?this.props.concat(s.props):this.props,e=new b.Event(a),t=r.length;while(t--)n=r[t],e[n]=a[n];return e.target||(e.target=a.srcElement||o),3===e.target.nodeType&&(e.target=e.target.parentNode),e.metaKey=!!e.metaKey,s.filter?s.filter(e,a):e},props:"altKey bubbles cancelable ctrlKey currentTarget eventPhase metaKey relatedTarget shiftKey target timeStamp view which".split(" "),fixHooks:{},keyHooks:{props:"char charCode key keyCode".split(" "),filter:function(e,t){return null==e.which&&(e.which=null!=t.charCode?t.charCode:t.keyCode),e}},mouseHooks:{props:"button buttons clientX clientY fromElement offsetX offsetY pageX pageY screenX screenY toElement".split(" "),filter:function(e,n){var r,i,a,s=n.button,u=n.fromElement;return null==e.pageX&&null!=n.clientX&&(i=e.target.ownerDocument||o,a=i.documentElement,r=i.body,e.pageX=n.clientX+(a&&a.scrollLeft||r&&r.scrollLeft||0)-(a&&a.clientLeft||r&&r.clientLeft||0),e.pageY=n.clientY+(a&&a.scrollTop||r&&r.scrollTop||0)-(a&&a.clientTop||r&&r.clientTop||0)),!e.relatedTarget&&u&&(e.relatedTarget=u===e.target?n.toElement:u),e.which||s===t||(e.which=1&s?1:2&s?3:4&s?2:0),e}},special:{load:{noBubble:!0},click:{trigger:function(){return b.nodeName(this,"input")&&"checkbox"===this.type&&this.click?(this.click(),!1):t}},focus:{trigger:function(){if(this!==o.activeElement&&this.focus)try{return this.focus(),!1}catch(e){}},delegateType:"focusin"},blur:{trigger:function(){return this===o.activeElement&&this.blur?(this.blur(),!1):t},delegateType:"focusout"},beforeunload:{postDispatch:function(e){e.result!==t&&(e.originalEvent.returnValue=e.result)}}},simulate:function(e,t,n,r){var i=b.extend(new b.Event,n,{type:e,isSimulated:!0,originalEvent:{}});r?b.event.trigger(i,null,t):b.event.dispatch.call(t,i),i.isDefaultPrevented()&&n.preventDefault()}},b.removeEvent=o.removeEventListener?function(e,t,n){e.removeEventListener&&e.removeEventListener(t,n,!1)}:function(e,t,n){var r="on"+t;e.detachEvent&&(typeof e[r]===i&&(e[r]=null),e.detachEvent(r,n))},b.Event=function(e,n){return this instanceof b.Event?(e&&e.type?(this.originalEvent=e,this.type=e.type,this.isDefaultPrevented=e.defaultPrevented||e.returnValue===!1||e.getPreventDefault&&e.getPreventDefault()?it:ot):this.type=e,n&&b.extend(this,n),this.timeStamp=e&&e.timeStamp||b.now(),this[b.expando]=!0,t):new b.Event(e,n)},b.Event.prototype={isDefaultPrevented:ot,isPropagationStopped:ot,isImmediatePropagationStopped:ot,preventDefault:function(){var e=this.originalEvent;this.isDefaultPrevented=it,e&&(e.preventDefault?e.preventDefault():e.returnValue=!1)},stopPropagation:function(){var e=this.originalEvent;this.isPropagationStopped=it,e&&(e.stopPropagation&&e.stopPropagation(),e.cancelBubble=!0)},stopImmediatePropagation:function(){this.isImmediatePropagationStopped=it,this.stopPropagation()}},b.each({mouseenter:"mouseover",mouseleave:"mouseout"},function(e,t){b.event.special[e]={delegateType:t,bindType:t,handle:function(e){var n,r=this,i=e.relatedTarget,o=e.handleObj;
-return(!i||i!==r&&!b.contains(r,i))&&(e.type=o.origType,n=o.handler.apply(this,arguments),e.type=t),n}}}),b.support.submitBubbles||(b.event.special.submit={setup:function(){return b.nodeName(this,"form")?!1:(b.event.add(this,"click._submit keypress._submit",function(e){var n=e.target,r=b.nodeName(n,"input")||b.nodeName(n,"button")?n.form:t;r&&!b._data(r,"submitBubbles")&&(b.event.add(r,"submit._submit",function(e){e._submit_bubble=!0}),b._data(r,"submitBubbles",!0))}),t)},postDispatch:function(e){e._submit_bubble&&(delete e._submit_bubble,this.parentNode&&!e.isTrigger&&b.event.simulate("submit",this.parentNode,e,!0))},teardown:function(){return b.nodeName(this,"form")?!1:(b.event.remove(this,"._submit"),t)}}),b.support.changeBubbles||(b.event.special.change={setup:function(){return Z.test(this.nodeName)?(("checkbox"===this.type||"radio"===this.type)&&(b.event.add(this,"propertychange._change",function(e){"checked"===e.originalEvent.propertyName&&(this._just_changed=!0)}),b.event.add(this,"click._change",function(e){this._just_changed&&!e.isTrigger&&(this._just_changed=!1),b.event.simulate("change",this,e,!0)})),!1):(b.event.add(this,"beforeactivate._change",function(e){var t=e.target;Z.test(t.nodeName)&&!b._data(t,"changeBubbles")&&(b.event.add(t,"change._change",function(e){!this.parentNode||e.isSimulated||e.isTrigger||b.event.simulate("change",this.parentNode,e,!0)}),b._data(t,"changeBubbles",!0))}),t)},handle:function(e){var n=e.target;return this!==n||e.isSimulated||e.isTrigger||"radio"!==n.type&&"checkbox"!==n.type?e.handleObj.handler.apply(this,arguments):t},teardown:function(){return b.event.remove(this,"._change"),!Z.test(this.nodeName)}}),b.support.focusinBubbles||b.each({focus:"focusin",blur:"focusout"},function(e,t){var n=0,r=function(e){b.event.simulate(t,e.target,b.event.fix(e),!0)};b.event.special[t]={setup:function(){0===n++&&o.addEventListener(e,r,!0)},teardown:function(){0===--n&&o.removeEventListener(e,r,!0)}}}),b.fn.extend({on:function(e,n,r,i,o){var a,s;if("object"==typeof e){"string"!=typeof n&&(r=r||n,n=t);for(a in e)this.on(a,n,r,e[a],o);return this}if(null==r&&null==i?(i=n,r=n=t):null==i&&("string"==typeof n?(i=r,r=t):(i=r,r=n,n=t)),i===!1)i=ot;else if(!i)return this;return 1===o&&(s=i,i=function(e){return b().off(e),s.apply(this,arguments)},i.guid=s.guid||(s.guid=b.guid++)),this.each(function(){b.event.add(this,e,i,r,n)})},one:function(e,t,n,r){return this.on(e,t,n,r,1)},off:function(e,n,r){var i,o;if(e&&e.preventDefault&&e.handleObj)return i=e.handleObj,b(e.delegateTarget).off(i.namespace?i.origType+"."+i.namespace:i.origType,i.selector,i.handler),this;if("object"==typeof e){for(o in e)this.off(o,n,e[o]);return this}return(n===!1||"function"==typeof n)&&(r=n,n=t),r===!1&&(r=ot),this.each(function(){b.event.remove(this,e,r,n)})},bind:function(e,t,n){return this.on(e,null,t,n)},unbind:function(e,t){return this.off(e,null,t)},delegate:function(e,t,n,r){return this.on(t,e,n,r)},undelegate:function(e,t,n){return 1===arguments.length?this.off(e,"**"):this.off(t,e||"**",n)},trigger:function(e,t){return this.each(function(){b.event.trigger(e,t,this)})},triggerHandler:function(e,n){var r=this[0];return r?b.event.trigger(e,n,r,!0):t}}),function(e,t){var n,r,i,o,a,s,u,l,c,p,f,d,h,g,m,y,v,x="sizzle"+-new Date,w=e.document,T={},N=0,C=0,k=it(),E=it(),S=it(),A=typeof t,j=1<<31,D=[],L=D.pop,H=D.push,q=D.slice,M=D.indexOf||function(e){var t=0,n=this.length;for(;n>t;t++)if(this[t]===e)return t;return-1},_="[\\x20\\t\\r\\n\\f]",F="(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",O=F.replace("w","w#"),B="([*^$|!~]?=)",P="\\["+_+"*("+F+")"+_+"*(?:"+B+_+"*(?:(['\"])((?:\\\\.|[^\\\\])*?)\\3|("+O+")|)|)"+_+"*\\]",R=":("+F+")(?:\\(((['\"])((?:\\\\.|[^\\\\])*?)\\3|((?:\\\\.|[^\\\\()[\\]]|"+P.replace(3,8)+")*)|.*)\\)|)",W=RegExp("^"+_+"+|((?:^|[^\\\\])(?:\\\\.)*)"+_+"+$","g"),$=RegExp("^"+_+"*,"+_+"*"),I=RegExp("^"+_+"*([\\x20\\t\\r\\n\\f>+~])"+_+"*"),z=RegExp(R),X=RegExp("^"+O+"$"),U={ID:RegExp("^#("+F+")"),CLASS:RegExp("^\\.("+F+")"),NAME:RegExp("^\\[name=['\"]?("+F+")['\"]?\\]"),TAG:RegExp("^("+F.replace("w","w*")+")"),ATTR:RegExp("^"+P),PSEUDO:RegExp("^"+R),CHILD:RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+_+"*(even|odd|(([+-]|)(\\d*)n|)"+_+"*(?:([+-]|)"+_+"*(\\d+)|))"+_+"*\\)|)","i"),needsContext:RegExp("^"+_+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+_+"*((?:-\\d)?\\d*)"+_+"*\\)|)(?=[^-]|$)","i")},V=/[\x20\t\r\n\f]*[+~]/,Y=/^[^{]+\{\s*\[native code/,J=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,G=/^(?:input|select|textarea|button)$/i,Q=/^h\d$/i,K=/'|\\/g,Z=/\=[\x20\t\r\n\f]*([^'"\]]*)[\x20\t\r\n\f]*\]/g,et=/\\([\da-fA-F]{1,6}[\x20\t\r\n\f]?|.)/g,tt=function(e,t){var n="0x"+t-65536;return n!==n?t:0>n?String.fromCharCode(n+65536):String.fromCharCode(55296|n>>10,56320|1023&n)};try{q.call(w.documentElement.childNodes,0)[0].nodeType}catch(nt){q=function(e){var t,n=[];while(t=this[e++])n.push(t);return n}}function rt(e){return Y.test(e+"")}function it(){var e,t=[];return e=function(n,r){return t.push(n+=" ")>i.cacheLength&&delete e[t.shift()],e[n]=r}}function ot(e){return e[x]=!0,e}function at(e){var t=p.createElement("div");try{return e(t)}catch(n){return!1}finally{t=null}}function st(e,t,n,r){var i,o,a,s,u,l,f,g,m,v;if((t?t.ownerDocument||t:w)!==p&&c(t),t=t||p,n=n||[],!e||"string"!=typeof e)return n;if(1!==(s=t.nodeType)&&9!==s)return[];if(!d&&!r){if(i=J.exec(e))if(a=i[1]){if(9===s){if(o=t.getElementById(a),!o||!o.parentNode)return n;if(o.id===a)return n.push(o),n}else if(t.ownerDocument&&(o=t.ownerDocument.getElementById(a))&&y(t,o)&&o.id===a)return n.push(o),n}else{if(i[2])return H.apply(n,q.call(t.getElementsByTagName(e),0)),n;if((a=i[3])&&T.getByClassName&&t.getElementsByClassName)return H.apply(n,q.call(t.getElementsByClassName(a),0)),n}if(T.qsa&&!h.test(e)){if(f=!0,g=x,m=t,v=9===s&&e,1===s&&"object"!==t.nodeName.toLowerCase()){l=ft(e),(f=t.getAttribute("id"))?g=f.replace(K,"\\$&"):t.setAttribute("id",g),g="[id='"+g+"'] ",u=l.length;while(u--)l[u]=g+dt(l[u]);m=V.test(e)&&t.parentNode||t,v=l.join(",")}if(v)try{return H.apply(n,q.call(m.querySelectorAll(v),0)),n}catch(b){}finally{f||t.removeAttribute("id")}}}return wt(e.replace(W,"$1"),t,n,r)}a=st.isXML=function(e){var t=e&&(e.ownerDocument||e).documentElement;return t?"HTML"!==t.nodeName:!1},c=st.setDocument=function(e){var n=e?e.ownerDocument||e:w;return n!==p&&9===n.nodeType&&n.documentElement?(p=n,f=n.documentElement,d=a(n),T.tagNameNoComments=at(function(e){return e.appendChild(n.createComment("")),!e.getElementsByTagName("*").length}),T.attributes=at(function(e){e.innerHTML="<select></select>";var t=typeof e.lastChild.getAttribute("multiple");return"boolean"!==t&&"string"!==t}),T.getByClassName=at(function(e){return e.innerHTML="<div class='hidden e'></div><div class='hidden'></div>",e.getElementsByClassName&&e.getElementsByClassName("e").length?(e.lastChild.className="e",2===e.getElementsByClassName("e").length):!1}),T.getByName=at(function(e){e.id=x+0,e.innerHTML="<a name='"+x+"'></a><div name='"+x+"'></div>",f.insertBefore(e,f.firstChild);var t=n.getElementsByName&&n.getElementsByName(x).length===2+n.getElementsByName(x+0).length;return T.getIdNotName=!n.getElementById(x),f.removeChild(e),t}),i.attrHandle=at(function(e){return e.innerHTML="<a href='#'></a>",e.firstChild&&typeof e.firstChild.getAttribute!==A&&"#"===e.firstChild.getAttribute("href")})?{}:{href:function(e){return e.getAttribute("href",2)},type:function(e){return e.getAttribute("type")}},T.getIdNotName?(i.find.ID=function(e,t){if(typeof t.getElementById!==A&&!d){var n=t.getElementById(e);return n&&n.parentNode?[n]:[]}},i.filter.ID=function(e){var t=e.replace(et,tt);return function(e){return e.getAttribute("id")===t}}):(i.find.ID=function(e,n){if(typeof n.getElementById!==A&&!d){var r=n.getElementById(e);return r?r.id===e||typeof r.getAttributeNode!==A&&r.getAttributeNode("id").value===e?[r]:t:[]}},i.filter.ID=function(e){var t=e.replace(et,tt);return function(e){var n=typeof e.getAttributeNode!==A&&e.getAttributeNode("id");return n&&n.value===t}}),i.find.TAG=T.tagNameNoComments?function(e,n){return typeof n.getElementsByTagName!==A?n.getElementsByTagName(e):t}:function(e,t){var n,r=[],i=0,o=t.getElementsByTagName(e);if("*"===e){while(n=o[i++])1===n.nodeType&&r.push(n);return r}return o},i.find.NAME=T.getByName&&function(e,n){return typeof n.getElementsByName!==A?n.getElementsByName(name):t},i.find.CLASS=T.getByClassName&&function(e,n){return typeof n.getElementsByClassName===A||d?t:n.getElementsByClassName(e)},g=[],h=[":focus"],(T.qsa=rt(n.querySelectorAll))&&(at(function(e){e.innerHTML="<select><option selected=''></option></select>",e.querySelectorAll("[selected]").length||h.push("\\["+_+"*(?:checked|disabled|ismap|multiple|readonly|selected|value)"),e.querySelectorAll(":checked").length||h.push(":checked")}),at(function(e){e.innerHTML="<input type='hidden' i=''/>",e.querySelectorAll("[i^='']").length&&h.push("[*^$]="+_+"*(?:\"\"|'')"),e.querySelectorAll(":enabled").length||h.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),h.push(",.*:")})),(T.matchesSelector=rt(m=f.matchesSelector||f.mozMatchesSelector||f.webkitMatchesSelector||f.oMatchesSelector||f.msMatchesSelector))&&at(function(e){T.disconnectedMatch=m.call(e,"div"),m.call(e,"[s!='']:x"),g.push("!=",R)}),h=RegExp(h.join("|")),g=RegExp(g.join("|")),y=rt(f.contains)||f.compareDocumentPosition?function(e,t){var n=9===e.nodeType?e.documentElement:e,r=t&&t.parentNode;return e===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):e.compareDocumentPosition&&16&e.compareDocumentPosition(r)))}:function(e,t){if(t)while(t=t.parentNode)if(t===e)return!0;return!1},v=f.compareDocumentPosition?function(e,t){var r;return e===t?(u=!0,0):(r=t.compareDocumentPosition&&e.compareDocumentPosition&&e.compareDocumentPosition(t))?1&r||e.parentNode&&11===e.parentNode.nodeType?e===n||y(w,e)?-1:t===n||y(w,t)?1:0:4&r?-1:1:e.compareDocumentPosition?-1:1}:function(e,t){var r,i=0,o=e.parentNode,a=t.parentNode,s=[e],l=[t];if(e===t)return u=!0,0;if(!o||!a)return e===n?-1:t===n?1:o?-1:a?1:0;if(o===a)return ut(e,t);r=e;while(r=r.parentNode)s.unshift(r);r=t;while(r=r.parentNode)l.unshift(r);while(s[i]===l[i])i++;return i?ut(s[i],l[i]):s[i]===w?-1:l[i]===w?1:0},u=!1,[0,0].sort(v),T.detectDuplicates=u,p):p},st.matches=function(e,t){return st(e,null,null,t)},st.matchesSelector=function(e,t){if((e.ownerDocument||e)!==p&&c(e),t=t.replace(Z,"='$1']"),!(!T.matchesSelector||d||g&&g.test(t)||h.test(t)))try{var n=m.call(e,t);if(n||T.disconnectedMatch||e.document&&11!==e.document.nodeType)return n}catch(r){}return st(t,p,null,[e]).length>0},st.contains=function(e,t){return(e.ownerDocument||e)!==p&&c(e),y(e,t)},st.attr=function(e,t){var n;return(e.ownerDocument||e)!==p&&c(e),d||(t=t.toLowerCase()),(n=i.attrHandle[t])?n(e):d||T.attributes?e.getAttribute(t):((n=e.getAttributeNode(t))||e.getAttribute(t))&&e[t]===!0?t:n&&n.specified?n.value:null},st.error=function(e){throw Error("Syntax error, unrecognized expression: "+e)},st.uniqueSort=function(e){var t,n=[],r=1,i=0;if(u=!T.detectDuplicates,e.sort(v),u){for(;t=e[r];r++)t===e[r-1]&&(i=n.push(r));while(i--)e.splice(n[i],1)}return e};function ut(e,t){var n=t&&e,r=n&&(~t.sourceIndex||j)-(~e.sourceIndex||j);if(r)return r;if(n)while(n=n.nextSibling)if(n===t)return-1;return e?1:-1}function lt(e){return function(t){var n=t.nodeName.toLowerCase();return"input"===n&&t.type===e}}function ct(e){return function(t){var n=t.nodeName.toLowerCase();return("input"===n||"button"===n)&&t.type===e}}function pt(e){return ot(function(t){return t=+t,ot(function(n,r){var i,o=e([],n.length,t),a=o.length;while(a--)n[i=o[a]]&&(n[i]=!(r[i]=n[i]))})})}o=st.getText=function(e){var t,n="",r=0,i=e.nodeType;if(i){if(1===i||9===i||11===i){if("string"==typeof e.textContent)return e.textContent;for(e=e.firstChild;e;e=e.nextSibling)n+=o(e)}else if(3===i||4===i)return e.nodeValue}else for(;t=e[r];r++)n+=o(t);return n},i=st.selectors={cacheLength:50,createPseudo:ot,match:U,find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(et,tt),e[3]=(e[4]||e[5]||"").replace(et,tt),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||st.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&st.error(e[0]),e},PSEUDO:function(e){var t,n=!e[5]&&e[2];return U.CHILD.test(e[0])?null:(e[4]?e[2]=e[4]:n&&z.test(n)&&(t=ft(n,!0))&&(t=n.indexOf(")",n.length-t)-n.length)&&(e[0]=e[0].slice(0,t),e[2]=n.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){return"*"===e?function(){return!0}:(e=e.replace(et,tt).toLowerCase(),function(t){return t.nodeName&&t.nodeName.toLowerCase()===e})},CLASS:function(e){var t=k[e+" "];return t||(t=RegExp("(^|"+_+")"+e+"("+_+"|$)"))&&k(e,function(e){return t.test(e.className||typeof e.getAttribute!==A&&e.getAttribute("class")||"")})},ATTR:function(e,t,n){return function(r){var i=st.attr(r,e);return null==i?"!="===t:t?(i+="","="===t?i===n:"!="===t?i!==n:"^="===t?n&&0===i.indexOf(n):"*="===t?n&&i.indexOf(n)>-1:"$="===t?n&&i.slice(-n.length)===n:"~="===t?(" "+i+" ").indexOf(n)>-1:"|="===t?i===n||i.slice(0,n.length+1)===n+"-":!1):!0}},CHILD:function(e,t,n,r,i){var o="nth"!==e.slice(0,3),a="last"!==e.slice(-4),s="of-type"===t;return 1===r&&0===i?function(e){return!!e.parentNode}:function(t,n,u){var l,c,p,f,d,h,g=o!==a?"nextSibling":"previousSibling",m=t.parentNode,y=s&&t.nodeName.toLowerCase(),v=!u&&!s;if(m){if(o){while(g){p=t;while(p=p[g])if(s?p.nodeName.toLowerCase()===y:1===p.nodeType)return!1;h=g="only"===e&&!h&&"nextSibling"}return!0}if(h=[a?m.firstChild:m.lastChild],a&&v){c=m[x]||(m[x]={}),l=c[e]||[],d=l[0]===N&&l[1],f=l[0]===N&&l[2],p=d&&m.childNodes[d];while(p=++d&&p&&p[g]||(f=d=0)||h.pop())if(1===p.nodeType&&++f&&p===t){c[e]=[N,d,f];break}}else if(v&&(l=(t[x]||(t[x]={}))[e])&&l[0]===N)f=l[1];else while(p=++d&&p&&p[g]||(f=d=0)||h.pop())if((s?p.nodeName.toLowerCase()===y:1===p.nodeType)&&++f&&(v&&((p[x]||(p[x]={}))[e]=[N,f]),p===t))break;return f-=i,f===r||0===f%r&&f/r>=0}}},PSEUDO:function(e,t){var n,r=i.pseudos[e]||i.setFilters[e.toLowerCase()]||st.error("unsupported pseudo: "+e);return r[x]?r(t):r.length>1?(n=[e,e,"",t],i.setFilters.hasOwnProperty(e.toLowerCase())?ot(function(e,n){var i,o=r(e,t),a=o.length;while(a--)i=M.call(e,o[a]),e[i]=!(n[i]=o[a])}):function(e){return r(e,0,n)}):r}},pseudos:{not:ot(function(e){var t=[],n=[],r=s(e.replace(W,"$1"));return r[x]?ot(function(e,t,n,i){var o,a=r(e,null,i,[]),s=e.length;while(s--)(o=a[s])&&(e[s]=!(t[s]=o))}):function(e,i,o){return t[0]=e,r(t,null,o,n),!n.pop()}}),has:ot(function(e){return function(t){return st(e,t).length>0}}),contains:ot(function(e){return function(t){return(t.textContent||t.innerText||o(t)).indexOf(e)>-1}}),lang:ot(function(e){return X.test(e||"")||st.error("unsupported lang: "+e),e=e.replace(et,tt).toLowerCase(),function(t){var n;do if(n=d?t.getAttribute("xml:lang")||t.getAttribute("lang"):t.lang)return n=n.toLowerCase(),n===e||0===n.indexOf(e+"-");while((t=t.parentNode)&&1===t.nodeType);return!1}}),target:function(t){var n=e.location&&e.location.hash;return n&&n.slice(1)===t.id},root:function(e){return e===f},focus:function(e){return e===p.activeElement&&(!p.hasFocus||p.hasFocus())&&!!(e.type||e.href||~e.tabIndex)},enabled:function(e){return e.disabled===!1},disabled:function(e){return e.disabled===!0},checked:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&!!e.checked||"option"===t&&!!e.selected},selected:function(e){return e.parentNode&&e.parentNode.selectedIndex,e.selected===!0},empty:function(e){for(e=e.firstChild;e;e=e.nextSibling)if(e.nodeName>"@"||3===e.nodeType||4===e.nodeType)return!1;return!0},parent:function(e){return!i.pseudos.empty(e)},header:function(e){return Q.test(e.nodeName)},input:function(e){return G.test(e.nodeName)},button:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&"button"===e.type||"button"===t},text:function(e){var t;return"input"===e.nodeName.toLowerCase()&&"text"===e.type&&(null==(t=e.getAttribute("type"))||t.toLowerCase()===e.type)},first:pt(function(){return[0]}),last:pt(function(e,t){return[t-1]}),eq:pt(function(e,t,n){return[0>n?n+t:n]}),even:pt(function(e,t){var n=0;for(;t>n;n+=2)e.push(n);return e}),odd:pt(function(e,t){var n=1;for(;t>n;n+=2)e.push(n);return e}),lt:pt(function(e,t,n){var r=0>n?n+t:n;for(;--r>=0;)e.push(r);return e}),gt:pt(function(e,t,n){var r=0>n?n+t:n;for(;t>++r;)e.push(r);return e})}};for(n in{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})i.pseudos[n]=lt(n);for(n in{submit:!0,reset:!0})i.pseudos[n]=ct(n);function ft(e,t){var n,r,o,a,s,u,l,c=E[e+" "];if(c)return t?0:c.slice(0);s=e,u=[],l=i.preFilter;while(s){(!n||(r=$.exec(s)))&&(r&&(s=s.slice(r[0].length)||s),u.push(o=[])),n=!1,(r=I.exec(s))&&(n=r.shift(),o.push({value:n,type:r[0].replace(W," ")}),s=s.slice(n.length));for(a in i.filter)!(r=U[a].exec(s))||l[a]&&!(r=l[a](r))||(n=r.shift(),o.push({value:n,type:a,matches:r}),s=s.slice(n.length));if(!n)break}return t?s.length:s?st.error(e):E(e,u).slice(0)}function dt(e){var t=0,n=e.length,r="";for(;n>t;t++)r+=e[t].value;return r}function ht(e,t,n){var i=t.dir,o=n&&"parentNode"===i,a=C++;return t.first?function(t,n,r){while(t=t[i])if(1===t.nodeType||o)return e(t,n,r)}:function(t,n,s){var u,l,c,p=N+" "+a;if(s){while(t=t[i])if((1===t.nodeType||o)&&e(t,n,s))return!0}else while(t=t[i])if(1===t.nodeType||o)if(c=t[x]||(t[x]={}),(l=c[i])&&l[0]===p){if((u=l[1])===!0||u===r)return u===!0}else if(l=c[i]=[p],l[1]=e(t,n,s)||r,l[1]===!0)return!0}}function gt(e){return e.length>1?function(t,n,r){var i=e.length;while(i--)if(!e[i](t,n,r))return!1;return!0}:e[0]}function mt(e,t,n,r,i){var o,a=[],s=0,u=e.length,l=null!=t;for(;u>s;s++)(o=e[s])&&(!n||n(o,r,i))&&(a.push(o),l&&t.push(s));return a}function yt(e,t,n,r,i,o){return r&&!r[x]&&(r=yt(r)),i&&!i[x]&&(i=yt(i,o)),ot(function(o,a,s,u){var l,c,p,f=[],d=[],h=a.length,g=o||xt(t||"*",s.nodeType?[s]:s,[]),m=!e||!o&&t?g:mt(g,f,e,s,u),y=n?i||(o?e:h||r)?[]:a:m;if(n&&n(m,y,s,u),r){l=mt(y,d),r(l,[],s,u),c=l.length;while(c--)(p=l[c])&&(y[d[c]]=!(m[d[c]]=p))}if(o){if(i||e){if(i){l=[],c=y.length;while(c--)(p=y[c])&&l.push(m[c]=p);i(null,y=[],l,u)}c=y.length;while(c--)(p=y[c])&&(l=i?M.call(o,p):f[c])>-1&&(o[l]=!(a[l]=p))}}else y=mt(y===a?y.splice(h,y.length):y),i?i(null,a,y,u):H.apply(a,y)})}function vt(e){var t,n,r,o=e.length,a=i.relative[e[0].type],s=a||i.relative[" "],u=a?1:0,c=ht(function(e){return e===t},s,!0),p=ht(function(e){return M.call(t,e)>-1},s,!0),f=[function(e,n,r){return!a&&(r||n!==l)||((t=n).nodeType?c(e,n,r):p(e,n,r))}];for(;o>u;u++)if(n=i.relative[e[u].type])f=[ht(gt(f),n)];else{if(n=i.filter[e[u].type].apply(null,e[u].matches),n[x]){for(r=++u;o>r;r++)if(i.relative[e[r].type])break;return yt(u>1&&gt(f),u>1&&dt(e.slice(0,u-1)).replace(W,"$1"),n,r>u&&vt(e.slice(u,r)),o>r&&vt(e=e.slice(r)),o>r&&dt(e))}f.push(n)}return gt(f)}function bt(e,t){var n=0,o=t.length>0,a=e.length>0,s=function(s,u,c,f,d){var h,g,m,y=[],v=0,b="0",x=s&&[],w=null!=d,T=l,C=s||a&&i.find.TAG("*",d&&u.parentNode||u),k=N+=null==T?1:Math.random()||.1;for(w&&(l=u!==p&&u,r=n);null!=(h=C[b]);b++){if(a&&h){g=0;while(m=e[g++])if(m(h,u,c)){f.push(h);break}w&&(N=k,r=++n)}o&&((h=!m&&h)&&v--,s&&x.push(h))}if(v+=b,o&&b!==v){g=0;while(m=t[g++])m(x,y,u,c);if(s){if(v>0)while(b--)x[b]||y[b]||(y[b]=L.call(f));y=mt(y)}H.apply(f,y),w&&!s&&y.length>0&&v+t.length>1&&st.uniqueSort(f)}return w&&(N=k,l=T),x};return o?ot(s):s}s=st.compile=function(e,t){var n,r=[],i=[],o=S[e+" "];if(!o){t||(t=ft(e)),n=t.length;while(n--)o=vt(t[n]),o[x]?r.push(o):i.push(o);o=S(e,bt(i,r))}return o};function xt(e,t,n){var r=0,i=t.length;for(;i>r;r++)st(e,t[r],n);return n}function wt(e,t,n,r){var o,a,u,l,c,p=ft(e);if(!r&&1===p.length){if(a=p[0]=p[0].slice(0),a.length>2&&"ID"===(u=a[0]).type&&9===t.nodeType&&!d&&i.relative[a[1].type]){if(t=i.find.ID(u.matches[0].replace(et,tt),t)[0],!t)return n;e=e.slice(a.shift().value.length)}o=U.needsContext.test(e)?0:a.length;while(o--){if(u=a[o],i.relative[l=u.type])break;if((c=i.find[l])&&(r=c(u.matches[0].replace(et,tt),V.test(a[0].type)&&t.parentNode||t))){if(a.splice(o,1),e=r.length&&dt(a),!e)return H.apply(n,q.call(r,0)),n;break}}}return s(e,p)(r,t,d,n,V.test(e)),n}i.pseudos.nth=i.pseudos.eq;function Tt(){}i.filters=Tt.prototype=i.pseudos,i.setFilters=new Tt,c(),st.attr=b.attr,b.find=st,b.expr=st.selectors,b.expr[":"]=b.expr.pseudos,b.unique=st.uniqueSort,b.text=st.getText,b.isXMLDoc=st.isXML,b.contains=st.contains}(e);var at=/Until$/,st=/^(?:parents|prev(?:Until|All))/,ut=/^.[^:#\[\.,]*$/,lt=b.expr.match.needsContext,ct={children:!0,contents:!0,next:!0,prev:!0};b.fn.extend({find:function(e){var t,n,r,i=this.length;if("string"!=typeof e)return r=this,this.pushStack(b(e).filter(function(){for(t=0;i>t;t++)if(b.contains(r[t],this))return!0}));for(n=[],t=0;i>t;t++)b.find(e,this[t],n);return n=this.pushStack(i>1?b.unique(n):n),n.selector=(this.selector?this.selector+" ":"")+e,n},has:function(e){var t,n=b(e,this),r=n.length;return this.filter(function(){for(t=0;r>t;t++)if(b.contains(this,n[t]))return!0})},not:function(e){return this.pushStack(ft(this,e,!1))},filter:function(e){return this.pushStack(ft(this,e,!0))},is:function(e){return!!e&&("string"==typeof e?lt.test(e)?b(e,this.context).index(this[0])>=0:b.filter(e,this).length>0:this.filter(e).length>0)},closest:function(e,t){var n,r=0,i=this.length,o=[],a=lt.test(e)||"string"!=typeof e?b(e,t||this.context):0;for(;i>r;r++){n=this[r];while(n&&n.ownerDocument&&n!==t&&11!==n.nodeType){if(a?a.index(n)>-1:b.find.matchesSelector(n,e)){o.push(n);break}n=n.parentNode}}return this.pushStack(o.length>1?b.unique(o):o)},index:function(e){return e?"string"==typeof e?b.inArray(this[0],b(e)):b.inArray(e.jquery?e[0]:e,this):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(e,t){var n="string"==typeof e?b(e,t):b.makeArray(e&&e.nodeType?[e]:e),r=b.merge(this.get(),n);return this.pushStack(b.unique(r))},addBack:function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}}),b.fn.andSelf=b.fn.addBack;function pt(e,t){do e=e[t];while(e&&1!==e.nodeType);return e}b.each({parent:function(e){var t=e.parentNode;return t&&11!==t.nodeType?t:null},parents:function(e){return b.dir(e,"parentNode")},parentsUntil:function(e,t,n){return b.dir(e,"parentNode",n)},next:function(e){return pt(e,"nextSibling")},prev:function(e){return pt(e,"previousSibling")},nextAll:function(e){return b.dir(e,"nextSibling")},prevAll:function(e){return b.dir(e,"previousSibling")},nextUntil:function(e,t,n){return b.dir(e,"nextSibling",n)},prevUntil:function(e,t,n){return b.dir(e,"previousSibling",n)},siblings:function(e){return b.sibling((e.parentNode||{}).firstChild,e)},children:function(e){return b.sibling(e.firstChild)},contents:function(e){return b.nodeName(e,"iframe")?e.contentDocument||e.contentWindow.document:b.merge([],e.childNodes)}},function(e,t){b.fn[e]=function(n,r){var i=b.map(this,t,n);return at.test(e)||(r=n),r&&"string"==typeof r&&(i=b.filter(r,i)),i=this.length>1&&!ct[e]?b.unique(i):i,this.length>1&&st.test(e)&&(i=i.reverse()),this.pushStack(i)}}),b.extend({filter:function(e,t,n){return n&&(e=":not("+e+")"),1===t.length?b.find.matchesSelector(t[0],e)?[t[0]]:[]:b.find.matches(e,t)},dir:function(e,n,r){var i=[],o=e[n];while(o&&9!==o.nodeType&&(r===t||1!==o.nodeType||!b(o).is(r)))1===o.nodeType&&i.push(o),o=o[n];return i},sibling:function(e,t){var n=[];for(;e;e=e.nextSibling)1===e.nodeType&&e!==t&&n.push(e);return n}});function ft(e,t,n){if(t=t||0,b.isFunction(t))return b.grep(e,function(e,r){var i=!!t.call(e,r,e);return i===n});if(t.nodeType)return b.grep(e,function(e){return e===t===n});if("string"==typeof t){var r=b.grep(e,function(e){return 1===e.nodeType});if(ut.test(t))return b.filter(t,r,!n);t=b.filter(t,r)}return b.grep(e,function(e){return b.inArray(e,t)>=0===n})}function dt(e){var t=ht.split("|"),n=e.createDocumentFragment();if(n.createElement)while(t.length)n.createElement(t.pop());return n}var ht="abbr|article|aside|audio|bdi|canvas|data|datalist|details|figcaption|figure|footer|header|hgroup|mark|meter|nav|output|progress|section|summary|time|video",gt=/ jQuery\d+="(?:null|\d+)"/g,mt=RegExp("<(?:"+ht+")[\\s/>]","i"),yt=/^\s+/,vt=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/gi,bt=/<([\w:]+)/,xt=/<tbody/i,wt=/<|&#?\w+;/,Tt=/<(?:script|style|link)/i,Nt=/^(?:checkbox|radio)$/i,Ct=/checked\s*(?:[^=]|=\s*.checked.)/i,kt=/^$|\/(?:java|ecma)script/i,Et=/^true\/(.*)/,St=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g,At={option:[1,"<select multiple='multiple'>","</select>"],legend:[1,"<fieldset>","</fieldset>"],area:[1,"<map>","</map>"],param:[1,"<object>","</object>"],thead:[1,"<table>","</table>"],tr:[2,"<table><tbody>","</tbody></table>"],col:[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:b.support.htmlSerialize?[0,"",""]:[1,"X<div>","</div>"]},jt=dt(o),Dt=jt.appendChild(o.createElement("div"));At.optgroup=At.option,At.tbody=At.tfoot=At.colgroup=At.caption=At.thead,At.th=At.td,b.fn.extend({text:function(e){return b.access(this,function(e){return e===t?b.text(this):this.empty().append((this[0]&&this[0].ownerDocument||o).createTextNode(e))},null,e,arguments.length)},wrapAll:function(e){if(b.isFunction(e))return this.each(function(t){b(this).wrapAll(e.call(this,t))});if(this[0]){var t=b(e,this[0].ownerDocument).eq(0).clone(!0);this[0].parentNode&&t.insertBefore(this[0]),t.map(function(){var e=this;while(e.firstChild&&1===e.firstChild.nodeType)e=e.firstChild;return e}).append(this)}return this},wrapInner:function(e){return b.isFunction(e)?this.each(function(t){b(this).wrapInner(e.call(this,t))}):this.each(function(){var t=b(this),n=t.contents();n.length?n.wrapAll(e):t.append(e)})},wrap:function(e){var t=b.isFunction(e);return this.each(function(n){b(this).wrapAll(t?e.call(this,n):e)})},unwrap:function(){return this.parent().each(function(){b.nodeName(this,"body")||b(this).replaceWith(this.childNodes)}).end()},append:function(){return this.domManip(arguments,!0,function(e){(1===this.nodeType||11===this.nodeType||9===this.nodeType)&&this.appendChild(e)})},prepend:function(){return this.domManip(arguments,!0,function(e){(1===this.nodeType||11===this.nodeType||9===this.nodeType)&&this.insertBefore(e,this.firstChild)})},before:function(){return this.domManip(arguments,!1,function(e){this.parentNode&&this.parentNode.insertBefore(e,this)})},after:function(){return this.domManip(arguments,!1,function(e){this.parentNode&&this.parentNode.insertBefore(e,this.nextSibling)})},remove:function(e,t){var n,r=0;for(;null!=(n=this[r]);r++)(!e||b.filter(e,[n]).length>0)&&(t||1!==n.nodeType||b.cleanData(Ot(n)),n.parentNode&&(t&&b.contains(n.ownerDocument,n)&&Mt(Ot(n,"script")),n.parentNode.removeChild(n)));return this},empty:function(){var e,t=0;for(;null!=(e=this[t]);t++){1===e.nodeType&&b.cleanData(Ot(e,!1));while(e.firstChild)e.removeChild(e.firstChild);e.options&&b.nodeName(e,"select")&&(e.options.length=0)}return this},clone:function(e,t){return e=null==e?!1:e,t=null==t?e:t,this.map(function(){return b.clone(this,e,t)})},html:function(e){return b.access(this,function(e){var n=this[0]||{},r=0,i=this.length;if(e===t)return 1===n.nodeType?n.innerHTML.replace(gt,""):t;if(!("string"!=typeof e||Tt.test(e)||!b.support.htmlSerialize&&mt.test(e)||!b.support.leadingWhitespace&&yt.test(e)||At[(bt.exec(e)||["",""])[1].toLowerCase()])){e=e.replace(vt,"<$1></$2>");try{for(;i>r;r++)n=this[r]||{},1===n.nodeType&&(b.cleanData(Ot(n,!1)),n.innerHTML=e);n=0}catch(o){}}n&&this.empty().append(e)},null,e,arguments.length)},replaceWith:function(e){var t=b.isFunction(e);return t||"string"==typeof e||(e=b(e).not(this).detach()),this.domManip([e],!0,function(e){var t=this.nextSibling,n=this.parentNode;n&&(b(this).remove(),n.insertBefore(e,t))})},detach:function(e){return this.remove(e,!0)},domManip:function(e,n,r){e=f.apply([],e);var i,o,a,s,u,l,c=0,p=this.length,d=this,h=p-1,g=e[0],m=b.isFunction(g);if(m||!(1>=p||"string"!=typeof g||b.support.checkClone)&&Ct.test(g))return this.each(function(i){var o=d.eq(i);m&&(e[0]=g.call(this,i,n?o.html():t)),o.domManip(e,n,r)});if(p&&(l=b.buildFragment(e,this[0].ownerDocument,!1,this),i=l.firstChild,1===l.childNodes.length&&(l=i),i)){for(n=n&&b.nodeName(i,"tr"),s=b.map(Ot(l,"script"),Ht),a=s.length;p>c;c++)o=l,c!==h&&(o=b.clone(o,!0,!0),a&&b.merge(s,Ot(o,"script"))),r.call(n&&b.nodeName(this[c],"table")?Lt(this[c],"tbody"):this[c],o,c);if(a)for(u=s[s.length-1].ownerDocument,b.map(s,qt),c=0;a>c;c++)o=s[c],kt.test(o.type||"")&&!b._data(o,"globalEval")&&b.contains(u,o)&&(o.src?b.ajax({url:o.src,type:"GET",dataType:"script",async:!1,global:!1,"throws":!0}):b.globalEval((o.text||o.textContent||o.innerHTML||"").replace(St,"")));l=i=null}return this}});function Lt(e,t){return e.getElementsByTagName(t)[0]||e.appendChild(e.ownerDocument.createElement(t))}function Ht(e){var t=e.getAttributeNode("type");return e.type=(t&&t.specified)+"/"+e.type,e}function qt(e){var t=Et.exec(e.type);return t?e.type=t[1]:e.removeAttribute("type"),e}function Mt(e,t){var n,r=0;for(;null!=(n=e[r]);r++)b._data(n,"globalEval",!t||b._data(t[r],"globalEval"))}function _t(e,t){if(1===t.nodeType&&b.hasData(e)){var n,r,i,o=b._data(e),a=b._data(t,o),s=o.events;if(s){delete a.handle,a.events={};for(n in s)for(r=0,i=s[n].length;i>r;r++)b.event.add(t,n,s[n][r])}a.data&&(a.data=b.extend({},a.data))}}function Ft(e,t){var n,r,i;if(1===t.nodeType){if(n=t.nodeName.toLowerCase(),!b.support.noCloneEvent&&t[b.expando]){i=b._data(t);for(r in i.events)b.removeEvent(t,r,i.handle);t.removeAttribute(b.expando)}"script"===n&&t.text!==e.text?(Ht(t).text=e.text,qt(t)):"object"===n?(t.parentNode&&(t.outerHTML=e.outerHTML),b.support.html5Clone&&e.innerHTML&&!b.trim(t.innerHTML)&&(t.innerHTML=e.innerHTML)):"input"===n&&Nt.test(e.type)?(t.defaultChecked=t.checked=e.checked,t.value!==e.value&&(t.value=e.value)):"option"===n?t.defaultSelected=t.selected=e.defaultSelected:("input"===n||"textarea"===n)&&(t.defaultValue=e.defaultValue)}}b.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(e,t){b.fn[e]=function(e){var n,r=0,i=[],o=b(e),a=o.length-1;for(;a>=r;r++)n=r===a?this:this.clone(!0),b(o[r])[t](n),d.apply(i,n.get());return this.pushStack(i)}});function Ot(e,n){var r,o,a=0,s=typeof e.getElementsByTagName!==i?e.getElementsByTagName(n||"*"):typeof e.querySelectorAll!==i?e.querySelectorAll(n||"*"):t;if(!s)for(s=[],r=e.childNodes||e;null!=(o=r[a]);a++)!n||b.nodeName(o,n)?s.push(o):b.merge(s,Ot(o,n));return n===t||n&&b.nodeName(e,n)?b.merge([e],s):s}function Bt(e){Nt.test(e.type)&&(e.defaultChecked=e.checked)}b.extend({clone:function(e,t,n){var r,i,o,a,s,u=b.contains(e.ownerDocument,e);if(b.support.html5Clone||b.isXMLDoc(e)||!mt.test("<"+e.nodeName+">")?o=e.cloneNode(!0):(Dt.innerHTML=e.outerHTML,Dt.removeChild(o=Dt.firstChild)),!(b.support.noCloneEvent&&b.support.noCloneChecked||1!==e.nodeType&&11!==e.nodeType||b.isXMLDoc(e)))for(r=Ot(o),s=Ot(e),a=0;null!=(i=s[a]);++a)r[a]&&Ft(i,r[a]);if(t)if(n)for(s=s||Ot(e),r=r||Ot(o),a=0;null!=(i=s[a]);a++)_t(i,r[a]);else _t(e,o);return r=Ot(o,"script"),r.length>0&&Mt(r,!u&&Ot(e,"script")),r=s=i=null,o},buildFragment:function(e,t,n,r){var i,o,a,s,u,l,c,p=e.length,f=dt(t),d=[],h=0;for(;p>h;h++)if(o=e[h],o||0===o)if("object"===b.type(o))b.merge(d,o.nodeType?[o]:o);else if(wt.test(o)){s=s||f.appendChild(t.createElement("div")),u=(bt.exec(o)||["",""])[1].toLowerCase(),c=At[u]||At._default,s.innerHTML=c[1]+o.replace(vt,"<$1></$2>")+c[2],i=c[0];while(i--)s=s.lastChild;if(!b.support.leadingWhitespace&&yt.test(o)&&d.push(t.createTextNode(yt.exec(o)[0])),!b.support.tbody){o="table"!==u||xt.test(o)?"<table>"!==c[1]||xt.test(o)?0:s:s.firstChild,i=o&&o.childNodes.length;while(i--)b.nodeName(l=o.childNodes[i],"tbody")&&!l.childNodes.length&&o.removeChild(l)
-}b.merge(d,s.childNodes),s.textContent="";while(s.firstChild)s.removeChild(s.firstChild);s=f.lastChild}else d.push(t.createTextNode(o));s&&f.removeChild(s),b.support.appendChecked||b.grep(Ot(d,"input"),Bt),h=0;while(o=d[h++])if((!r||-1===b.inArray(o,r))&&(a=b.contains(o.ownerDocument,o),s=Ot(f.appendChild(o),"script"),a&&Mt(s),n)){i=0;while(o=s[i++])kt.test(o.type||"")&&n.push(o)}return s=null,f},cleanData:function(e,t){var n,r,o,a,s=0,u=b.expando,l=b.cache,p=b.support.deleteExpando,f=b.event.special;for(;null!=(n=e[s]);s++)if((t||b.acceptData(n))&&(o=n[u],a=o&&l[o])){if(a.events)for(r in a.events)f[r]?b.event.remove(n,r):b.removeEvent(n,r,a.handle);l[o]&&(delete l[o],p?delete n[u]:typeof n.removeAttribute!==i?n.removeAttribute(u):n[u]=null,c.push(o))}}});var Pt,Rt,Wt,$t=/alpha\([^)]*\)/i,It=/opacity\s*=\s*([^)]*)/,zt=/^(top|right|bottom|left)$/,Xt=/^(none|table(?!-c[ea]).+)/,Ut=/^margin/,Vt=RegExp("^("+x+")(.*)$","i"),Yt=RegExp("^("+x+")(?!px)[a-z%]+$","i"),Jt=RegExp("^([+-])=("+x+")","i"),Gt={BODY:"block"},Qt={position:"absolute",visibility:"hidden",display:"block"},Kt={letterSpacing:0,fontWeight:400},Zt=["Top","Right","Bottom","Left"],en=["Webkit","O","Moz","ms"];function tn(e,t){if(t in e)return t;var n=t.charAt(0).toUpperCase()+t.slice(1),r=t,i=en.length;while(i--)if(t=en[i]+n,t in e)return t;return r}function nn(e,t){return e=t||e,"none"===b.css(e,"display")||!b.contains(e.ownerDocument,e)}function rn(e,t){var n,r,i,o=[],a=0,s=e.length;for(;s>a;a++)r=e[a],r.style&&(o[a]=b._data(r,"olddisplay"),n=r.style.display,t?(o[a]||"none"!==n||(r.style.display=""),""===r.style.display&&nn(r)&&(o[a]=b._data(r,"olddisplay",un(r.nodeName)))):o[a]||(i=nn(r),(n&&"none"!==n||!i)&&b._data(r,"olddisplay",i?n:b.css(r,"display"))));for(a=0;s>a;a++)r=e[a],r.style&&(t&&"none"!==r.style.display&&""!==r.style.display||(r.style.display=t?o[a]||"":"none"));return e}b.fn.extend({css:function(e,n){return b.access(this,function(e,n,r){var i,o,a={},s=0;if(b.isArray(n)){for(o=Rt(e),i=n.length;i>s;s++)a[n[s]]=b.css(e,n[s],!1,o);return a}return r!==t?b.style(e,n,r):b.css(e,n)},e,n,arguments.length>1)},show:function(){return rn(this,!0)},hide:function(){return rn(this)},toggle:function(e){var t="boolean"==typeof e;return this.each(function(){(t?e:nn(this))?b(this).show():b(this).hide()})}}),b.extend({cssHooks:{opacity:{get:function(e,t){if(t){var n=Wt(e,"opacity");return""===n?"1":n}}}},cssNumber:{columnCount:!0,fillOpacity:!0,fontWeight:!0,lineHeight:!0,opacity:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{"float":b.support.cssFloat?"cssFloat":"styleFloat"},style:function(e,n,r,i){if(e&&3!==e.nodeType&&8!==e.nodeType&&e.style){var o,a,s,u=b.camelCase(n),l=e.style;if(n=b.cssProps[u]||(b.cssProps[u]=tn(l,u)),s=b.cssHooks[n]||b.cssHooks[u],r===t)return s&&"get"in s&&(o=s.get(e,!1,i))!==t?o:l[n];if(a=typeof r,"string"===a&&(o=Jt.exec(r))&&(r=(o[1]+1)*o[2]+parseFloat(b.css(e,n)),a="number"),!(null==r||"number"===a&&isNaN(r)||("number"!==a||b.cssNumber[u]||(r+="px"),b.support.clearCloneStyle||""!==r||0!==n.indexOf("background")||(l[n]="inherit"),s&&"set"in s&&(r=s.set(e,r,i))===t)))try{l[n]=r}catch(c){}}},css:function(e,n,r,i){var o,a,s,u=b.camelCase(n);return n=b.cssProps[u]||(b.cssProps[u]=tn(e.style,u)),s=b.cssHooks[n]||b.cssHooks[u],s&&"get"in s&&(a=s.get(e,!0,r)),a===t&&(a=Wt(e,n,i)),"normal"===a&&n in Kt&&(a=Kt[n]),""===r||r?(o=parseFloat(a),r===!0||b.isNumeric(o)?o||0:a):a},swap:function(e,t,n,r){var i,o,a={};for(o in t)a[o]=e.style[o],e.style[o]=t[o];i=n.apply(e,r||[]);for(o in t)e.style[o]=a[o];return i}}),e.getComputedStyle?(Rt=function(t){return e.getComputedStyle(t,null)},Wt=function(e,n,r){var i,o,a,s=r||Rt(e),u=s?s.getPropertyValue(n)||s[n]:t,l=e.style;return s&&(""!==u||b.contains(e.ownerDocument,e)||(u=b.style(e,n)),Yt.test(u)&&Ut.test(n)&&(i=l.width,o=l.minWidth,a=l.maxWidth,l.minWidth=l.maxWidth=l.width=u,u=s.width,l.width=i,l.minWidth=o,l.maxWidth=a)),u}):o.documentElement.currentStyle&&(Rt=function(e){return e.currentStyle},Wt=function(e,n,r){var i,o,a,s=r||Rt(e),u=s?s[n]:t,l=e.style;return null==u&&l&&l[n]&&(u=l[n]),Yt.test(u)&&!zt.test(n)&&(i=l.left,o=e.runtimeStyle,a=o&&o.left,a&&(o.left=e.currentStyle.left),l.left="fontSize"===n?"1em":u,u=l.pixelLeft+"px",l.left=i,a&&(o.left=a)),""===u?"auto":u});function on(e,t,n){var r=Vt.exec(t);return r?Math.max(0,r[1]-(n||0))+(r[2]||"px"):t}function an(e,t,n,r,i){var o=n===(r?"border":"content")?4:"width"===t?1:0,a=0;for(;4>o;o+=2)"margin"===n&&(a+=b.css(e,n+Zt[o],!0,i)),r?("content"===n&&(a-=b.css(e,"padding"+Zt[o],!0,i)),"margin"!==n&&(a-=b.css(e,"border"+Zt[o]+"Width",!0,i))):(a+=b.css(e,"padding"+Zt[o],!0,i),"padding"!==n&&(a+=b.css(e,"border"+Zt[o]+"Width",!0,i)));return a}function sn(e,t,n){var r=!0,i="width"===t?e.offsetWidth:e.offsetHeight,o=Rt(e),a=b.support.boxSizing&&"border-box"===b.css(e,"boxSizing",!1,o);if(0>=i||null==i){if(i=Wt(e,t,o),(0>i||null==i)&&(i=e.style[t]),Yt.test(i))return i;r=a&&(b.support.boxSizingReliable||i===e.style[t]),i=parseFloat(i)||0}return i+an(e,t,n||(a?"border":"content"),r,o)+"px"}function un(e){var t=o,n=Gt[e];return n||(n=ln(e,t),"none"!==n&&n||(Pt=(Pt||b("<iframe frameborder='0' width='0' height='0'/>").css("cssText","display:block !important")).appendTo(t.documentElement),t=(Pt[0].contentWindow||Pt[0].contentDocument).document,t.write("<!doctype html><html><body>"),t.close(),n=ln(e,t),Pt.detach()),Gt[e]=n),n}function ln(e,t){var n=b(t.createElement(e)).appendTo(t.body),r=b.css(n[0],"display");return n.remove(),r}b.each(["height","width"],function(e,n){b.cssHooks[n]={get:function(e,r,i){return r?0===e.offsetWidth&&Xt.test(b.css(e,"display"))?b.swap(e,Qt,function(){return sn(e,n,i)}):sn(e,n,i):t},set:function(e,t,r){var i=r&&Rt(e);return on(e,t,r?an(e,n,r,b.support.boxSizing&&"border-box"===b.css(e,"boxSizing",!1,i),i):0)}}}),b.support.opacity||(b.cssHooks.opacity={get:function(e,t){return It.test((t&&e.currentStyle?e.currentStyle.filter:e.style.filter)||"")?.01*parseFloat(RegExp.$1)+"":t?"1":""},set:function(e,t){var n=e.style,r=e.currentStyle,i=b.isNumeric(t)?"alpha(opacity="+100*t+")":"",o=r&&r.filter||n.filter||"";n.zoom=1,(t>=1||""===t)&&""===b.trim(o.replace($t,""))&&n.removeAttribute&&(n.removeAttribute("filter"),""===t||r&&!r.filter)||(n.filter=$t.test(o)?o.replace($t,i):o+" "+i)}}),b(function(){b.support.reliableMarginRight||(b.cssHooks.marginRight={get:function(e,n){return n?b.swap(e,{display:"inline-block"},Wt,[e,"marginRight"]):t}}),!b.support.pixelPosition&&b.fn.position&&b.each(["top","left"],function(e,n){b.cssHooks[n]={get:function(e,r){return r?(r=Wt(e,n),Yt.test(r)?b(e).position()[n]+"px":r):t}}})}),b.expr&&b.expr.filters&&(b.expr.filters.hidden=function(e){return 0>=e.offsetWidth&&0>=e.offsetHeight||!b.support.reliableHiddenOffsets&&"none"===(e.style&&e.style.display||b.css(e,"display"))},b.expr.filters.visible=function(e){return!b.expr.filters.hidden(e)}),b.each({margin:"",padding:"",border:"Width"},function(e,t){b.cssHooks[e+t]={expand:function(n){var r=0,i={},o="string"==typeof n?n.split(" "):[n];for(;4>r;r++)i[e+Zt[r]+t]=o[r]||o[r-2]||o[0];return i}},Ut.test(e)||(b.cssHooks[e+t].set=on)});var cn=/%20/g,pn=/\[\]$/,fn=/\r?\n/g,dn=/^(?:submit|button|image|reset|file)$/i,hn=/^(?:input|select|textarea|keygen)/i;b.fn.extend({serialize:function(){return b.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var e=b.prop(this,"elements");return e?b.makeArray(e):this}).filter(function(){var e=this.type;return this.name&&!b(this).is(":disabled")&&hn.test(this.nodeName)&&!dn.test(e)&&(this.checked||!Nt.test(e))}).map(function(e,t){var n=b(this).val();return null==n?null:b.isArray(n)?b.map(n,function(e){return{name:t.name,value:e.replace(fn,"\r\n")}}):{name:t.name,value:n.replace(fn,"\r\n")}}).get()}}),b.param=function(e,n){var r,i=[],o=function(e,t){t=b.isFunction(t)?t():null==t?"":t,i[i.length]=encodeURIComponent(e)+"="+encodeURIComponent(t)};if(n===t&&(n=b.ajaxSettings&&b.ajaxSettings.traditional),b.isArray(e)||e.jquery&&!b.isPlainObject(e))b.each(e,function(){o(this.name,this.value)});else for(r in e)gn(r,e[r],n,o);return i.join("&").replace(cn,"+")};function gn(e,t,n,r){var i;if(b.isArray(t))b.each(t,function(t,i){n||pn.test(e)?r(e,i):gn(e+"["+("object"==typeof i?t:"")+"]",i,n,r)});else if(n||"object"!==b.type(t))r(e,t);else for(i in t)gn(e+"["+i+"]",t[i],n,r)}b.each("blur focus focusin focusout load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup error contextmenu".split(" "),function(e,t){b.fn[t]=function(e,n){return arguments.length>0?this.on(t,null,e,n):this.trigger(t)}}),b.fn.hover=function(e,t){return this.mouseenter(e).mouseleave(t||e)};var mn,yn,vn=b.now(),bn=/\?/,xn=/#.*$/,wn=/([?&])_=[^&]*/,Tn=/^(.*?):[ \t]*([^\r\n]*)\r?$/gm,Nn=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,Cn=/^(?:GET|HEAD)$/,kn=/^\/\//,En=/^([\w.+-]+:)(?:\/\/([^\/?#:]*)(?::(\d+)|)|)/,Sn=b.fn.load,An={},jn={},Dn="*/".concat("*");try{yn=a.href}catch(Ln){yn=o.createElement("a"),yn.href="",yn=yn.href}mn=En.exec(yn.toLowerCase())||[];function Hn(e){return function(t,n){"string"!=typeof t&&(n=t,t="*");var r,i=0,o=t.toLowerCase().match(w)||[];if(b.isFunction(n))while(r=o[i++])"+"===r[0]?(r=r.slice(1)||"*",(e[r]=e[r]||[]).unshift(n)):(e[r]=e[r]||[]).push(n)}}function qn(e,n,r,i){var o={},a=e===jn;function s(u){var l;return o[u]=!0,b.each(e[u]||[],function(e,u){var c=u(n,r,i);return"string"!=typeof c||a||o[c]?a?!(l=c):t:(n.dataTypes.unshift(c),s(c),!1)}),l}return s(n.dataTypes[0])||!o["*"]&&s("*")}function Mn(e,n){var r,i,o=b.ajaxSettings.flatOptions||{};for(i in n)n[i]!==t&&((o[i]?e:r||(r={}))[i]=n[i]);return r&&b.extend(!0,e,r),e}b.fn.load=function(e,n,r){if("string"!=typeof e&&Sn)return Sn.apply(this,arguments);var i,o,a,s=this,u=e.indexOf(" ");return u>=0&&(i=e.slice(u,e.length),e=e.slice(0,u)),b.isFunction(n)?(r=n,n=t):n&&"object"==typeof n&&(a="POST"),s.length>0&&b.ajax({url:e,type:a,dataType:"html",data:n}).done(function(e){o=arguments,s.html(i?b("<div>").append(b.parseHTML(e)).find(i):e)}).complete(r&&function(e,t){s.each(r,o||[e.responseText,t,e])}),this},b.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(e,t){b.fn[t]=function(e){return this.on(t,e)}}),b.each(["get","post"],function(e,n){b[n]=function(e,r,i,o){return b.isFunction(r)&&(o=o||i,i=r,r=t),b.ajax({url:e,type:n,dataType:o,data:r,success:i})}}),b.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:yn,type:"GET",isLocal:Nn.test(mn[1]),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":Dn,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/xml/,html:/html/,json:/json/},responseFields:{xml:"responseXML",text:"responseText"},converters:{"* text":e.String,"text html":!0,"text json":b.parseJSON,"text xml":b.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(e,t){return t?Mn(Mn(e,b.ajaxSettings),t):Mn(b.ajaxSettings,e)},ajaxPrefilter:Hn(An),ajaxTransport:Hn(jn),ajax:function(e,n){"object"==typeof e&&(n=e,e=t),n=n||{};var r,i,o,a,s,u,l,c,p=b.ajaxSetup({},n),f=p.context||p,d=p.context&&(f.nodeType||f.jquery)?b(f):b.event,h=b.Deferred(),g=b.Callbacks("once memory"),m=p.statusCode||{},y={},v={},x=0,T="canceled",N={readyState:0,getResponseHeader:function(e){var t;if(2===x){if(!c){c={};while(t=Tn.exec(a))c[t[1].toLowerCase()]=t[2]}t=c[e.toLowerCase()]}return null==t?null:t},getAllResponseHeaders:function(){return 2===x?a:null},setRequestHeader:function(e,t){var n=e.toLowerCase();return x||(e=v[n]=v[n]||e,y[e]=t),this},overrideMimeType:function(e){return x||(p.mimeType=e),this},statusCode:function(e){var t;if(e)if(2>x)for(t in e)m[t]=[m[t],e[t]];else N.always(e[N.status]);return this},abort:function(e){var t=e||T;return l&&l.abort(t),k(0,t),this}};if(h.promise(N).complete=g.add,N.success=N.done,N.error=N.fail,p.url=((e||p.url||yn)+"").replace(xn,"").replace(kn,mn[1]+"//"),p.type=n.method||n.type||p.method||p.type,p.dataTypes=b.trim(p.dataType||"*").toLowerCase().match(w)||[""],null==p.crossDomain&&(r=En.exec(p.url.toLowerCase()),p.crossDomain=!(!r||r[1]===mn[1]&&r[2]===mn[2]&&(r[3]||("http:"===r[1]?80:443))==(mn[3]||("http:"===mn[1]?80:443)))),p.data&&p.processData&&"string"!=typeof p.data&&(p.data=b.param(p.data,p.traditional)),qn(An,p,n,N),2===x)return N;u=p.global,u&&0===b.active++&&b.event.trigger("ajaxStart"),p.type=p.type.toUpperCase(),p.hasContent=!Cn.test(p.type),o=p.url,p.hasContent||(p.data&&(o=p.url+=(bn.test(o)?"&":"?")+p.data,delete p.data),p.cache===!1&&(p.url=wn.test(o)?o.replace(wn,"$1_="+vn++):o+(bn.test(o)?"&":"?")+"_="+vn++)),p.ifModified&&(b.lastModified[o]&&N.setRequestHeader("If-Modified-Since",b.lastModified[o]),b.etag[o]&&N.setRequestHeader("If-None-Match",b.etag[o])),(p.data&&p.hasContent&&p.contentType!==!1||n.contentType)&&N.setRequestHeader("Content-Type",p.contentType),N.setRequestHeader("Accept",p.dataTypes[0]&&p.accepts[p.dataTypes[0]]?p.accepts[p.dataTypes[0]]+("*"!==p.dataTypes[0]?", "+Dn+"; q=0.01":""):p.accepts["*"]);for(i in p.headers)N.setRequestHeader(i,p.headers[i]);if(p.beforeSend&&(p.beforeSend.call(f,N,p)===!1||2===x))return N.abort();T="abort";for(i in{success:1,error:1,complete:1})N[i](p[i]);if(l=qn(jn,p,n,N)){N.readyState=1,u&&d.trigger("ajaxSend",[N,p]),p.async&&p.timeout>0&&(s=setTimeout(function(){N.abort("timeout")},p.timeout));try{x=1,l.send(y,k)}catch(C){if(!(2>x))throw C;k(-1,C)}}else k(-1,"No Transport");function k(e,n,r,i){var c,y,v,w,T,C=n;2!==x&&(x=2,s&&clearTimeout(s),l=t,a=i||"",N.readyState=e>0?4:0,r&&(w=_n(p,N,r)),e>=200&&300>e||304===e?(p.ifModified&&(T=N.getResponseHeader("Last-Modified"),T&&(b.lastModified[o]=T),T=N.getResponseHeader("etag"),T&&(b.etag[o]=T)),204===e?(c=!0,C="nocontent"):304===e?(c=!0,C="notmodified"):(c=Fn(p,w),C=c.state,y=c.data,v=c.error,c=!v)):(v=C,(e||!C)&&(C="error",0>e&&(e=0))),N.status=e,N.statusText=(n||C)+"",c?h.resolveWith(f,[y,C,N]):h.rejectWith(f,[N,C,v]),N.statusCode(m),m=t,u&&d.trigger(c?"ajaxSuccess":"ajaxError",[N,p,c?y:v]),g.fireWith(f,[N,C]),u&&(d.trigger("ajaxComplete",[N,p]),--b.active||b.event.trigger("ajaxStop")))}return N},getScript:function(e,n){return b.get(e,t,n,"script")},getJSON:function(e,t,n){return b.get(e,t,n,"json")}});function _n(e,n,r){var i,o,a,s,u=e.contents,l=e.dataTypes,c=e.responseFields;for(s in c)s in r&&(n[c[s]]=r[s]);while("*"===l[0])l.shift(),o===t&&(o=e.mimeType||n.getResponseHeader("Content-Type"));if(o)for(s in u)if(u[s]&&u[s].test(o)){l.unshift(s);break}if(l[0]in r)a=l[0];else{for(s in r){if(!l[0]||e.converters[s+" "+l[0]]){a=s;break}i||(i=s)}a=a||i}return a?(a!==l[0]&&l.unshift(a),r[a]):t}function Fn(e,t){var n,r,i,o,a={},s=0,u=e.dataTypes.slice(),l=u[0];if(e.dataFilter&&(t=e.dataFilter(t,e.dataType)),u[1])for(i in e.converters)a[i.toLowerCase()]=e.converters[i];for(;r=u[++s];)if("*"!==r){if("*"!==l&&l!==r){if(i=a[l+" "+r]||a["* "+r],!i)for(n in a)if(o=n.split(" "),o[1]===r&&(i=a[l+" "+o[0]]||a["* "+o[0]])){i===!0?i=a[n]:a[n]!==!0&&(r=o[0],u.splice(s--,0,r));break}if(i!==!0)if(i&&e["throws"])t=i(t);else try{t=i(t)}catch(c){return{state:"parsererror",error:i?c:"No conversion from "+l+" to "+r}}}l=r}return{state:"success",data:t}}b.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/(?:java|ecma)script/},converters:{"text script":function(e){return b.globalEval(e),e}}}),b.ajaxPrefilter("script",function(e){e.cache===t&&(e.cache=!1),e.crossDomain&&(e.type="GET",e.global=!1)}),b.ajaxTransport("script",function(e){if(e.crossDomain){var n,r=o.head||b("head")[0]||o.documentElement;return{send:function(t,i){n=o.createElement("script"),n.async=!0,e.scriptCharset&&(n.charset=e.scriptCharset),n.src=e.url,n.onload=n.onreadystatechange=function(e,t){(t||!n.readyState||/loaded|complete/.test(n.readyState))&&(n.onload=n.onreadystatechange=null,n.parentNode&&n.parentNode.removeChild(n),n=null,t||i(200,"success"))},r.insertBefore(n,r.firstChild)},abort:function(){n&&n.onload(t,!0)}}}});var On=[],Bn=/(=)\?(?=&|$)|\?\?/;b.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var e=On.pop()||b.expando+"_"+vn++;return this[e]=!0,e}}),b.ajaxPrefilter("json jsonp",function(n,r,i){var o,a,s,u=n.jsonp!==!1&&(Bn.test(n.url)?"url":"string"==typeof n.data&&!(n.contentType||"").indexOf("application/x-www-form-urlencoded")&&Bn.test(n.data)&&"data");return u||"jsonp"===n.dataTypes[0]?(o=n.jsonpCallback=b.isFunction(n.jsonpCallback)?n.jsonpCallback():n.jsonpCallback,u?n[u]=n[u].replace(Bn,"$1"+o):n.jsonp!==!1&&(n.url+=(bn.test(n.url)?"&":"?")+n.jsonp+"="+o),n.converters["script json"]=function(){return s||b.error(o+" was not called"),s[0]},n.dataTypes[0]="json",a=e[o],e[o]=function(){s=arguments},i.always(function(){e[o]=a,n[o]&&(n.jsonpCallback=r.jsonpCallback,On.push(o)),s&&b.isFunction(a)&&a(s[0]),s=a=t}),"script"):t});var Pn,Rn,Wn=0,$n=e.ActiveXObject&&function(){var e;for(e in Pn)Pn[e](t,!0)};function In(){try{return new e.XMLHttpRequest}catch(t){}}function zn(){try{return new e.ActiveXObject("Microsoft.XMLHTTP")}catch(t){}}b.ajaxSettings.xhr=e.ActiveXObject?function(){return!this.isLocal&&In()||zn()}:In,Rn=b.ajaxSettings.xhr(),b.support.cors=!!Rn&&"withCredentials"in Rn,Rn=b.support.ajax=!!Rn,Rn&&b.ajaxTransport(function(n){if(!n.crossDomain||b.support.cors){var r;return{send:function(i,o){var a,s,u=n.xhr();if(n.username?u.open(n.type,n.url,n.async,n.username,n.password):u.open(n.type,n.url,n.async),n.xhrFields)for(s in n.xhrFields)u[s]=n.xhrFields[s];n.mimeType&&u.overrideMimeType&&u.overrideMimeType(n.mimeType),n.crossDomain||i["X-Requested-With"]||(i["X-Requested-With"]="XMLHttpRequest");try{for(s in i)u.setRequestHeader(s,i[s])}catch(l){}u.send(n.hasContent&&n.data||null),r=function(e,i){var s,l,c,p;try{if(r&&(i||4===u.readyState))if(r=t,a&&(u.onreadystatechange=b.noop,$n&&delete Pn[a]),i)4!==u.readyState&&u.abort();else{p={},s=u.status,l=u.getAllResponseHeaders(),"string"==typeof u.responseText&&(p.text=u.responseText);try{c=u.statusText}catch(f){c=""}s||!n.isLocal||n.crossDomain?1223===s&&(s=204):s=p.text?200:404}}catch(d){i||o(-1,d)}p&&o(s,c,p,l)},n.async?4===u.readyState?setTimeout(r):(a=++Wn,$n&&(Pn||(Pn={},b(e).unload($n)),Pn[a]=r),u.onreadystatechange=r):r()},abort:function(){r&&r(t,!0)}}}});var Xn,Un,Vn=/^(?:toggle|show|hide)$/,Yn=RegExp("^(?:([+-])=|)("+x+")([a-z%]*)$","i"),Jn=/queueHooks$/,Gn=[nr],Qn={"*":[function(e,t){var n,r,i=this.createTween(e,t),o=Yn.exec(t),a=i.cur(),s=+a||0,u=1,l=20;if(o){if(n=+o[2],r=o[3]||(b.cssNumber[e]?"":"px"),"px"!==r&&s){s=b.css(i.elem,e,!0)||n||1;do u=u||".5",s/=u,b.style(i.elem,e,s+r);while(u!==(u=i.cur()/a)&&1!==u&&--l)}i.unit=r,i.start=s,i.end=o[1]?s+(o[1]+1)*n:n}return i}]};function Kn(){return setTimeout(function(){Xn=t}),Xn=b.now()}function Zn(e,t){b.each(t,function(t,n){var r=(Qn[t]||[]).concat(Qn["*"]),i=0,o=r.length;for(;o>i;i++)if(r[i].call(e,t,n))return})}function er(e,t,n){var r,i,o=0,a=Gn.length,s=b.Deferred().always(function(){delete u.elem}),u=function(){if(i)return!1;var t=Xn||Kn(),n=Math.max(0,l.startTime+l.duration-t),r=n/l.duration||0,o=1-r,a=0,u=l.tweens.length;for(;u>a;a++)l.tweens[a].run(o);return s.notifyWith(e,[l,o,n]),1>o&&u?n:(s.resolveWith(e,[l]),!1)},l=s.promise({elem:e,props:b.extend({},t),opts:b.extend(!0,{specialEasing:{}},n),originalProperties:t,originalOptions:n,startTime:Xn||Kn(),duration:n.duration,tweens:[],createTween:function(t,n){var r=b.Tween(e,l.opts,t,n,l.opts.specialEasing[t]||l.opts.easing);return l.tweens.push(r),r},stop:function(t){var n=0,r=t?l.tweens.length:0;if(i)return this;for(i=!0;r>n;n++)l.tweens[n].run(1);return t?s.resolveWith(e,[l,t]):s.rejectWith(e,[l,t]),this}}),c=l.props;for(tr(c,l.opts.specialEasing);a>o;o++)if(r=Gn[o].call(l,e,c,l.opts))return r;return Zn(l,c),b.isFunction(l.opts.start)&&l.opts.start.call(e,l),b.fx.timer(b.extend(u,{elem:e,anim:l,queue:l.opts.queue})),l.progress(l.opts.progress).done(l.opts.done,l.opts.complete).fail(l.opts.fail).always(l.opts.always)}function tr(e,t){var n,r,i,o,a;for(i in e)if(r=b.camelCase(i),o=t[r],n=e[i],b.isArray(n)&&(o=n[1],n=e[i]=n[0]),i!==r&&(e[r]=n,delete e[i]),a=b.cssHooks[r],a&&"expand"in a){n=a.expand(n),delete e[r];for(i in n)i in e||(e[i]=n[i],t[i]=o)}else t[r]=o}b.Animation=b.extend(er,{tweener:function(e,t){b.isFunction(e)?(t=e,e=["*"]):e=e.split(" ");var n,r=0,i=e.length;for(;i>r;r++)n=e[r],Qn[n]=Qn[n]||[],Qn[n].unshift(t)},prefilter:function(e,t){t?Gn.unshift(e):Gn.push(e)}});function nr(e,t,n){var r,i,o,a,s,u,l,c,p,f=this,d=e.style,h={},g=[],m=e.nodeType&&nn(e);n.queue||(c=b._queueHooks(e,"fx"),null==c.unqueued&&(c.unqueued=0,p=c.empty.fire,c.empty.fire=function(){c.unqueued||p()}),c.unqueued++,f.always(function(){f.always(function(){c.unqueued--,b.queue(e,"fx").length||c.empty.fire()})})),1===e.nodeType&&("height"in t||"width"in t)&&(n.overflow=[d.overflow,d.overflowX,d.overflowY],"inline"===b.css(e,"display")&&"none"===b.css(e,"float")&&(b.support.inlineBlockNeedsLayout&&"inline"!==un(e.nodeName)?d.zoom=1:d.display="inline-block")),n.overflow&&(d.overflow="hidden",b.support.shrinkWrapBlocks||f.always(function(){d.overflow=n.overflow[0],d.overflowX=n.overflow[1],d.overflowY=n.overflow[2]}));for(i in t)if(a=t[i],Vn.exec(a)){if(delete t[i],u=u||"toggle"===a,a===(m?"hide":"show"))continue;g.push(i)}if(o=g.length){s=b._data(e,"fxshow")||b._data(e,"fxshow",{}),"hidden"in s&&(m=s.hidden),u&&(s.hidden=!m),m?b(e).show():f.done(function(){b(e).hide()}),f.done(function(){var t;b._removeData(e,"fxshow");for(t in h)b.style(e,t,h[t])});for(i=0;o>i;i++)r=g[i],l=f.createTween(r,m?s[r]:0),h[r]=s[r]||b.style(e,r),r in s||(s[r]=l.start,m&&(l.end=l.start,l.start="width"===r||"height"===r?1:0))}}function rr(e,t,n,r,i){return new rr.prototype.init(e,t,n,r,i)}b.Tween=rr,rr.prototype={constructor:rr,init:function(e,t,n,r,i,o){this.elem=e,this.prop=n,this.easing=i||"swing",this.options=t,this.start=this.now=this.cur(),this.end=r,this.unit=o||(b.cssNumber[n]?"":"px")},cur:function(){var e=rr.propHooks[this.prop];return e&&e.get?e.get(this):rr.propHooks._default.get(this)},run:function(e){var t,n=rr.propHooks[this.prop];return this.pos=t=this.options.duration?b.easing[this.easing](e,this.options.duration*e,0,1,this.options.duration):e,this.now=(this.end-this.start)*t+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),n&&n.set?n.set(this):rr.propHooks._default.set(this),this}},rr.prototype.init.prototype=rr.prototype,rr.propHooks={_default:{get:function(e){var t;return null==e.elem[e.prop]||e.elem.style&&null!=e.elem.style[e.prop]?(t=b.css(e.elem,e.prop,""),t&&"auto"!==t?t:0):e.elem[e.prop]},set:function(e){b.fx.step[e.prop]?b.fx.step[e.prop](e):e.elem.style&&(null!=e.elem.style[b.cssProps[e.prop]]||b.cssHooks[e.prop])?b.style(e.elem,e.prop,e.now+e.unit):e.elem[e.prop]=e.now}}},rr.propHooks.scrollTop=rr.propHooks.scrollLeft={set:function(e){e.elem.nodeType&&e.elem.parentNode&&(e.elem[e.prop]=e.now)}},b.each(["toggle","show","hide"],function(e,t){var n=b.fn[t];b.fn[t]=function(e,r,i){return null==e||"boolean"==typeof e?n.apply(this,arguments):this.animate(ir(t,!0),e,r,i)}}),b.fn.extend({fadeTo:function(e,t,n,r){return this.filter(nn).css("opacity",0).show().end().animate({opacity:t},e,n,r)},animate:function(e,t,n,r){var i=b.isEmptyObject(e),o=b.speed(t,n,r),a=function(){var t=er(this,b.extend({},e),o);a.finish=function(){t.stop(!0)},(i||b._data(this,"finish"))&&t.stop(!0)};return a.finish=a,i||o.queue===!1?this.each(a):this.queue(o.queue,a)},stop:function(e,n,r){var i=function(e){var t=e.stop;delete e.stop,t(r)};return"string"!=typeof e&&(r=n,n=e,e=t),n&&e!==!1&&this.queue(e||"fx",[]),this.each(function(){var t=!0,n=null!=e&&e+"queueHooks",o=b.timers,a=b._data(this);if(n)a[n]&&a[n].stop&&i(a[n]);else for(n in a)a[n]&&a[n].stop&&Jn.test(n)&&i(a[n]);for(n=o.length;n--;)o[n].elem!==this||null!=e&&o[n].queue!==e||(o[n].anim.stop(r),t=!1,o.splice(n,1));(t||!r)&&b.dequeue(this,e)})},finish:function(e){return e!==!1&&(e=e||"fx"),this.each(function(){var t,n=b._data(this),r=n[e+"queue"],i=n[e+"queueHooks"],o=b.timers,a=r?r.length:0;for(n.finish=!0,b.queue(this,e,[]),i&&i.cur&&i.cur.finish&&i.cur.finish.call(this),t=o.length;t--;)o[t].elem===this&&o[t].queue===e&&(o[t].anim.stop(!0),o.splice(t,1));for(t=0;a>t;t++)r[t]&&r[t].finish&&r[t].finish.call(this);delete n.finish})}});function ir(e,t){var n,r={height:e},i=0;for(t=t?1:0;4>i;i+=2-t)n=Zt[i],r["margin"+n]=r["padding"+n]=e;return t&&(r.opacity=r.width=e),r}b.each({slideDown:ir("show"),slideUp:ir("hide"),slideToggle:ir("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(e,t){b.fn[e]=function(e,n,r){return this.animate(t,e,n,r)}}),b.speed=function(e,t,n){var r=e&&"object"==typeof e?b.extend({},e):{complete:n||!n&&t||b.isFunction(e)&&e,duration:e,easing:n&&t||t&&!b.isFunction(t)&&t};return r.duration=b.fx.off?0:"number"==typeof r.duration?r.duration:r.duration in b.fx.speeds?b.fx.speeds[r.duration]:b.fx.speeds._default,(null==r.queue||r.queue===!0)&&(r.queue="fx"),r.old=r.complete,r.complete=function(){b.isFunction(r.old)&&r.old.call(this),r.queue&&b.dequeue(this,r.queue)},r},b.easing={linear:function(e){return e},swing:function(e){return.5-Math.cos(e*Math.PI)/2}},b.timers=[],b.fx=rr.prototype.init,b.fx.tick=function(){var e,n=b.timers,r=0;for(Xn=b.now();n.length>r;r++)e=n[r],e()||n[r]!==e||n.splice(r--,1);n.length||b.fx.stop(),Xn=t},b.fx.timer=function(e){e()&&b.timers.push(e)&&b.fx.start()},b.fx.interval=13,b.fx.start=function(){Un||(Un=setInterval(b.fx.tick,b.fx.interval))},b.fx.stop=function(){clearInterval(Un),Un=null},b.fx.speeds={slow:600,fast:200,_default:400},b.fx.step={},b.expr&&b.expr.filters&&(b.expr.filters.animated=function(e){return b.grep(b.timers,function(t){return e===t.elem}).length}),b.fn.offset=function(e){if(arguments.length)return e===t?this:this.each(function(t){b.offset.setOffset(this,e,t)});var n,r,o={top:0,left:0},a=this[0],s=a&&a.ownerDocument;if(s)return n=s.documentElement,b.contains(n,a)?(typeof a.getBoundingClientRect!==i&&(o=a.getBoundingClientRect()),r=or(s),{top:o.top+(r.pageYOffset||n.scrollTop)-(n.clientTop||0),left:o.left+(r.pageXOffset||n.scrollLeft)-(n.clientLeft||0)}):o},b.offset={setOffset:function(e,t,n){var r=b.css(e,"position");"static"===r&&(e.style.position="relative");var i=b(e),o=i.offset(),a=b.css(e,"top"),s=b.css(e,"left"),u=("absolute"===r||"fixed"===r)&&b.inArray("auto",[a,s])>-1,l={},c={},p,f;u?(c=i.position(),p=c.top,f=c.left):(p=parseFloat(a)||0,f=parseFloat(s)||0),b.isFunction(t)&&(t=t.call(e,n,o)),null!=t.top&&(l.top=t.top-o.top+p),null!=t.left&&(l.left=t.left-o.left+f),"using"in t?t.using.call(e,l):i.css(l)}},b.fn.extend({position:function(){if(this[0]){var e,t,n={top:0,left:0},r=this[0];return"fixed"===b.css(r,"position")?t=r.getBoundingClientRect():(e=this.offsetParent(),t=this.offset(),b.nodeName(e[0],"html")||(n=e.offset()),n.top+=b.css(e[0],"borderTopWidth",!0),n.left+=b.css(e[0],"borderLeftWidth",!0)),{top:t.top-n.top-b.css(r,"marginTop",!0),left:t.left-n.left-b.css(r,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var e=this.offsetParent||o.documentElement;while(e&&!b.nodeName(e,"html")&&"static"===b.css(e,"position"))e=e.offsetParent;return e||o.documentElement})}}),b.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(e,n){var r=/Y/.test(n);b.fn[e]=function(i){return b.access(this,function(e,i,o){var a=or(e);return o===t?a?n in a?a[n]:a.document.documentElement[i]:e[i]:(a?a.scrollTo(r?b(a).scrollLeft():o,r?o:b(a).scrollTop()):e[i]=o,t)},e,i,arguments.length,null)}});function or(e){return b.isWindow(e)?e:9===e.nodeType?e.defaultView||e.parentWindow:!1}b.each({Height:"height",Width:"width"},function(e,n){b.each({padding:"inner"+e,content:n,"":"outer"+e},function(r,i){b.fn[i]=function(i,o){var a=arguments.length&&(r||"boolean"!=typeof i),s=r||(i===!0||o===!0?"margin":"border");return b.access(this,function(n,r,i){var o;return b.isWindow(n)?n.document.documentElement["client"+e]:9===n.nodeType?(o=n.documentElement,Math.max(n.body["scroll"+e],o["scroll"+e],n.body["offset"+e],o["offset"+e],o["client"+e])):i===t?b.css(n,r,s):b.style(n,r,i,s)},n,a?i:t,a,null)}})}),e.jQuery=e.$=b,"function"==typeof define&&define.amd&&define.amd.jQuery&&define("jquery",[],function(){return b})})(window);
\ No newline at end of file
diff --git a/docs/theme/docker/static/js/vendor/modernizr-2.6.2-respond-1.1.0.min.js b/docs/theme/docker/static/js/vendor/modernizr-2.6.2-respond-1.1.0.min.js
deleted file mode 100755
index 302f461..0000000
--- a/docs/theme/docker/static/js/vendor/modernizr-2.6.2-respond-1.1.0.min.js
+++ /dev/null
@@ -1,11 +0,0 @@
-/* Modernizr 2.6.2 (Custom Build) | MIT & BSD
- * Build: http://modernizr.com/download/#-fontface-backgroundsize-borderimage-borderradius-boxshadow-flexbox-hsla-multiplebgs-opacity-rgba-textshadow-cssanimations-csscolumns-generatedcontent-cssgradients-cssreflections-csstransforms-csstransforms3d-csstransitions-applicationcache-canvas-canvastext-draganddrop-hashchange-history-audio-video-indexeddb-input-inputtypes-localstorage-postmessage-sessionstorage-websockets-websqldatabase-webworkers-geolocation-inlinesvg-smil-svg-svgclippaths-touch-webgl-shiv-mq-cssclasses-addtest-prefixed-teststyles-testprop-testallprops-hasevent-prefixes-domprefixes-load
- */
-;window.Modernizr=function(a,b,c){function D(a){j.cssText=a}function E(a,b){return D(n.join(a+";")+(b||""))}function F(a,b){return typeof a===b}function G(a,b){return!!~(""+a).indexOf(b)}function H(a,b){for(var d in a){var e=a[d];if(!G(e,"-")&&j[e]!==c)return b=="pfx"?e:!0}return!1}function I(a,b,d){for(var e in a){var f=b[a[e]];if(f!==c)return d===!1?a[e]:F(f,"function")?f.bind(d||b):f}return!1}function J(a,b,c){var d=a.charAt(0).toUpperCase()+a.slice(1),e=(a+" "+p.join(d+" ")+d).split(" ");return F(b,"string")||F(b,"undefined")?H(e,b):(e=(a+" "+q.join(d+" ")+d).split(" "),I(e,b,c))}function K(){e.input=function(c){for(var d=0,e=c.length;d<e;d++)u[c[d]]=c[d]in k;return u.list&&(u.list=!!b.createElement("datalist")&&!!a.HTMLDataListElement),u}("autocomplete autofocus list placeholder max min multiple pattern required step".split(" ")),e.inputtypes=function(a){for(var d=0,e,f,h,i=a.length;d<i;d++)k.setAttribute("type",f=a[d]),e=k.type!=="text",e&&(k.value=l,k.style.cssText="position:absolute;visibility:hidden;",/^range$/.test(f)&&k.style.WebkitAppearance!==c?(g.appendChild(k),h=b.defaultView,e=h.getComputedStyle&&h.getComputedStyle(k,null).WebkitAppearance!=="textfield"&&k.offsetHeight!==0,g.removeChild(k)):/^(search|tel)$/.test(f)||(/^(url|email)$/.test(f)?e=k.checkValidity&&k.checkValidity()===!1:e=k.value!=l)),t[a[d]]=!!e;return t}("search tel url email datetime date month week time datetime-local number range color".split(" "))}var d="2.6.2",e={},f=!0,g=b.documentElement,h="modernizr",i=b.createElement(h),j=i.style,k=b.createElement("input"),l=":)",m={}.toString,n=" -webkit- -moz- -o- -ms- ".split(" "),o="Webkit Moz O ms",p=o.split(" "),q=o.toLowerCase().split(" "),r={svg:"http://www.w3.org/2000/svg"},s={},t={},u={},v=[],w=v.slice,x,y=function(a,c,d,e){var f,i,j,k,l=b.createElement("div"),m=b.body,n=m||b.createElement("body");if(parseInt(d,10))while(d--)j=b.createElement("div"),j.id=e?e[d]:h+(d+1),l.appendChild(j);return f=["&#173;",'<style id="s',h,'">',a,"</style>"].join(""),l.id=h,(m?l:n).innerHTML+=f,n.appendChild(l),m||(n.style.background="",n.style.overflow="hidden",k=g.style.overflow,g.style.overflow="hidden",g.appendChild(n)),i=c(l,a),m?l.parentNode.removeChild(l):(n.parentNode.removeChild(n),g.style.overflow=k),!!i},z=function(b){var c=a.matchMedia||a.msMatchMedia;if(c)return c(b).matches;var d;return y("@media "+b+" { #"+h+" { position: absolute; } }",function(b){d=(a.getComputedStyle?getComputedStyle(b,null):b.currentStyle)["position"]=="absolute"}),d},A=function(){function d(d,e){e=e||b.createElement(a[d]||"div"),d="on"+d;var f=d in e;return f||(e.setAttribute||(e=b.createElement("div")),e.setAttribute&&e.removeAttribute&&(e.setAttribute(d,""),f=F(e[d],"function"),F(e[d],"undefined")||(e[d]=c),e.removeAttribute(d))),e=null,f}var a={select:"input",change:"input",submit:"form",reset:"form",error:"img",load:"img",abort:"img"};return d}(),B={}.hasOwnProperty,C;!F(B,"undefined")&&!F(B.call,"undefined")?C=function(a,b){return B.call(a,b)}:C=function(a,b){return b in a&&F(a.constructor.prototype[b],"undefined")},Function.prototype.bind||(Function.prototype.bind=function(b){var c=this;if(typeof c!="function")throw new TypeError;var d=w.call(arguments,1),e=function(){if(this instanceof e){var a=function(){};a.prototype=c.prototype;var f=new a,g=c.apply(f,d.concat(w.call(arguments)));return Object(g)===g?g:f}return c.apply(b,d.concat(w.call(arguments)))};return e}),s.flexbox=function(){return J("flexWrap")},s.canvas=function(){var a=b.createElement("canvas");return!!a.getContext&&!!a.getContext("2d")},s.canvastext=function(){return!!e.canvas&&!!F(b.createElement("canvas").getContext("2d").fillText,"function")},s.webgl=function(){return!!a.WebGLRenderingContext},s.touch=function(){var c;return"ontouchstart"in a||a.DocumentTouch&&b instanceof DocumentTouch?c=!0:y(["@media (",n.join("touch-enabled),("),h,")","{#modernizr{top:9px;position:absolute}}"].join(""),function(a){c=a.offsetTop===9}),c},s.geolocation=function(){return"geolocation"in navigator},s.postmessage=function(){return!!a.postMessage},s.websqldatabase=function(){return!!a.openDatabase},s.indexedDB=function(){return!!J("indexedDB",a)},s.hashchange=function(){return A("hashchange",a)&&(b.documentMode===c||b.documentMode>7)},s.history=function(){return!!a.history&&!!history.pushState},s.draganddrop=function(){var a=b.createElement("div");return"draggable"in a||"ondragstart"in a&&"ondrop"in a},s.websockets=function(){return"WebSocket"in a||"MozWebSocket"in a},s.rgba=function(){return D("background-color:rgba(150,255,150,.5)"),G(j.backgroundColor,"rgba")},s.hsla=function(){return D("background-color:hsla(120,40%,100%,.5)"),G(j.backgroundColor,"rgba")||G(j.backgroundColor,"hsla")},s.multiplebgs=function(){return D("background:url(https://),url(https://),red url(https://)"),/(url\s*\(.*?){3}/.test(j.background)},s.backgroundsize=function(){return J("backgroundSize")},s.borderimage=function(){return J("borderImage")},s.borderradius=function(){return J("borderRadius")},s.boxshadow=function(){return J("boxShadow")},s.textshadow=function(){return b.createElement("div").style.textShadow===""},s.opacity=function(){return E("opacity:.55"),/^0.55$/.test(j.opacity)},s.cssanimations=function(){return J("animationName")},s.csscolumns=function(){return J("columnCount")},s.cssgradients=function(){var a="background-image:",b="gradient(linear,left top,right bottom,from(#9f9),to(white));",c="linear-gradient(left top,#9f9, white);";return D((a+"-webkit- ".split(" ").join(b+a)+n.join(c+a)).slice(0,-a.length)),G(j.backgroundImage,"gradient")},s.cssreflections=function(){return J("boxReflect")},s.csstransforms=function(){return!!J("transform")},s.csstransforms3d=function(){var a=!!J("perspective");return a&&"webkitPerspective"in g.style&&y("@media (transform-3d),(-webkit-transform-3d){#modernizr{left:9px;position:absolute;height:3px;}}",function(b,c){a=b.offsetLeft===9&&b.offsetHeight===3}),a},s.csstransitions=function(){return J("transition")},s.fontface=function(){var a;return y('@font-face {font-family:"font";src:url("https://")}',function(c,d){var e=b.getElementById("smodernizr"),f=e.sheet||e.styleSheet,g=f?f.cssRules&&f.cssRules[0]?f.cssRules[0].cssText:f.cssText||"":"";a=/src/i.test(g)&&g.indexOf(d.split(" ")[0])===0}),a},s.generatedcontent=function(){var a;return y(["#",h,"{font:0/0 a}#",h,':after{content:"',l,'";visibility:hidden;font:3px/1 a}'].join(""),function(b){a=b.offsetHeight>=3}),a},s.video=function(){var a=b.createElement("video"),c=!1;try{if(c=!!a.canPlayType)c=new Boolean(c),c.ogg=a.canPlayType('video/ogg; codecs="theora"').replace(/^no$/,""),c.h264=a.canPlayType('video/mp4; codecs="avc1.42E01E"').replace(/^no$/,""),c.webm=a.canPlayType('video/webm; codecs="vp8, vorbis"').replace(/^no$/,"")}catch(d){}return c},s.audio=function(){var a=b.createElement("audio"),c=!1;try{if(c=!!a.canPlayType)c=new Boolean(c),c.ogg=a.canPlayType('audio/ogg; codecs="vorbis"').replace(/^no$/,""),c.mp3=a.canPlayType("audio/mpeg;").replace(/^no$/,""),c.wav=a.canPlayType('audio/wav; codecs="1"').replace(/^no$/,""),c.m4a=(a.canPlayType("audio/x-m4a;")||a.canPlayType("audio/aac;")).replace(/^no$/,"")}catch(d){}return c},s.localstorage=function(){try{return localStorage.setItem(h,h),localStorage.removeItem(h),!0}catch(a){return!1}},s.sessionstorage=function(){try{return sessionStorage.setItem(h,h),sessionStorage.removeItem(h),!0}catch(a){return!1}},s.webworkers=function(){return!!a.Worker},s.applicationcache=function(){return!!a.applicationCache},s.svg=function(){return!!b.createElementNS&&!!b.createElementNS(r.svg,"svg").createSVGRect},s.inlinesvg=function(){var a=b.createElement("div");return a.innerHTML="<svg/>",(a.firstChild&&a.firstChild.namespaceURI)==r.svg},s.smil=function(){return!!b.createElementNS&&/SVGAnimate/.test(m.call(b.createElementNS(r.svg,"animate")))},s.svgclippaths=function(){return!!b.createElementNS&&/SVGClipPath/.test(m.call(b.createElementNS(r.svg,"clipPath")))};for(var L in s)C(s,L)&&(x=L.toLowerCase(),e[x]=s[L](),v.push((e[x]?"":"no-")+x));return e.input||K(),e.addTest=function(a,b){if(typeof a=="object")for(var d in a)C(a,d)&&e.addTest(d,a[d]);else{a=a.toLowerCase();if(e[a]!==c)return e;b=typeof b=="function"?b():b,typeof f!="undefined"&&f&&(g.className+=" "+(b?"":"no-")+a),e[a]=b}return e},D(""),i=k=null,function(a,b){function k(a,b){var c=a.createElement("p"),d=a.getElementsByTagName("head")[0]||a.documentElement;return c.innerHTML="x<style>"+b+"</style>",d.insertBefore(c.lastChild,d.firstChild)}function l(){var a=r.elements;return typeof a=="string"?a.split(" "):a}function m(a){var b=i[a[g]];return b||(b={},h++,a[g]=h,i[h]=b),b}function n(a,c,f){c||(c=b);if(j)return c.createElement(a);f||(f=m(c));var g;return f.cache[a]?g=f.cache[a].cloneNode():e.test(a)?g=(f.cache[a]=f.createElem(a)).cloneNode():g=f.createElem(a),g.canHaveChildren&&!d.test(a)?f.frag.appendChild(g):g}function o(a,c){a||(a=b);if(j)return a.createDocumentFragment();c=c||m(a);var d=c.frag.cloneNode(),e=0,f=l(),g=f.length;for(;e<g;e++)d.createElement(f[e]);return d}function p(a,b){b.cache||(b.cache={},b.createElem=a.createElement,b.createFrag=a.createDocumentFragment,b.frag=b.createFrag()),a.createElement=function(c){return r.shivMethods?n(c,a,b):b.createElem(c)},a.createDocumentFragment=Function("h,f","return function(){var n=f.cloneNode(),c=n.createElement;h.shivMethods&&("+l().join().replace(/\w+/g,function(a){return b.createElem(a),b.frag.createElement(a),'c("'+a+'")'})+");return n}")(r,b.frag)}function q(a){a||(a=b);var c=m(a);return r.shivCSS&&!f&&!c.hasCSS&&(c.hasCSS=!!k(a,"article,aside,figcaption,figure,footer,header,hgroup,nav,section{display:block}mark{background:#FF0;color:#000}")),j||p(a,c),a}var c=a.html5||{},d=/^<|^(?:button|map|select|textarea|object|iframe|option|optgroup)$/i,e=/^(?:a|b|code|div|fieldset|h1|h2|h3|h4|h5|h6|i|label|li|ol|p|q|span|strong|style|table|tbody|td|th|tr|ul)$/i,f,g="_html5shiv",h=0,i={},j;(function(){try{var a=b.createElement("a");a.innerHTML="<xyz></xyz>",f="hidden"in a,j=a.childNodes.length==1||function(){b.createElement("a");var a=b.createDocumentFragment();return typeof a.cloneNode=="undefined"||typeof a.createDocumentFragment=="undefined"||typeof a.createElement=="undefined"}()}catch(c){f=!0,j=!0}})();var r={elements:c.elements||"abbr article aside audio bdi canvas data datalist details figcaption figure footer header hgroup mark meter nav output progress section summary time video",shivCSS:c.shivCSS!==!1,supportsUnknownElements:j,shivMethods:c.shivMethods!==!1,type:"default",shivDocument:q,createElement:n,createDocumentFragment:o};a.html5=r,q(b)}(this,b),e._version=d,e._prefixes=n,e._domPrefixes=q,e._cssomPrefixes=p,e.mq=z,e.hasEvent=A,e.testProp=function(a){return H([a])},e.testAllProps=J,e.testStyles=y,e.prefixed=function(a,b,c){return b?J(a,b,c):J(a,"pfx")},g.className=g.className.replace(/(^|\s)no-js(\s|$)/,"$1$2")+(f?" js "+v.join(" "):""),e}(this,this.document),function(a,b,c){function d(a){return"[object Function]"==o.call(a)}function e(a){return"string"==typeof a}function f(){}function g(a){return!a||"loaded"==a||"complete"==a||"uninitialized"==a}function h(){var a=p.shift();q=1,a?a.t?m(function(){("c"==a.t?B.injectCss:B.injectJs)(a.s,0,a.a,a.x,a.e,1)},0):(a(),h()):q=0}function i(a,c,d,e,f,i,j){function k(b){if(!o&&g(l.readyState)&&(u.r=o=1,!q&&h(),l.onload=l.onreadystatechange=null,b)){"img"!=a&&m(function(){t.removeChild(l)},50);for(var d in y[c])y[c].hasOwnProperty(d)&&y[c][d].onload()}}var j=j||B.errorTimeout,l=b.createElement(a),o=0,r=0,u={t:d,s:c,e:f,a:i,x:j};1===y[c]&&(r=1,y[c]=[]),"object"==a?l.data=c:(l.src=c,l.type=a),l.width=l.height="0",l.onerror=l.onload=l.onreadystatechange=function(){k.call(this,r)},p.splice(e,0,u),"img"!=a&&(r||2===y[c]?(t.insertBefore(l,s?null:n),m(k,j)):y[c].push(l))}function j(a,b,c,d,f){return q=0,b=b||"j",e(a)?i("c"==b?v:u,a,b,this.i++,c,d,f):(p.splice(this.i++,0,a),1==p.length&&h()),this}function k(){var a=B;return a.loader={load:j,i:0},a}var l=b.documentElement,m=a.setTimeout,n=b.getElementsByTagName("script")[0],o={}.toString,p=[],q=0,r="MozAppearance"in l.style,s=r&&!!b.createRange().compareNode,t=s?l:n.parentNode,l=a.opera&&"[object Opera]"==o.call(a.opera),l=!!b.attachEvent&&!l,u=r?"object":l?"script":"img",v=l?"script":u,w=Array.isArray||function(a){return"[object Array]"==o.call(a)},x=[],y={},z={timeout:function(a,b){return b.length&&(a.timeout=b[0]),a}},A,B;B=function(a){function b(a){var a=a.split("!"),b=x.length,c=a.pop(),d=a.length,c={url:c,origUrl:c,prefixes:a},e,f,g;for(f=0;f<d;f++)g=a[f].split("="),(e=z[g.shift()])&&(c=e(c,g));for(f=0;f<b;f++)c=x[f](c);return c}function g(a,e,f,g,h){var i=b(a),j=i.autoCallback;i.url.split(".").pop().split("?").shift(),i.bypass||(e&&(e=d(e)?e:e[a]||e[g]||e[a.split("/").pop().split("?")[0]]),i.instead?i.instead(a,e,f,g,h):(y[i.url]?i.noexec=!0:y[i.url]=1,f.load(i.url,i.forceCSS||!i.forceJS&&"css"==i.url.split(".").pop().split("?").shift()?"c":c,i.noexec,i.attrs,i.timeout),(d(e)||d(j))&&f.load(function(){k(),e&&e(i.origUrl,h,g),j&&j(i.origUrl,h,g),y[i.url]=2})))}function h(a,b){function c(a,c){if(a){if(e(a))c||(j=function(){var a=[].slice.call(arguments);k.apply(this,a),l()}),g(a,j,b,0,h);else if(Object(a)===a)for(n in m=function(){var b=0,c;for(c in a)a.hasOwnProperty(c)&&b++;return b}(),a)a.hasOwnProperty(n)&&(!c&&!--m&&(d(j)?j=function(){var a=[].slice.call(arguments);k.apply(this,a),l()}:j[n]=function(a){return function(){var b=[].slice.call(arguments);a&&a.apply(this,b),l()}}(k[n])),g(a[n],j,b,n,h))}else!c&&l()}var h=!!a.test,i=a.load||a.both,j=a.callback||f,k=j,l=a.complete||f,m,n;c(h?a.yep:a.nope,!!i),i&&c(i)}var i,j,l=this.yepnope.loader;if(e(a))g(a,0,l,0);else if(w(a))for(i=0;i<a.length;i++)j=a[i],e(j)?g(j,0,l,0):w(j)?B(j):Object(j)===j&&h(j,l);else Object(a)===a&&h(a,l)},B.addPrefix=function(a,b){z[a]=b},B.addFilter=function(a){x.push(a)},B.errorTimeout=1e4,null==b.readyState&&b.addEventListener&&(b.readyState="loading",b.addEventListener("DOMContentLoaded",A=function(){b.removeEventListener("DOMContentLoaded",A,0),b.readyState="complete"},0)),a.yepnope=k(),a.yepnope.executeStack=h,a.yepnope.injectJs=function(a,c,d,e,i,j){var k=b.createElement("script"),l,o,e=e||B.errorTimeout;k.src=a;for(o in d)k.setAttribute(o,d[o]);c=j?h:c||f,k.onreadystatechange=k.onload=function(){!l&&g(k.readyState)&&(l=1,c(),k.onload=k.onreadystatechange=null)},m(function(){l||(l=1,c(1))},e),i?k.onload():n.parentNode.insertBefore(k,n)},a.yepnope.injectCss=function(a,c,d,e,g,i){var e=b.createElement("link"),j,c=i?h:c||f;e.href=a,e.rel="stylesheet",e.type="text/css";for(j in d)e.setAttribute(j,d[j]);g||(n.parentNode.insertBefore(e,n),m(c,0))}}(this,document),Modernizr.load=function(){yepnope.apply(window,[].slice.call(arguments,0))};
-
-/*! matchMedia() polyfill - Test a CSS media type/query in JS. Authors & copyright (c) 2012: Scott Jehl, Paul Irish, Nicholas Zakas. Dual MIT/BSD license */
-/*! NOTE: If you're already including a window.matchMedia polyfill via Modernizr or otherwise, you don't need this part */
-window.matchMedia=window.matchMedia||(function(e,f){var c,a=e.documentElement,b=a.firstElementChild||a.firstChild,d=e.createElement("body"),g=e.createElement("div");g.id="mq-test-1";g.style.cssText="position:absolute;top:-100em";d.style.background="none";d.appendChild(g);return function(h){g.innerHTML='&shy;<style media="'+h+'"> #mq-test-1 { width: 42px; }</style>';a.insertBefore(d,b);c=g.offsetWidth==42;a.removeChild(d);return{matches:c,media:h}}})(document);
-
-/*! Respond.js v1.1.0: min/max-width media query polyfill. (c) Scott Jehl. MIT/GPLv2 Lic. j.mp/respondjs  */
-(function(e){e.respond={};respond.update=function(){};respond.mediaQueriesSupported=e.matchMedia&&e.matchMedia("only all").matches;if(respond.mediaQueriesSupported){return}var w=e.document,s=w.documentElement,i=[],k=[],q=[],o={},h=30,f=w.getElementsByTagName("head")[0]||s,g=w.getElementsByTagName("base")[0],b=f.getElementsByTagName("link"),d=[],a=function(){var D=b,y=D.length,B=0,A,z,C,x;for(;B<y;B++){A=D[B],z=A.href,C=A.media,x=A.rel&&A.rel.toLowerCase()==="stylesheet";if(!!z&&x&&!o[z]){if(A.styleSheet&&A.styleSheet.rawCssText){m(A.styleSheet.rawCssText,z,C);o[z]=true}else{if((!/^([a-zA-Z:]*\/\/)/.test(z)&&!g)||z.replace(RegExp.$1,"").split("/")[0]===e.location.host){d.push({href:z,media:C})}}}}u()},u=function(){if(d.length){var x=d.shift();n(x.href,function(y){m(y,x.href,x.media);o[x.href]=true;u()})}},m=function(I,x,z){var G=I.match(/@media[^\{]+\{([^\{\}]*\{[^\}\{]*\})+/gi),J=G&&G.length||0,x=x.substring(0,x.lastIndexOf("/")),y=function(K){return K.replace(/(url\()['"]?([^\/\)'"][^:\)'"]+)['"]?(\))/g,"$1"+x+"$2$3")},A=!J&&z,D=0,C,E,F,B,H;if(x.length){x+="/"}if(A){J=1}for(;D<J;D++){C=0;if(A){E=z;k.push(y(I))}else{E=G[D].match(/@media *([^\{]+)\{([\S\s]+?)$/)&&RegExp.$1;k.push(RegExp.$2&&y(RegExp.$2))}B=E.split(",");H=B.length;for(;C<H;C++){F=B[C];i.push({media:F.split("(")[0].match(/(only\s+)?([a-zA-Z]+)\s?/)&&RegExp.$2||"all",rules:k.length-1,hasquery:F.indexOf("(")>-1,minw:F.match(/\(min\-width:[\s]*([\s]*[0-9\.]+)(px|em)[\s]*\)/)&&parseFloat(RegExp.$1)+(RegExp.$2||""),maxw:F.match(/\(max\-width:[\s]*([\s]*[0-9\.]+)(px|em)[\s]*\)/)&&parseFloat(RegExp.$1)+(RegExp.$2||"")})}}j()},l,r,v=function(){var z,A=w.createElement("div"),x=w.body,y=false;A.style.cssText="position:absolute;font-size:1em;width:1em";if(!x){x=y=w.createElement("body");x.style.background="none"}x.appendChild(A);s.insertBefore(x,s.firstChild);z=A.offsetWidth;if(y){s.removeChild(x)}else{x.removeChild(A)}z=p=parseFloat(z);return z},p,j=function(I){var x="clientWidth",B=s[x],H=w.compatMode==="CSS1Compat"&&B||w.body[x]||B,D={},G=b[b.length-1],z=(new Date()).getTime();if(I&&l&&z-l<h){clearTimeout(r);r=setTimeout(j,h);return}else{l=z}for(var E in i){var K=i[E],C=K.minw,J=K.maxw,A=C===null,L=J===null,y="em";if(!!C){C=parseFloat(C)*(C.indexOf(y)>-1?(p||v()):1)}if(!!J){J=parseFloat(J)*(J.indexOf(y)>-1?(p||v()):1)}if(!K.hasquery||(!A||!L)&&(A||H>=C)&&(L||H<=J)){if(!D[K.media]){D[K.media]=[]}D[K.media].push(k[K.rules])}}for(var E in q){if(q[E]&&q[E].parentNode===f){f.removeChild(q[E])}}for(var E in D){var M=w.createElement("style"),F=D[E].join("\n");M.type="text/css";M.media=E;f.insertBefore(M,G.nextSibling);if(M.styleSheet){M.styleSheet.cssText=F}else{M.appendChild(w.createTextNode(F))}q.push(M)}},n=function(x,z){var y=c();if(!y){return}y.open("GET",x,true);y.onreadystatechange=function(){if(y.readyState!=4||y.status!=200&&y.status!=304){return}z(y.responseText)};if(y.readyState==4){return}y.send(null)},c=(function(){var x=false;try{x=new XMLHttpRequest()}catch(y){x=new ActiveXObject("Microsoft.XMLHTTP")}return function(){return x}})();a();respond.update=a;function t(){j(true)}if(e.addEventListener){e.addEventListener("resize",t,false)}else{if(e.attachEvent){e.attachEvent("onresize",t)}}})(this);
\ No newline at end of file
diff --git a/hack/CONTRIBUTORS.md b/hack/CONTRIBUTORS.md
new file mode 120000
index 0000000..44fcc63
--- /dev/null
+++ b/hack/CONTRIBUTORS.md
@@ -0,0 +1 @@
+../CONTRIBUTING.md
\ No newline at end of file
diff --git a/hack/MAINTAINERS b/hack/MAINTAINERS
index 1887dfc..afd13f8 100644
--- a/hack/MAINTAINERS
+++ b/hack/MAINTAINERS
@@ -1 +1,2 @@
 Solomon Hykes <solomon@dotcloud.com> (@shykes)
+Tianon Gravi <admwiggin@gmail.com> (@tianon)
diff --git a/hack/MAINTAINERS.md b/hack/MAINTAINERS.md
new file mode 100644
index 0000000..b109c32
--- /dev/null
+++ b/hack/MAINTAINERS.md
@@ -0,0 +1,78 @@
+# The Docker maintainer manual
+
+## Introduction
+
+Dear maintainer. Thank you for investing the time and energy to help make Docker as
+useful as possible. Maintaining a project is difficult, sometimes unrewarding work.
+Sure, you will get to contribute cool features to the project. But most of your time
+will be spent reviewing, cleaning up, documenting, andswering questions, justifying
+design decisions - while everyone has all the fun! But remember - the quality of the
+maintainers work is what distinguishes the good projects from the great.
+So please be proud of your work, even the unglamourous parts, and encourage a culture
+of appreciation and respect for *every* aspect of improving the project - not just the
+hot new features.
+
+This document is a manual for maintainers old and new. It explains what is expected of
+maintainers, how they should work, and what tools are available to them.
+
+This is a living document - if you see something out of date or missing, speak up!
+
+
+## What are a maintainer's responsibility?
+
+It is every maintainer's responsibility to:
+
+* 1) Expose a clear roadmap for improving their component.
+* 2) Deliver prompt feedback and decisions on pull requests.
+* 3) Be available to anyone with questions, bug reports, criticism etc. on their component. This includes irc, github requests and the mailing list.
+* 4) Make sure their component respects the philosophy, design and roadmap of the project.
+
+
+## How are decisions made?
+
+Short answer: with pull requests to the docker repository.
+
+Docker is an open-source project with an open design philosophy. This means that the repository is the source of truth for EVERY aspect of the project,
+including its philosophy, design, roadmap and APIs. *If it's part of the project, it's in the repo. It's in the repo, it's part of the project.*
+
+As a result, all decisions can be expressed as changes to the repository. An implementation change is a change to the source code. An API change is a change to
+the API specification. A philosophy change is a change to the philosophy manifesto. And so on.
+
+All decisions affecting docker, big and small, follow the same 3 steps:
+
+* Step 1: Open a pull request. Anyone can do this.
+
+* Step 2: Discuss the pull request. Anyone can do this.
+
+* Step 3: Accept or refuse a pull request. The relevant maintainer does this (see below "Who decides what?")
+
+
+## Who decides what?
+
+So all decisions are pull requests, and the relevant maintainer makes the decision by accepting or refusing the pull request.
+But how do we identify the relevant maintainer for a given pull request?
+
+Docker follows the timeless, highly efficient and totally unfair system known as [Benevolent dictator for life](http://en.wikipedia.org/wiki/Benevolent_Dictator_for_Life),
+with yours truly, Solomon Hykes, in the role of BDFL.
+This means that all decisions are made by default by me. Since making every decision myself would be highly unscalable, in practice decisions are spread across multiple maintainers.
+
+The relevant maintainer for a pull request is assigned in 3 steps:
+
+* Step 1: Determine the subdirectory affected by the pull request. This might be src/registry, docs/source/api, or any other part of the repo.
+
+* Step 2: Find the MAINTAINERS file which affects this directory. If the directory itself does not have a MAINTAINERS file, work your way up the the repo hierarchy until you find one.
+
+* Step 3: The first maintainer listed is the primary maintainer. The pull request is assigned to him. He may assign it to other listed maintainers, at his discretion.
+
+
+### I'm a maintainer, should I make pull requests too?
+
+Yes. Nobody should ever push to master directly. All changes should be made through a pull request.
+
+### Who assigns maintainers?
+
+Solomon.
+
+### How is this process changed?
+
+Just like everything else: by making a pull request :)
diff --git a/hack/PACKAGERS.md b/hack/PACKAGERS.md
index 776ed47..ab8d74d 100644
--- a/hack/PACKAGERS.md
+++ b/hack/PACKAGERS.md
@@ -116,6 +116,7 @@
 * iptables version 1.4 or later
 * The lxc utility scripts (http://lxc.sourceforge.net) version 0.8 or later.
 * Git version 1.7 or later 
+* XZ Utils 4.9 or later
 
 ## Kernel dependencies
 
diff --git a/hack/README.md b/hack/README.md
new file mode 100644
index 0000000..207a2aa
--- /dev/null
+++ b/hack/README.md
@@ -0,0 +1,24 @@
+# Hacking on Docker
+
+The hack/ directory holds information and tools for everyone involved in the process of creating and
+distributing Docker, specifically:
+
+## Guides
+
+If you're a *contributor* or aspiring contributor, you should read CONTRIBUTORS.md.
+
+If you're a *maintainer* or aspiring maintainer, you should read MAINTAINERS.md.
+
+If you're a *packager* or aspiring packager, you should read PACKAGERS.md.
+
+If you're a maintainer in charge of a *release*, you should read RELEASE-CHECKLIST.md.
+
+## Roadmap
+
+A high-level roadmap is available at ROADMAP.md.
+
+
+## Build tools
+
+make.sh is the primary build tool for docker. It is used for compiling the official binary,
+running the test suite, and pushing releases.
diff --git a/hack/README.rst b/hack/README.rst
deleted file mode 100644
index c693e1f..0000000
--- a/hack/README.rst
+++ /dev/null
@@ -1,28 +0,0 @@
-This directory contains material helpful for hacking on docker.
-
-make hack
-=========
-
-Set up an Ubuntu 12.04 virtual machine for developers including kernel 3.8
-go1.1 and buildbot. The environment is setup in a way that can be used through
-the usual go workflow and/or the root Makefile. You can either edit on
-your host, or inside the VM (using make ssh-dev) and run and test docker
-inside the VM.
-
-dependencies: vagrant, virtualbox packages and python package requests
-
-
-Buildbot
-~~~~~~~~
-
-Buildbot is a continuous integration system designed to automate the
-build/test cycle. By automatically rebuilding and testing the tree each time
-something has changed, build problems are pinpointed quickly, before other
-developers are inconvenienced by the failure.
-
-When running 'make hack' at the docker root directory, it spawns a virtual
-machine in the background running a buildbot instance and adds a git
-post-commit hook that automatically run docker tests for you each time you
-commit in your local docker repository.
-
-You can check your buildbot instance at http://192.168.33.21:8010/waterfall
diff --git a/hack/RELEASE-CHECKLIST.md b/hack/RELEASE-CHECKLIST.md
index f01bb3a..5f873c6 100644
--- a/hack/RELEASE-CHECKLIST.md
+++ b/hack/RELEASE-CHECKLIST.md
@@ -55,11 +55,15 @@
 
 ### 4. Run all tests
 
-```bash
-go test
-```
+FIXME
 
-### 5. Commit and create a pull request
+### 5. Test the docs
+
+Make sure that your tree includes documentation for any modified or
+new features, syntax or semantic changes. Instructions for building
+the docs are in ``docs/README.md``
+
+### 6. Commit and create a pull request to the "release" branch
 
 ```bash
 git add CHANGELOG.md
@@ -67,12 +71,12 @@
 git push origin bump_$VERSION
 ```
 
-### 6. Get 2 other maintainers to validate the pull request
+### 7. Get 2 other maintainers to validate the pull request
 
-### 7. Merge the pull request and apply tags
+### 8. Merge the pull request and apply tags
 
 ```bash
-git checkout master
+git checkout release
 git merge bump_$VERSION
 git tag -a v$VERSION # Don't forget the v!
 git tag -f -a latest
@@ -80,20 +84,27 @@
 git push --tags
 ```
 
-### 8. Publish binaries
+Merging the pull request to the release branch will automatically
+update the documentation on the "latest" revision of the docs. You
+should see the updated docs 5-10 minutes after the merge. The docs
+will appear on http://docs.docker.io/. For more information about
+documentation releases, see ``docs/README.md``
+
+### 9. Publish binaries
 
 To run this you will need access to the release credentials.
 Get them from [the infrastructure maintainers](
 https://github.com/dotcloud/docker/blob/master/hack/infrastructure/MAINTAINERS).
 
 ```bash
-docker build -t releasedocker .
+docker build -t docker .
 docker run  \
 	-e AWS_S3_BUCKET=get-nightly.docker.io \
 	-e AWS_ACCESS_KEY=$(cat ~/.aws/access_key) \
 	-e AWS_SECRET_KEY=$(cat ~/.aws/secret_key) \
 	-e GPG_PASSPHRASE=supersecretsesame \
-	releasedocker
+	docker
+	hack/release.sh
 ```
 
 It will build and upload the binaries on the specified bucket (you should
@@ -101,6 +112,6 @@
 switch to get.docker.io).
 
 
-### 9. Rejoice!
+### 10. Rejoice!
 
 Congratulations! You're done.
diff --git a/hack/Vagrantfile b/hack/Vagrantfile
deleted file mode 100644
index 0ac0736..0000000
--- a/hack/Vagrantfile
+++ /dev/null
@@ -1,36 +0,0 @@
-# -*- mode: ruby -*-
-# vi: set ft=ruby :
-
-BOX_NAME = "ubuntu-dev"
-BOX_URI = "http://files.vagrantup.com/precise64.box"
-VM_IP = "192.168.33.21"
-USER = "vagrant"
-GOPATH = "/data/docker"
-DOCKER_PATH = "#{GOPATH}/src/github.com/dotcloud/docker"
-CFG_PATH = "#{DOCKER_PATH}/hack/environment"
-BUILDBOT_PATH = "/data/buildbot"
-
-Vagrant::Config.run do |config|
-  # Setup virtual machine box
-  config.vm.box = BOX_NAME
-  config.vm.box_url = BOX_URI
-  config.vm.share_folder "v-data", DOCKER_PATH, "#{File.dirname(__FILE__)}/.."
-  config.vm.network :hostonly, VM_IP
-  # Stop if deployment has been done
-  config.vm.provision :shell, :inline => "[ ! -f /usr/bin/git ]"
-  # Touch for makefile
-  pkg_cmd = "touch #{DOCKER_PATH}; "
-  # Install docker dependencies
-  pkg_cmd << "apt-get update -qq; apt-get install -y python-software-properties; " \
-    "add-apt-repository -y ppa:dotcloud/docker-golang/ubuntu; apt-get update -qq; " \
-    "apt-get install -y linux-image-generic-lts-raring lxc git aufs-tools golang-stable make; " \
-    "chown -R #{USER}.#{USER} #{GOPATH}; " \
-    "install -m 0664 #{CFG_PATH}/bash_profile /home/#{USER}/.bash_profile"
-  config.vm.provision :shell, :inline => pkg_cmd
-  # Deploy buildbot CI
-  pkg_cmd = "apt-get install -q -y python-dev python-pip supervisor; " \
-    "pip install -q -r #{CFG_PATH}/requirements.txt; " \
-    "chown #{USER}.#{USER} /data; cd /data; " \
-    "#{CFG_PATH}/setup.sh #{USER} #{GOPATH} #{DOCKER_PATH} #{CFG_PATH} #{BUILDBOT_PATH}"
-  config.vm.provision :shell, :inline => pkg_cmd
-end
diff --git a/hack/environment/README.rst b/hack/environment/README.rst
deleted file mode 100644
index da5c885..0000000
--- a/hack/environment/README.rst
+++ /dev/null
@@ -1 +0,0 @@
-Files used to setup the developer virtual machine
diff --git a/hack/environment/bash_profile b/hack/environment/bash_profile
deleted file mode 100644
index 77eed79..0000000
--- a/hack/environment/bash_profile
+++ /dev/null
@@ -1,19 +0,0 @@
-# ~/.bash_profile : executed by the command interpreter for login shells.
-
-# if running bash
-if [ -n "$BASH_VERSION" ]; then
-    # include .bashrc if it exists
-    if [ -f "$HOME/.bashrc" ]; then
-        . "$HOME/.bashrc"
-    fi
-fi
-
-# set PATH so it includes user's private bin if it exists
-[ -d "$HOME/bin" ] && PATH="$HOME/bin:$PATH"
-
-docker=/data/docker/src/github.com/dotcloud/docker
-[ -d $docker ] && cd $docker
-
-export GOPATH=/data/docker
-export PATH=$PATH:$GOPATH/bin
-
diff --git a/hack/environment/buildbot.conf b/hack/environment/buildbot.conf
deleted file mode 100644
index b162f4e..0000000
--- a/hack/environment/buildbot.conf
+++ /dev/null
@@ -1,18 +0,0 @@
-[program:buildmaster]
-command=su vagrant -c "buildbot start master"
-directory=/data/buildbot
-chown= root:root
-redirect_stderr=true
-stdout_logfile=/var/log/supervisor/buildbot-master.log
-stderr_logfile=/var/log/supervisor/buildbot-master.log
-
-[program:buildworker]
-command=buildslave start slave
-directory=/data/buildbot
-chown= root:root
-redirect_stderr=true
-stdout_logfile=/var/log/supervisor/buildbot-slave.log
-stderr_logfile=/var/log/supervisor/buildbot-slave.log
-
-[group:buildbot]
-programs=buildmaster,buildworker
diff --git a/hack/environment/master.cfg b/hack/environment/master.cfg
deleted file mode 100644
index fad023b..0000000
--- a/hack/environment/master.cfg
+++ /dev/null
@@ -1,43 +0,0 @@
-import os
-from buildbot.buildslave import BuildSlave
-from buildbot.schedulers.forcesched import ForceScheduler
-from buildbot.config import BuilderConfig
-from buildbot.process.factory import BuildFactory
-from buildbot.steps.shell import ShellCommand
-from buildbot.status import html
-from buildbot.status.web import authz, auth
-
-PORT_WEB = 8010         # Buildbot webserver port
-PORT_MASTER = 9989      # Port where buildbot master listen buildworkers
-TEST_USER = 'buildbot'  # Credential to authenticate build triggers
-TEST_PWD = 'docker'     # Credential to authenticate build triggers
-BUILDER_NAME = 'docker'
-BUILDPASSWORD = 'pass-docker'  # Credential to authenticate buildworkers
-GOPATH = '/data/docker'
-DOCKER_PATH = '{0}/src/github.com/dotcloud/docker'.format(GOPATH)
-
-c = BuildmasterConfig = {}
-
-c['title'] = "Docker"
-c['titleURL'] = "waterfall"
-c['buildbotURL'] = "http://localhost:{0}/".format(PORT_WEB)
-c['db'] = {'db_url':"sqlite:///state.sqlite"}
-c['slaves'] = [BuildSlave('buildworker', BUILDPASSWORD)]
-c['slavePortnum'] = PORT_MASTER
-
-c['schedulers'] = [ForceScheduler(name='trigger',builderNames=[BUILDER_NAME])]
-
-# Docker test command
-test_cmd = "GOPATH={0} make -C {1} test".format(GOPATH,DOCKER_PATH)
-
-# Builder
-factory = BuildFactory()
-factory.addStep(ShellCommand(description='Docker',logEnviron=False,
-    usePTY=True,command=test_cmd))
-c['builders'] = [BuilderConfig(name=BUILDER_NAME,slavenames=['buildworker'],
-    factory=factory)]
-
-# Status
-authz_cfg=authz.Authz(auth=auth.BasicAuth([(TEST_USER,TEST_PWD)]),
-    forceBuild='auth')
-c['status'] = [html.WebStatus(http_port=PORT_WEB, authz=authz_cfg)]
diff --git a/hack/environment/post-commit b/hack/environment/post-commit
deleted file mode 100755
index 0173fe5..0000000
--- a/hack/environment/post-commit
+++ /dev/null
@@ -1,21 +0,0 @@
-#!/usr/bin/env python
-
-'''Trigger buildbot docker test build
-
-   post-commit git hook designed to automatically trigger buildbot on
-   the provided vagrant docker VM.'''
-
-import requests
-
-USERNAME = 'buildbot'
-PASSWORD = 'docker'
-BASE_URL = 'http://localhost:8010'
-path = lambda s: BASE_URL + '/' + s
-
-try:
-    session = requests.session()
-    session.post(path('login'),data={'username':USERNAME,'passwd':PASSWORD})
-    session.post(path('builders/docker/force'),
-        data={'forcescheduler':'trigger','reason':'Test commit'})
-except:
-    pass
diff --git a/hack/environment/requirements.txt b/hack/environment/requirements.txt
deleted file mode 100644
index 0e451b0..0000000
--- a/hack/environment/requirements.txt
+++ /dev/null
@@ -1,6 +0,0 @@
-sqlalchemy<=0.7.9
-sqlalchemy-migrate>=0.7.2
-buildbot==0.8.7p1
-buildbot_slave==0.8.7p1
-nose==1.2.1
-requests==1.1.0
diff --git a/hack/environment/setup.sh b/hack/environment/setup.sh
deleted file mode 100755
index 7aa06a5..0000000
--- a/hack/environment/setup.sh
+++ /dev/null
@@ -1,45 +0,0 @@
-#!/bin/bash
-
-# Setup of buildbot configuration. Package installation is being done by
-# Vagrantfile
-# Dependencies: buildbot, buildbot-slave, supervisor
-
-USER=$1
-GOPATH=$2
-DOCKER_PATH=$3
-CFG_PATH=$4
-BUILDBOT_PATH=$5
-SLAVE_NAME="buildworker"
-SLAVE_SOCKET="localhost:9989"
-BUILDBOT_PWD="pass-docker"
-IP=$(sed -nE 's/VM_IP = "(.+)"/\1/p' ${DOCKER_PATH}/hack/Vagrantfile)
-export PATH="/bin:sbin:/usr/bin:/usr/sbin:/usr/local/bin"
-
-function run { su $USER -c "$1"; }
-
-# Exit if buildbot has already been installed
-[ -d "$BUILDBOT_PATH" ] && exit 0
-
-# Setup buildbot
-run "mkdir -p $BUILDBOT_PATH"
-cd $BUILDBOT_PATH
-run "buildbot create-master master"
-run "cp $CFG_PATH/master.cfg master"
-run "sed -i 's/localhost/$IP/' master/master.cfg"
-run "sed -i -E 's#(GOPATH = ).+#\1\"$GOPATH\"#' master/master.cfg"
-run "sed -i -E 's#(DOCKER_PATH = ).+#\1\"$DOCKER_PATH\"#' master/master.cfg"
-run "buildslave create-slave slave $SLAVE_SOCKET $SLAVE_NAME $BUILDBOT_PWD"
-
-# Allow buildbot subprocesses (docker tests) to properly run in containers,
-# in particular with docker -u
-run "sed -i 's/^umask = None/umask = 000/' slave/buildbot.tac"
-
-# Setup supervisor
-cp $CFG_PATH/buildbot.conf /etc/supervisor/conf.d/buildbot.conf
-sed -i -E "s/^chmod=0700.+/chmod=0770\nchown=root:$USER/" /etc/supervisor/supervisord.conf
-kill -HUP $(pgrep -f "/usr/bin/python /usr/bin/supervisord")
-
-# Add git hook
-cp $CFG_PATH/post-commit $DOCKER_PATH/.git/hooks
-sed -i "s/localhost/$IP/" $DOCKER_PATH/.git/hooks/post-commit
-
diff --git a/hack/infrastructure/docker-ci.rst b/hack/infrastructure/docker-ci.rst
index abb8492..0be530d 100644
--- a/hack/infrastructure/docker-ci.rst
+++ b/hack/infrastructure/docker-ci.rst
@@ -1,5 +1,38 @@
-docker-ci github pull request
-=============================
+docker-ci
+=========
+
+docker-ci is our buildbot continuous integration server,
+building and testing docker, hosted on EC2 and reachable at
+http://docker-ci.dotcloud.com
+
+
+Deployment
+==========
+
+# Load AWS credentials
+export AWS_ACCESS_KEY_ID=''
+export AWS_SECRET_ACCESS_KEY=''
+export AWS_KEYPAIR_NAME=''
+export AWS_SSH_PRIVKEY=''
+
+# Load buildbot credentials and config
+export BUILDBOT_PWD=''
+export IRC_PWD=''
+export IRC_CHANNEL='docker-dev'
+export SMTP_USER=''
+export SMTP_PWD=''
+export EMAIL_RCP=''
+
+# Load registry test credentials
+export REGISTRY_USER=''
+export REGISTRY_PWD=''
+
+cd docker/testing
+vagrant up --provider=aws
+
+
+github pull request
+===================
 
 The entire docker pull request test workflow is event driven by github. Its
 usage is fully automatic and the results are logged in docker-ci.dotcloud.com
@@ -13,3 +46,11 @@
 can understand the PR data github sends to it. Originally PR #1603 (ee64e099e0)
 implemented this capability. Also we added a new scheduler to exclusively filter
 PRs. and the 'pullrequest' builder to rebase the PR on top of master and test it.
+
+
+nighthly release
+================
+
+The nightly release process is done by buildbot, running a DinD container that downloads
+the docker repository and builds the release container. The resulting docker
+binary is then tested, and if everything is fine, the release is done.
diff --git a/hack/infrastructure/docker-ci/Dockerfile b/hack/infrastructure/docker-ci/Dockerfile
new file mode 100644
index 0000000..3ac8d90
--- /dev/null
+++ b/hack/infrastructure/docker-ci/Dockerfile
@@ -0,0 +1,43 @@
+# VERSION:        0.22
+# DOCKER-VERSION  0.6.3
+# AUTHOR:         Daniel Mizyrycki <daniel@dotcloud.com>
+# DESCRIPTION:    Deploy docker-ci on Amazon EC2
+# COMMENTS:
+#     CONFIG_JSON is an environment variable json string loaded as:
+#
+# export CONFIG_JSON='
+#     { "AWS_TAG":             "EC2_instance_name",
+#       "AWS_ACCESS_KEY":      "EC2_access_key",
+#       "AWS_SECRET_KEY":      "EC2_secret_key",
+#       "DOCKER_CI_PUB":       "$(cat docker-ci_ssh_public_key.pub)",
+#       "DOCKER_CI_KEY":       "$(cat docker-ci_ssh_private_key.key)",
+#       "BUILDBOT_PWD":        "Buildbot_server_password",
+#       "IRC_PWD":             "Buildbot_IRC_password",
+#       "SMTP_USER":           "SMTP_server_user",
+#       "SMTP_PWD":            "SMTP_server_password",
+#       "PKG_ACCESS_KEY":      "Docker_release_S3_bucket_access_key",
+#       "PKG_SECRET_KEY":      "Docker_release_S3_bucket_secret_key",
+#       "PKG_GPG_PASSPHRASE":  "Docker_release_gpg_passphrase",
+#       "INDEX_AUTH":          "Index_encripted_user_password",
+#       "REGISTRY_USER":       "Registry_test_user",
+#       "REGISTRY_PWD":        "Registry_test_password",
+#       "REGISTRY_BUCKET":     "Registry_S3_bucket_name",
+#       "REGISTRY_ACCESS_KEY": "Registry_S3_bucket_access_key",
+#       "REGISTRY_SECRET_KEY": "Registry_S3_bucket_secret_key",
+#       "IRC_CHANNEL":         "Buildbot_IRC_channel",
+#       "EMAIL_RCP":           "Buildbot_mailing_receipient" }'
+#
+#
+# TO_BUILD:   docker build -t docker-ci .
+# TO_DEPLOY:  docker run -e CONFIG_JSON="${CONFIG_JSON}" docker-ci
+
+from ubuntu:12.04
+
+run echo 'deb http://archive.ubuntu.com/ubuntu precise main universe' > /etc/apt/sources.list
+run apt-get update; apt-get install -y python2.7 python-dev python-pip ssh rsync less vim
+run pip install boto fabric
+
+# Add deployment code and set default container command
+add . /docker-ci
+cmd "/docker-ci/deployment.py"
+
diff --git a/packaging/MAINTAINERS b/hack/infrastructure/docker-ci/MAINTAINERS
similarity index 100%
rename from packaging/MAINTAINERS
rename to hack/infrastructure/docker-ci/MAINTAINERS
diff --git a/hack/infrastructure/docker-ci/README.rst b/hack/infrastructure/docker-ci/README.rst
new file mode 100644
index 0000000..33a1435
--- /dev/null
+++ b/hack/infrastructure/docker-ci/README.rst
@@ -0,0 +1,26 @@
+=======
+testing
+=======
+
+This directory contains docker-ci testing related files.
+
+
+Buildbot
+========
+
+Buildbot is a continuous integration system designed to automate the
+build/test cycle. By automatically rebuilding and testing the tree each time
+something has changed, build problems are pinpointed quickly, before other
+developers are inconvenienced by the failure.
+
+We are running buildbot in Amazon's EC2 to verify docker passes all
+tests when commits get pushed to the master branch and building
+nightly releases using Docker in Docker awesome implementation made
+by Jerome Petazzoni.
+
+https://github.com/jpetazzo/dind
+
+Docker's buildbot instance is at http://docker-ci.dotcloud.com/waterfall
+
+For deployment instructions, please take a look at
+hack/infrastructure/docker-ci/Dockerfile
diff --git a/hack/infrastructure/docker-ci/buildbot/README.rst b/hack/infrastructure/docker-ci/buildbot/README.rst
new file mode 100644
index 0000000..6cbcb8d
--- /dev/null
+++ b/hack/infrastructure/docker-ci/buildbot/README.rst
@@ -0,0 +1 @@
+Buildbot configuration and setup files
diff --git a/testing/buildbot/buildbot.conf b/hack/infrastructure/docker-ci/buildbot/buildbot.conf
similarity index 100%
rename from testing/buildbot/buildbot.conf
rename to hack/infrastructure/docker-ci/buildbot/buildbot.conf
diff --git a/testing/buildbot/github.py b/hack/infrastructure/docker-ci/buildbot/github.py
similarity index 85%
rename from testing/buildbot/github.py
rename to hack/infrastructure/docker-ci/buildbot/github.py
index b0fe98a..ff6b6c6 100644
--- a/testing/buildbot/github.py
+++ b/hack/infrastructure/docker-ci/buildbot/github.py
@@ -86,12 +86,16 @@
                 the http request object
         """
         payload = json.loads(request.args['payload'][0])
-	if 'pull_request' in payload:
-	    user = payload['repository']['owner']['login']
-	    repo = payload['repository']['name']
-            repo_url = payload['repository']['html_url']
-	else:
-	    user = payload['repository']['owner']['name']
+        import urllib,datetime
+        fname = str(datetime.datetime.now()).replace(' ','_').replace(':','-')[:19]
+        open('github_{0}.json'.format(fname),'w').write(json.dumps(json.loads(urllib.unquote(request.args['payload'][0])), sort_keys = True, indent = 2))
+
+        if 'pull_request' in payload:
+            user = payload['pull_request']['user']['login']
+            repo = payload['pull_request']['head']['repo']['name']
+            repo_url = payload['pull_request']['head']['repo']['html_url']
+        else:
+            user = payload['repository']['owner']['name']
             repo = payload['repository']['name']
             repo_url = payload['repository']['url']
         project = request.args.get('project', None)
@@ -115,7 +119,7 @@
                 Hook.
         """
         changes = []
-	
+
         newrev = payload['after'] if 'after' in payload else payload['pull_request']['head']['sha']
         refname = payload['ref'] if 'ref' in payload else payload['pull_request']['head']['ref']
 
@@ -130,10 +134,13 @@
             log.msg("Branch `%s' deleted, ignoring" % branch)
             return []
         else: 
-	    if 'pull_request' in payload:
-		changes = [{
-		    'category'   : 'github_pullrequest',
-                    'who'        : user,
+            if 'pull_request' in payload:
+                if payload['action'] == 'closed':
+                    log.msg("PR#{} closed, ignoring".format(payload['number']))
+                    return []
+                changes = [{
+                    'category'   : 'github_pullrequest',
+                    'who'        : '{0} - PR#{1}'.format(user,payload['number']),
                     'files'      : [],
                     'comments'   : payload['pull_request']['title'], 
                     'revision'   : newrev,
@@ -142,7 +149,7 @@
                     'revlink'    : '{0}/commit/{1}'.format(repo_url,newrev),
                     'repository' : repo_url,
                     'project'  : project  }] 
-		return changes
+                return changes
             for commit in payload['commits']:
                 files = []
                 if 'added' in commit:
@@ -166,4 +173,3 @@
                     project  = project)
                 changes.append(chdict) 
             return changes
-        
diff --git a/testing/buildbot/master.cfg b/hack/infrastructure/docker-ci/buildbot/master.cfg
similarity index 70%
rename from testing/buildbot/master.cfg
rename to hack/infrastructure/docker-ci/buildbot/master.cfg
index 7962fe9..78a9f71 100644
--- a/testing/buildbot/master.cfg
+++ b/hack/infrastructure/docker-ci/buildbot/master.cfg
@@ -20,7 +20,8 @@
 BUILDER_NAME = 'docker'
 GITHUB_DOCKER = 'github.com/dotcloud/docker'
 BUILDBOT_PATH = '/data/buildbot'
-DOCKER_PATH = '/data/docker'
+DOCKER_PATH = '/go/src/github.com/dotcloud/docker'
+DOCKER_CI_PATH = '/docker-ci'
 BUILDER_PATH = '/data/buildbot/slave/{0}/build'.format(BUILDER_NAME)
 PULL_REQUEST_PATH = '/data/buildbot/slave/pullrequest/build'
 
@@ -45,49 +46,41 @@
 
 # Schedulers
 c['schedulers'] = [ForceScheduler(name='trigger', builderNames=[BUILDER_NAME,
-    'index','registry','coverage'])]
+    'index','registry','coverage','nightlyrelease'])]
 c['schedulers'] += [SingleBranchScheduler(name="all",
     change_filter=filter.ChangeFilter(branch='master'), treeStableTimer=None,
     builderNames=[BUILDER_NAME])]
 c['schedulers'] += [SingleBranchScheduler(name='pullrequest',
     change_filter=filter.ChangeFilter(category='github_pullrequest'), treeStableTimer=None,
     builderNames=['pullrequest'])]
-c['schedulers'] += [Nightly(name='daily', branch=None, builderNames=['coverage'],
-    hour=0, minute=30)]
+c['schedulers'] += [Nightly(name='daily', branch=None, builderNames=['nightlyrelease'],
+    hour=7, minute=00)]
 c['schedulers'] += [Nightly(name='every4hrs', branch=None, builderNames=['registry','index'],
     hour=range(0,24,4), minute=15)]
 
 # Builders
 # Docker commit test
 factory = BuildFactory()
-factory.addStep(ShellCommand(description='Docker',logEnviron=False,usePTY=True,
-    command=["sh", "-c", Interpolate("cd ..; rm -rf build; mkdir build; "
-    "cp -r {2}-dependencies/src {0}; export GOPATH={0}; go get {3}; cd {1}; "
-    "git reset --hard %(src::revision)s; go test -v".format(
-    BUILDER_PATH, BUILDER_PATH+'/src/'+GITHUB_DOCKER, DOCKER_PATH, GITHUB_DOCKER))]))
-c['builders'] = [BuilderConfig(name=BUILDER_NAME,slavenames=['buildworker'],
+factory.addStep(ShellCommand(description='Docker', logEnviron=False,
+    usePTY=True, command=['sh', '-c', Interpolate(
+    '{0}/docker-test/test_docker.sh %(src::revision)s'.format(DOCKER_CI_PATH))]))
+c['builders'] = [BuilderConfig(name='docker',slavenames=['buildworker'],
     factory=factory)]
 
 # Docker pull request test
 factory = BuildFactory()
-factory.addStep(ShellCommand(description='pull_request',logEnviron=False,usePTY=True,
-    command=["sh", "-c", Interpolate("cd ..; rm -rf build; mkdir build; "
-    "cp -r {2}-dependencies/src {0}; export GOPATH={0}; go get {3}; cd {1}; "
-    "git fetch %(src::repository)s %(src::branch)s:PR-%(src::branch)s; "
-    "git checkout %(src::revision)s; git rebase master; go test -v".format(
-    PULL_REQUEST_PATH, PULL_REQUEST_PATH+'/src/'+GITHUB_DOCKER, DOCKER_PATH, GITHUB_DOCKER))]))
+factory.addStep(ShellCommand(description='pull_request', logEnviron=False,
+    usePTY=True, command=['sh', '-c', Interpolate(
+    '{0}/docker-test/test_docker.sh %(src::revision)s %(src::repository)s'
+    ' %(src::branch)s'.format(DOCKER_CI_PATH))]))
 c['builders'] += [BuilderConfig(name='pullrequest',slavenames=['buildworker'],
     factory=factory)]
 
 # Docker coverage test
-coverage_cmd = ('GOPATH=`pwd` go get -d github.com/dotcloud/docker\n'
-    'GOPATH=`pwd` go get github.com/axw/gocov/gocov\n'
-    'sudo -E GOPATH=`pwd` ./bin/gocov test -deps -exclude-goroot -v'
-    ' -exclude github.com/gorilla/context,github.com/gorilla/mux,github.com/kr/pty,'
-    'code.google.com/p/go.net/websocket github.com/dotcloud/docker | ./bin/gocov report')
 factory = BuildFactory()
-factory.addStep(ShellCommand(description='Coverage',logEnviron=False,usePTY=True,
-    command=coverage_cmd))
+factory.addStep(ShellCommand(description='Coverage', logEnviron=False,
+    usePTY=True, command='{0}/docker-coverage/coverage-docker.sh'.format(
+    DOCKER_CI_PATH)))
 c['builders'] += [BuilderConfig(name='coverage',slavenames=['buildworker'],
     factory=factory)]
 
@@ -95,8 +88,8 @@
 factory = BuildFactory()
 factory.addStep(ShellCommand(description='registry', logEnviron=False,
     command='. {0}/master/credentials.cfg; '
-    '{1}/testing/functionaltests/test_registry.sh'.format(BUILDBOT_PATH,
-    DOCKER_PATH), usePTY=True))
+    '/docker-ci/functionaltests/test_registry.sh'.format(BUILDBOT_PATH),
+    usePTY=True))
 c['builders'] += [BuilderConfig(name='registry',slavenames=['buildworker'],
     factory=factory)]
 
@@ -109,6 +102,14 @@
 c['builders'] += [BuilderConfig(name='index',slavenames=['buildworker'],
     factory=factory)]
 
+# Docker nightly release
+nightlyrelease_cmd = ('docker run -i -t -privileged -lxc-conf=lxc.aa_profile=unconfined'
+    ' -e AWS_S3_BUCKET=test.docker.io dockerbuilder')
+factory = BuildFactory()
+factory.addStep(ShellCommand(description='NightlyRelease',logEnviron=False,usePTY=True,
+    command=nightlyrelease_cmd))
+c['builders'] += [BuilderConfig(name='nightlyrelease',slavenames=['buildworker'],
+    factory=factory)]
 
 # Status
 authz_cfg = authz.Authz(auth=auth.BasicAuth([(TEST_USER, TEST_PWD)]),
diff --git a/testing/buildbot/requirements.txt b/hack/infrastructure/docker-ci/buildbot/requirements.txt
similarity index 100%
rename from testing/buildbot/requirements.txt
rename to hack/infrastructure/docker-ci/buildbot/requirements.txt
diff --git a/testing/buildbot/setup.sh b/hack/infrastructure/docker-ci/buildbot/setup.sh
similarity index 72%
rename from testing/buildbot/setup.sh
rename to hack/infrastructure/docker-ci/buildbot/setup.sh
index 99e4f7f..c7e89c4 100755
--- a/testing/buildbot/setup.sh
+++ b/hack/infrastructure/docker-ci/buildbot/setup.sh
@@ -6,16 +6,22 @@
 
 USER=$1
 CFG_PATH=$2
-BUILDBOT_PWD=$3
-IRC_PWD=$4
-IRC_CHANNEL=$5
-SMTP_USER=$6
-SMTP_PWD=$7
-EMAIL_RCP=$8
+DOCKER_PATH=$3
+BUILDBOT_PWD=$4
+IRC_PWD=$5
+IRC_CHANNEL=$6
+SMTP_USER=$7
+SMTP_PWD=$8
+EMAIL_RCP=$9
+REGISTRY_USER=${10}
+REGISTRY_PWD=${11}
+REGISTRY_BUCKET=${12}
+REGISTRY_ACCESS_KEY=${13}
+REGISTRY_SECRET_KEY=${14}
 BUILDBOT_PATH="/data/buildbot"
-DOCKER_PATH="/data/docker"
 SLAVE_NAME="buildworker"
 SLAVE_SOCKET="localhost:9989"
+
 export PATH="/bin:sbin:/usr/bin:/usr/sbin:/usr/local/bin"
 
 function run { su $USER -c "$1"; }
@@ -35,6 +41,10 @@
 run "sed -i -E 's#(SMTP_PWD = ).+#\1\"$SMTP_PWD\"#' master/master.cfg"
 run "sed -i -E 's#(EMAIL_RCP = ).+#\1\"$EMAIL_RCP\"#' master/master.cfg"
 run "buildslave create-slave slave $SLAVE_SOCKET $SLAVE_NAME $BUILDBOT_PWD"
+run "echo 'export DOCKER_CREDS=\"$REGISTRY_USER:$REGISTRY_PWD\"' > $BUILDBOT_PATH/master/credentials.cfg"
+run "echo 'export S3_BUCKET=\"$REGISTRY_BUCKET\"' >> $BUILDBOT_PATH/master/credentials.cfg"
+run "echo 'export S3_ACCESS_KEY=\"$REGISTRY_ACCESS_KEY\"' >> $BUILDBOT_PATH/master/credentials.cfg"
+run "echo 'export S3_SECRET_KEY=\"$REGISTRY_SECRET_KEY\"' >> $BUILDBOT_PATH/master/credentials.cfg"
 
 # Patch github webstatus to capture pull requests
 cp $CFG_PATH/github.py /usr/local/lib/python2.7/dist-packages/buildbot/status/web/hooks
diff --git a/hack/infrastructure/docker-ci/deployment.py b/hack/infrastructure/docker-ci/deployment.py
new file mode 100755
index 0000000..0ff21ce
--- /dev/null
+++ b/hack/infrastructure/docker-ci/deployment.py
@@ -0,0 +1,155 @@
+#!/usr/bin/env python
+
+import os, sys, re, json, base64
+from boto.ec2.connection import EC2Connection
+from subprocess import call
+from fabric import api
+from fabric.api import cd, run, put, sudo
+from os import environ as env
+from time import sleep
+
+# Remove SSH private key as it needs more processing
+CONFIG = json.loads(re.sub(r'("DOCKER_CI_KEY".+?"(.+?)",)','',
+    env['CONFIG_JSON'], flags=re.DOTALL))
+
+# Populate environment variables
+for key in CONFIG:
+    env[key] = CONFIG[key]
+
+# Load SSH private key
+env['DOCKER_CI_KEY'] = re.sub('^.+"DOCKER_CI_KEY".+?"(.+?)".+','\\1',
+    env['CONFIG_JSON'],flags=re.DOTALL)
+
+
+AWS_TAG = env.get('AWS_TAG','docker-ci')
+AWS_KEY_NAME = 'dotcloud-dev'       # Same as CONFIG_JSON['DOCKER_CI_PUB']
+AWS_AMI = 'ami-d582d6bc'            # Ubuntu 13.04
+AWS_REGION = 'us-east-1'
+AWS_TYPE = 'm1.small'
+AWS_SEC_GROUPS = 'gateway'
+AWS_IMAGE_USER = 'ubuntu'
+DOCKER_PATH = '/go/src/github.com/dotcloud/docker'
+DOCKER_CI_PATH = '/docker-ci'
+CFG_PATH = '{}/buildbot'.format(DOCKER_CI_PATH)
+
+
+class AWS_EC2:
+    '''Amazon EC2'''
+    def __init__(self, access_key, secret_key):
+        '''Set default API parameters'''
+        self.handler = EC2Connection(access_key, secret_key)
+    def create_instance(self, tag, instance_type):
+        reservation = self.handler.run_instances(**instance_type)
+        instance = reservation.instances[0]
+        sleep(10)
+        while instance.state != 'running':
+            sleep(5)
+            instance.update()
+            print "Instance state: %s" % (instance.state)
+        instance.add_tag("Name",tag)
+        print "instance %s done!" % (instance.id)
+        return instance.ip_address
+    def get_instances(self):
+        return self.handler.get_all_instances()
+    def get_tags(self):
+        return dict([(i.instances[0].id, i.instances[0].tags['Name'])
+            for i in self.handler.get_all_instances() if i.instances[0].tags])
+    def del_instance(self, instance_id):
+        self.handler.terminate_instances(instance_ids=[instance_id])
+
+
+def json_fmt(data):
+    '''Format json output'''
+    return json.dumps(data, sort_keys = True, indent = 2)
+
+
+# Create EC2 API handler
+ec2 = AWS_EC2(env['AWS_ACCESS_KEY'], env['AWS_SECRET_KEY'])
+
+# Stop processing if AWS_TAG exists on EC2
+if AWS_TAG in ec2.get_tags().values():
+    print ('Instance: {} already deployed. Not further processing.'
+        .format(AWS_TAG))
+    exit(1)
+
+ip = ec2.create_instance(AWS_TAG, {'image_id':AWS_AMI, 'instance_type':AWS_TYPE,
+    'security_groups':[AWS_SEC_GROUPS], 'key_name':AWS_KEY_NAME})
+
+# Wait 30 seconds for the machine to boot
+sleep(30)
+
+# Create docker-ci ssh private key so docker-ci docker container can communicate
+# with its EC2 instance
+os.makedirs('/root/.ssh')
+open('/root/.ssh/id_rsa','w').write(env['DOCKER_CI_KEY'])
+os.chmod('/root/.ssh/id_rsa',0600)
+open('/root/.ssh/config','w').write('StrictHostKeyChecking no\n')
+
+api.env.host_string = ip
+api.env.user = AWS_IMAGE_USER
+api.env.key_filename = '/root/.ssh/id_rsa'
+
+# Correct timezone
+sudo('echo "America/Los_Angeles" >/etc/timezone')
+sudo('dpkg-reconfigure --frontend noninteractive tzdata')
+
+# Load public docker-ci key
+sudo("echo '{}' >> /root/.ssh/authorized_keys".format(env['DOCKER_CI_PUB']))
+
+# Create docker nightly release credentials file
+credentials = {
+    'AWS_ACCESS_KEY': env['PKG_ACCESS_KEY'],
+    'AWS_SECRET_KEY': env['PKG_SECRET_KEY'],
+    'GPG_PASSPHRASE': env['PKG_GPG_PASSPHRASE'],
+    'INDEX_AUTH': env['INDEX_AUTH']}
+open(DOCKER_CI_PATH + '/nightlyrelease/release_credentials.json', 'w').write(
+    base64.b64encode(json.dumps(credentials)))
+
+# Transfer docker
+sudo('mkdir -p ' + DOCKER_CI_PATH)
+sudo('chown {}.{} {}'.format(AWS_IMAGE_USER, AWS_IMAGE_USER, DOCKER_CI_PATH))
+call('/usr/bin/rsync -aH {} {}@{}:{}'.format(DOCKER_CI_PATH, AWS_IMAGE_USER, ip,
+    os.path.dirname(DOCKER_CI_PATH)), shell=True)
+
+# Install Docker and Buildbot dependencies
+sudo('addgroup docker')
+sudo('usermod -a -G docker ubuntu')
+sudo('mkdir /mnt/docker; ln -s /mnt/docker /var/lib/docker')
+sudo('wget -q -O - https://get.docker.io/gpg | apt-key add -')
+sudo('echo deb https://get.docker.io/ubuntu docker main >'
+    ' /etc/apt/sources.list.d/docker.list')
+sudo('echo -e "deb http://archive.ubuntu.com/ubuntu raring main universe\n'
+    'deb http://us.archive.ubuntu.com/ubuntu/ raring-security main universe\n"'
+    ' > /etc/apt/sources.list; apt-get update')
+sudo('DEBIAN_FRONTEND=noninteractive apt-get install -q -y wget python-dev'
+    ' python-pip supervisor git mercurial linux-image-extra-$(uname -r)'
+    ' aufs-tools make libfontconfig libevent-dev')
+sudo('wget -O - https://go.googlecode.com/files/go1.1.2.linux-amd64.tar.gz | '
+    'tar -v -C /usr/local -xz; ln -s /usr/local/go/bin/go /usr/bin/go')
+sudo('GOPATH=/go go get -d github.com/dotcloud/docker')
+sudo('pip install -r {}/requirements.txt'.format(CFG_PATH))
+
+# Install docker and testing dependencies
+sudo('apt-get install -y -q lxc-docker')
+sudo('curl -s https://phantomjs.googlecode.com/files/'
+    'phantomjs-1.9.1-linux-x86_64.tar.bz2 | tar jx -C /usr/bin'
+    ' --strip-components=2 phantomjs-1.9.1-linux-x86_64/bin/phantomjs')
+
+#### FIXME. Temporarily install docker with proper apparmor handling
+sudo('stop docker')
+sudo('wget -q -O /usr/bin/docker http://test.docker.io/test/docker')
+sudo('start docker')
+
+# Build docker-ci containers
+sudo('cd {}; docker build -t docker .'.format(DOCKER_PATH))
+sudo('cd {}/nightlyrelease; docker build -t dockerbuilder .'.format(
+    DOCKER_CI_PATH))
+
+# Setup buildbot
+sudo('mkdir /data')
+sudo('{0}/setup.sh root {0} {1} {2} {3} {4} {5} {6} {7} {8} {9} {10}'
+    ' {11} {12}'.format(CFG_PATH, DOCKER_PATH, env['BUILDBOT_PWD'],
+    env['IRC_PWD'], env['IRC_CHANNEL'], env['SMTP_USER'],
+    env['SMTP_PWD'], env['EMAIL_RCP'], env['REGISTRY_USER'],
+    env['REGISTRY_PWD'], env['REGISTRY_BUCKET'], env['REGISTRY_ACCESS_KEY'],
+    env['REGISTRY_SECRET_KEY']))
diff --git a/hack/infrastructure/docker-ci/docker-coverage/coverage-docker.sh b/hack/infrastructure/docker-ci/docker-coverage/coverage-docker.sh
new file mode 100755
index 0000000..2ca3b6e
--- /dev/null
+++ b/hack/infrastructure/docker-ci/docker-coverage/coverage-docker.sh
@@ -0,0 +1,32 @@
+#!/bin/bash
+
+set -x
+# Generate a random string of $1 characters
+function random {
+    cat /dev/urandom | tr -cd 'a-f0-9' | head -c $1
+}
+
+# Compute test paths
+BASE_PATH=`pwd`/test_docker_$(random 12)
+DOCKER_PATH=$BASE_PATH/go/src/github.com/dotcloud/docker
+export GOPATH=$BASE_PATH/go:$DOCKER_PATH/vendor
+
+# Fetch latest master
+mkdir -p $DOCKER_PATH
+cd $DOCKER_PATH
+git init .
+git fetch -q http://github.com/dotcloud/docker master
+git reset --hard FETCH_HEAD
+
+# Fetch go coverage
+cd $BASE_PATH/go
+GOPATH=$BASE_PATH/go go get github.com/axw/gocov/gocov
+sudo -E GOPATH=$GOPATH ./bin/gocov test -deps -exclude-goroot -v\
+ -exclude github.com/gorilla/context,github.com/gorilla/mux,github.com/kr/pty,\
+code.google.com/p/go.net/websocket,github.com/dotcloud/tar\
+ github.com/dotcloud/docker | ./bin/gocov report; exit_status=$?
+
+# Cleanup testing directory
+rm -rf $BASE_PATH
+
+exit $exit_status
diff --git a/hack/infrastructure/docker-ci/docker-test/test_docker.sh b/hack/infrastructure/docker-ci/docker-test/test_docker.sh
new file mode 100755
index 0000000..46075b7
--- /dev/null
+++ b/hack/infrastructure/docker-ci/docker-test/test_docker.sh
@@ -0,0 +1,35 @@
+#!/bin/bash
+
+set -x
+COMMIT=${1-HEAD}
+REPO=${2-http://github.com/dotcloud/docker}
+BRANCH=${3-master}
+
+# Generate a random string of $1 characters
+function random {
+    cat /dev/urandom | tr -cd 'a-f0-9' | head -c $1
+}
+
+# Compute test paths
+BASE_PATH=`pwd`/test_docker_$(random 12)
+DOCKER_PATH=$BASE_PATH/go/src/github.com/dotcloud/docker
+export GOPATH=$BASE_PATH/go:$DOCKER_PATH/vendor
+
+# Fetch latest master
+mkdir -p $DOCKER_PATH
+cd $DOCKER_PATH
+git init .
+git fetch -q http://github.com/dotcloud/docker master
+git reset --hard FETCH_HEAD
+
+# Merge commit
+git fetch -q "$REPO" "$BRANCH"
+git merge --no-edit $COMMIT || exit 1
+
+# Test commit
+go test -v; exit_status=$?
+
+# Cleanup testing directory
+rm -rf $BASE_PATH
+
+exit $exit_status
diff --git a/testing/functionaltests/test_index.py b/hack/infrastructure/docker-ci/functionaltests/test_index.py
similarity index 100%
rename from testing/functionaltests/test_index.py
rename to hack/infrastructure/docker-ci/functionaltests/test_index.py
diff --git a/hack/infrastructure/docker-ci/functionaltests/test_registry.sh b/hack/infrastructure/docker-ci/functionaltests/test_registry.sh
new file mode 100755
index 0000000..8bcd355
--- /dev/null
+++ b/hack/infrastructure/docker-ci/functionaltests/test_registry.sh
@@ -0,0 +1,26 @@
+#!/bin/sh
+
+set -x
+
+# Cleanup
+rm -rf docker-registry
+
+# Setup the environment
+export SETTINGS_FLAVOR=test
+export DOCKER_REGISTRY_CONFIG=config_test.yml
+
+# Get latest docker registry
+git clone -q https://github.com/dotcloud/docker-registry.git
+cd docker-registry
+
+# Get dependencies
+pip install -q -r requirements.txt
+pip install -q -r test-requirements.txt
+pip install -q tox
+
+# Run registry tests
+tox || exit 1
+export PYTHONPATH=$(pwd)/docker-registry
+python -m unittest discover -p s3.py -s test || exit 1
+python -m unittest discover -p workflow.py -s test
+
diff --git a/hack/infrastructure/docker-ci/nightlyrelease/Dockerfile b/hack/infrastructure/docker-ci/nightlyrelease/Dockerfile
new file mode 100644
index 0000000..8eb0b72
--- /dev/null
+++ b/hack/infrastructure/docker-ci/nightlyrelease/Dockerfile
@@ -0,0 +1,37 @@
+# VERSION:        1.2
+# DOCKER-VERSION  0.6.3
+# AUTHOR:         Daniel Mizyrycki <daniel@dotcloud.com>
+# DESCRIPTION:    Build docker nightly release using Docker in Docker.
+# REFERENCES:     This code reuses the excellent implementation of docker in docker
+#                 made by Jerome Petazzoni.  https://github.com/jpetazzo/dind
+# COMMENTS:
+#   release_credentials.json is a base64 json encoded file containing:
+#       { "AWS_ACCESS_KEY": "Test_docker_AWS_S3_bucket_id",
+#         "AWS_SECRET_KEY='Test_docker_AWS_S3_bucket_key'
+#         "GPG_PASSPHRASE='Test_docker_GPG_passphrase_signature'
+#         "INDEX_AUTH='Encripted_index_authentication' }
+# TO_BUILD:       docker build -t dockerbuilder .
+# TO_RELEASE:     docker run -i -t -privileged -lxc-conf="lxc.aa_profile = unconfined" -e AWS_S3_BUCKET="test.docker.io" dockerbuilder
+
+from docker
+maintainer Daniel Mizyrycki <daniel@dotcloud.com>
+
+# Add docker dependencies and downloading packages
+run echo 'deb http://archive.ubuntu.com/ubuntu precise main universe' > /etc/apt/sources.list
+run apt-get update; apt-get install -y -q wget python2.7
+
+# Add production docker binary
+run wget -q -O /usr/bin/docker http://get.docker.io/builds/Linux/x86_64/docker-latest; chmod +x /usr/bin/docker
+
+#### FIXME. Temporarily install docker with proper apparmor handling
+run wget -q -O /usr/bin/docker http://test.docker.io/test/docker; chmod +x /usr/bin/docker
+
+# Add proto docker builder
+add ./dockerbuild /usr/bin/dockerbuild
+run chmod +x /usr/bin/dockerbuild
+
+# Add release credentials
+add ./release_credentials.json /root/release_credentials.json
+
+# Launch build process in a container
+cmd dockerbuild
diff --git a/hack/infrastructure/docker-ci/nightlyrelease/dockerbuild b/hack/infrastructure/docker-ci/nightlyrelease/dockerbuild
new file mode 100644
index 0000000..857e0f8
--- /dev/null
+++ b/hack/infrastructure/docker-ci/nightlyrelease/dockerbuild
@@ -0,0 +1,45 @@
+#!/bin/bash
+
+# Variables AWS_ACCESS_KEY, AWS_SECRET_KEY, PG_PASSPHRASE and INDEX_AUTH
+# are decoded from /root/release_credentials.json
+# Variable AWS_S3_BUCKET is passed to the environment from docker run -e
+
+# Enable debugging
+set -x
+
+# Fetch docker master branch
+rm -rf  /go/src/github.com/dotcloud/docker
+cd /
+git clone -q http://github.com/dotcloud/docker /go/src/github.com/dotcloud/docker
+cd /go/src/github.com/dotcloud/docker
+
+echo FIXME. Temporarily add Jerome changeset with proper apparmor handling
+git fetch  http://github.com/jpetazzo/docker escape-apparmor-confinement:escape-apparmor-confinement
+git rebase --onto master master escape-apparmor-confinement
+
+# Launch docker daemon using dind inside the container
+./hack/dind /usr/bin/docker -d &
+sleep 5
+
+# Add an uncommitted change to generate a timestamped release
+date > timestamp
+
+# Build the docker package using /Dockerfile
+docker build -t docker .
+
+# Run Docker unittests binary and Ubuntu package
+docker run -privileged -lxc-conf=lxc.aa_profile=unconfined docker hack/make.sh || exit 1
+
+# Turn debug off to load credentials from the environment
+set +x
+eval $(cat /root/release_credentials.json  | python -c '
+import sys,json,base64;
+d=json.loads(base64.b64decode(sys.stdin.read()));
+exec("""for k in d: print "export {0}=\\"{1}\\"".format(k,d[k])""")')
+echo '{"https://index.docker.io/v1/":{"auth":"'$INDEX_AUTH'","email":"engineering@dotcloud.com"}}' > /.dockercfg
+set -x
+
+# Push docker nightly
+echo docker run -i -t -privileged -e AWS_S3_BUCKET=$AWS_S3_BUCKET -e AWS_ACCESS_KEY=XXXXX -e AWS_SECRET_KEY=XXXXX -e GPG_PASSPHRASE=XXXXX release  hack/release.sh
+set +x
+docker run -i -t -privileged -e AWS_S3_BUCKET=$AWS_S3_BUCKET -e AWS_ACCESS_KEY=$AWS_ACCESS_KEY -e AWS_SECRET_KEY=$AWS_SECRET_KEY -e GPG_PASSPHRASE=$GPG_PASSPHRASE  release  hack/release.sh
diff --git a/hack/infrastructure/docker-ci/nightlyrelease/release_credentials.json b/hack/infrastructure/docker-ci/nightlyrelease/release_credentials.json
new file mode 100644
index 0000000..ed6d53e
--- /dev/null
+++ b/hack/infrastructure/docker-ci/nightlyrelease/release_credentials.json
@@ -0,0 +1 @@
+eyAiQVdTX0FDQ0VTU19LRVkiOiAiIiwKICAiQVdTX1NFQ1JFVF9LRVkiOiAiIiwKICAiR1BHX1BBU1NQSFJBU0UiOiAiIiwKICAiSU5ERVhfQVVUSCI6ICIiIH0=
diff --git a/hack/infrastructure/docker-ci/report/Dockerfile b/hack/infrastructure/docker-ci/report/Dockerfile
new file mode 100644
index 0000000..32600c4
--- /dev/null
+++ b/hack/infrastructure/docker-ci/report/Dockerfile
@@ -0,0 +1,28 @@
+# VERSION:        0.22
+# DOCKER-VERSION  0.6.3
+# AUTHOR:         Daniel Mizyrycki <daniel@dotcloud.com>
+# DESCRIPTION:    Generate docker-ci daily report
+# COMMENTS:       The build process is initiated by deployment.py
+                  Report configuration is passed through ./credentials.json at
+#                 deployment time.
+# TO_BUILD:       docker build -t report .
+# TO_DEPLOY:      docker run report
+
+from ubuntu:12.04
+maintainer Daniel Mizyrycki <daniel@dotcloud.com>
+
+env PYTHONPATH /report
+
+
+# Add report dependencies
+run echo 'deb http://archive.ubuntu.com/ubuntu precise main universe' > \
+    /etc/apt/sources.list
+run apt-get update; apt-get install -y python2.7 python-pip ssh rsync
+
+# Set San Francisco timezone
+run echo "America/Los_Angeles" >/etc/timezone
+run dpkg-reconfigure --frontend noninteractive tzdata
+
+# Add report code and set default container command
+add . /report
+cmd "/report/report.py"
diff --git a/hack/infrastructure/docker-ci/report/deployment.py b/hack/infrastructure/docker-ci/report/deployment.py
new file mode 100755
index 0000000..d5efb4a
--- /dev/null
+++ b/hack/infrastructure/docker-ci/report/deployment.py
@@ -0,0 +1,130 @@
+#!/usr/bin/env python
+
+'''Deploy docker-ci report container on Digital Ocean.
+Usage:
+    export CONFIG_JSON='
+        { "DROPLET_NAME":        "Digital_Ocean_dropplet_name",
+          "DO_CLIENT_ID":        "Digital_Ocean_client_id",
+          "DO_API_KEY":          "Digital_Ocean_api_key",
+          "DOCKER_KEY_ID":       "Digital_Ocean_ssh_key_id",
+          "DOCKER_CI_KEY_PATH":  "docker-ci_private_key_path",
+          "DOCKER_CI_PUB":       "$(cat docker-ci_ssh_public_key.pub)",
+          "DOCKER_CI_ADDRESS"    "user@docker-ci_fqdn_server",
+          "SMTP_USER":           "SMTP_server_user",
+          "SMTP_PWD":            "SMTP_server_password",
+          "EMAIL_SENDER":        "Buildbot_mailing_sender",
+          "EMAIL_RCP":           "Buildbot_mailing_receipient" }'
+    python deployment.py
+'''
+
+import re, json, requests, base64
+from fabric import api
+from fabric.api import cd, run, put, sudo
+from os import environ as env
+from time import sleep
+from datetime import datetime
+
+# Populate environment variables
+CONFIG = json.loads(env['CONFIG_JSON'])
+for key in CONFIG:
+    env[key] = CONFIG[key]
+
+# Load DOCKER_CI_KEY
+env['DOCKER_CI_KEY'] = open(env['DOCKER_CI_KEY_PATH']).read()
+
+DROPLET_NAME = env.get('DROPLET_NAME','report')
+TIMEOUT = 120            # Seconds before timeout droplet creation
+IMAGE_ID = 894856        # Docker on Ubuntu 13.04
+REGION_ID = 4            # New York 2
+SIZE_ID = 66             # memory 512MB
+DO_IMAGE_USER = 'root'   # Image user on Digital Ocean
+API_URL = 'https://api.digitalocean.com/'
+
+
+class digital_ocean():
+
+    def __init__(self, key, client):
+        '''Set default API parameters'''
+        self.key = key
+        self.client = client
+        self.api_url = API_URL
+
+    def api(self, cmd_path, api_arg={}):
+        '''Make api call'''
+        api_arg.update({'api_key':self.key, 'client_id':self.client})
+        resp = requests.get(self.api_url + cmd_path, params=api_arg).text
+        resp = json.loads(resp)
+        if resp['status'] != 'OK':
+            raise Exception(resp['error_message'])
+        return resp
+
+    def droplet_data(self, name):
+        '''Get droplet data'''
+        data = self.api('droplets')
+        data = [droplet for droplet in data['droplets']
+            if droplet['name'] == name]
+        return data[0] if data else {}
+
+def json_fmt(data):
+    '''Format json output'''
+    return json.dumps(data, sort_keys = True, indent = 2)
+
+
+do = digital_ocean(env['DO_API_KEY'], env['DO_CLIENT_ID'])
+
+# Get DROPLET_NAME data
+data = do.droplet_data(DROPLET_NAME)
+
+# Stop processing if DROPLET_NAME exists on Digital Ocean
+if data:
+    print ('Droplet: {} already deployed. Not further processing.'
+        .format(DROPLET_NAME))
+    exit(1)
+
+# Create droplet
+do.api('droplets/new', {'name':DROPLET_NAME, 'region_id':REGION_ID,
+    'image_id':IMAGE_ID, 'size_id':SIZE_ID,
+    'ssh_key_ids':[env['DOCKER_KEY_ID']]})
+
+# Wait for droplet to be created.
+start_time = datetime.now()
+while (data.get('status','') != 'active' and (
+ datetime.now()-start_time).seconds < TIMEOUT):
+    data = do.droplet_data(DROPLET_NAME)
+    print data['status']
+    sleep(3)
+
+# Wait for the machine to boot
+sleep(15)
+
+# Get droplet IP
+ip = str(data['ip_address'])
+print 'droplet: {}    ip: {}'.format(DROPLET_NAME, ip)
+
+api.env.host_string = ip
+api.env.user = DO_IMAGE_USER
+api.env.key_filename = env['DOCKER_CI_KEY_PATH']
+
+# Correct timezone
+sudo('echo "America/Los_Angeles" >/etc/timezone')
+sudo('dpkg-reconfigure --frontend noninteractive tzdata')
+
+# Load JSON_CONFIG environment for Dockerfile
+CONFIG_JSON= base64.b64encode(
+    '{{"DOCKER_CI_PUB":     "{DOCKER_CI_PUB}",'
+    '  "DOCKER_CI_KEY":     "{DOCKER_CI_KEY}",'
+    '  "DOCKER_CI_ADDRESS": "{DOCKER_CI_ADDRESS}",'
+    '  "SMTP_USER":         "{SMTP_USER}",'
+    '  "SMTP_PWD":          "{SMTP_PWD}",'
+    '  "EMAIL_SENDER":      "{EMAIL_SENDER}",'
+    '  "EMAIL_RCP":         "{EMAIL_RCP}"}}'.format(**env))
+
+run('mkdir -p /data/report')
+put('./', '/data/report')
+with cd('/data/report'):
+    run('chmod 700 report.py')
+    run('echo "{}" > credentials.json'.format(CONFIG_JSON))
+    run('docker build -t report .')
+    run('rm credentials.json')
+    run("echo -e '30 09 * * * /usr/bin/docker run report\n' |"
+        " /usr/bin/crontab -")
diff --git a/hack/infrastructure/docker-ci/report/report.py b/hack/infrastructure/docker-ci/report/report.py
new file mode 100755
index 0000000..7018cab
--- /dev/null
+++ b/hack/infrastructure/docker-ci/report/report.py
@@ -0,0 +1,145 @@
+#!/usr/bin/python
+
+'''CONFIG_JSON is a json encoded string base64 environment variable. It is used
+to clone docker-ci database, generate docker-ci report and submit it by email.
+CONFIG_JSON data comes from the file /report/credentials.json inserted in this
+container by deployment.py:
+
+{ "DOCKER_CI_PUB":       "$(cat docker-ci_ssh_public_key.pub)",
+  "DOCKER_CI_KEY":       "$(cat docker-ci_ssh_private_key.key)",
+  "DOCKER_CI_ADDRESS":   "user@docker-ci_fqdn_server",
+  "SMTP_USER":           "SMTP_server_user",
+  "SMTP_PWD":            "SMTP_server_password",
+  "EMAIL_SENDER":        "Buildbot_mailing_sender",
+  "EMAIL_RCP":           "Buildbot_mailing_receipient" }  '''
+
+import os, re, json, sqlite3, datetime, base64
+import smtplib
+from datetime import timedelta
+from subprocess import call
+from os import environ as env
+
+TODAY = datetime.date.today()
+
+# Load credentials to the environment
+env['CONFIG_JSON'] = base64.b64decode(open('/report/credentials.json').read())
+
+# Remove SSH private key as it needs more processing
+CONFIG = json.loads(re.sub(r'("DOCKER_CI_KEY".+?"(.+?)",)','',
+    env['CONFIG_JSON'], flags=re.DOTALL))
+
+# Populate environment variables
+for key in CONFIG:
+    env[key] = CONFIG[key]
+
+# Load SSH private key
+env['DOCKER_CI_KEY'] = re.sub('^.+"DOCKER_CI_KEY".+?"(.+?)".+','\\1',
+    env['CONFIG_JSON'],flags=re.DOTALL)
+
+# Prevent rsync to validate host on first connection to docker-ci
+os.makedirs('/root/.ssh')
+open('/root/.ssh/id_rsa','w').write(env['DOCKER_CI_KEY'])
+os.chmod('/root/.ssh/id_rsa',0600)
+open('/root/.ssh/config','w').write('StrictHostKeyChecking no\n')
+
+
+# Sync buildbot database from docker-ci
+call('rsync {}:/data/buildbot/master/state.sqlite .'.format(
+    env['DOCKER_CI_ADDRESS']), shell=True)
+
+class SQL:
+    def __init__(self, database_name):
+        sql = sqlite3.connect(database_name)
+        # Use column names as keys for fetchall rows
+        sql.row_factory = sqlite3.Row
+        sql = sql.cursor()
+        self.sql = sql
+
+    def query(self,query_statement):
+        return self.sql.execute(query_statement).fetchall()
+
+sql = SQL("state.sqlite")
+
+
+class Report():
+
+    def __init__(self,period='',date=''):
+        self.data = []
+        self.period = 'date' if not period else period
+        self.date = str(TODAY) if not date else date
+        self.compute()
+
+    def compute(self):
+        '''Compute report'''
+        if self.period == 'week':
+            self.week_report(self.date)
+        else:
+            self.date_report(self.date)
+
+
+    def date_report(self,date):
+        '''Create a date test report'''
+        builds = []
+        # Get a queryset with all builds from date
+        rows = sql.query('SELECT * FROM builds JOIN buildrequests'
+            ' WHERE builds.brid=buildrequests.id and'
+            ' date(start_time, "unixepoch", "localtime") = "{0}"'
+            ' GROUP BY number'.format(date))
+        build_names = sorted(set([row['buildername'] for row in rows]))
+        # Create a report build line for a given build
+        for build_name in build_names:
+            tried = len([row['buildername']
+                for row in rows if row['buildername'] == build_name])
+            fail_tests = [row['buildername'] for row in rows if (
+                row['buildername'] == build_name and row['results'] != 0)]
+            fail = len(fail_tests)
+            fail_details = ''
+            fail_pct = int(100.0*fail/tried) if  tried != 0 else 100
+            builds.append({'name': build_name, 'tried': tried, 'fail': fail,
+                'fail_pct': fail_pct, 'fail_details':fail_details})
+        if builds:
+            self.data.append({'date': date, 'builds': builds})
+
+
+    def week_report(self,date):
+        '''Add the week's date test reports to report.data'''
+        date = datetime.datetime.strptime(date,'%Y-%m-%d').date()
+        last_monday = date - datetime.timedelta(days=date.weekday())
+        week_dates = [last_monday + timedelta(days=x) for x in range(7,-1,-1)]
+        for date in week_dates:
+            self.date_report(str(date))
+
+    def render_text(self):
+        '''Return rendered report in text format'''
+        retval = ''
+        fail_tests = {}
+        for builds in self.data:
+            retval += 'Test date: {0}\n'.format(builds['date'],retval)
+            table = ''
+            for build in builds['builds']:
+                table += ('Build {name:15}   Tried: {tried:4}   '
+                    ' Failures: {fail:4} ({fail_pct}%)\n'.format(**build))
+                if build['name'] in fail_tests:
+                    fail_tests[build['name']] += build['fail_details']
+                else:
+                    fail_tests[build['name']] = build['fail_details']
+            retval += '{0}\n'.format(table)
+            retval += '\n    Builds failing'
+            for fail_name in fail_tests:
+                retval += '\n' + fail_name + '\n'
+                for (fail_id,fail_url,rn_tests,nr_errors,log_errors,
+                 tracelog_errors) in fail_tests[fail_name]:
+                    retval += fail_url + '\n'
+            retval += '\n\n'
+        return retval
+
+
+# Send email
+smtp_from = env['EMAIL_SENDER']
+subject = '[docker-ci] Daily report for {}'.format(str(TODAY))
+msg = "From: {}\r\nTo: {}\r\nSubject: {}\r\n\r\n".format(
+    smtp_from, env['EMAIL_RCP'], subject)
+msg = msg + Report('week').render_text()
+server = smtplib.SMTP_SSL('smtp.mailgun.org')
+server.login(env['SMTP_USER'], env['SMTP_PWD'])
+server.sendmail(smtp_from, env['EMAIL_RCP'], msg)
diff --git a/hack/infrastructure/overview.md b/hack/infrastructure/overview.md
new file mode 100644
index 0000000..592c9b0
--- /dev/null
+++ b/hack/infrastructure/overview.md
@@ -0,0 +1,103 @@
+# Docker Server Overview
+This is an overview of the Docker infrastructure
+
+## Docker Git Repo
+The Docker source code lives on github.com under the dotCloud account.
+https://github.com/dotcloud/docker
+
+## DNS
+We are using dyn.com for our DNS server for the docker.io domain. 
+It is using the dotCloud account.
+
+### DNS Redirect
+We have a DNS redirect in dyn.com that will automatically redirect 
+docker.io to www.docker.io
+
+## email
+Email is sent via  dotCloud account on MailGun.com
+
+## CDN
+We are using a CDN in front of some of the docker.io domains to help improve
+proformance. The CDN is Cloudflare, using a Pro account. 
+
+*This is currently disabled due to an issue with slow performance during pull
+in some regions of the world.*
+
+### CDN Domains
+- www.docker.io
+- test.docker.io
+- registry-1.docker.io
+- debug.docker.io
+- cdn-registry-1.docker.io
+
+## edge-docker.dotcloud.com
+All of the Docker applications that live on dotCloud go through their own
+load balancer, and this is where SSL is terminated as well.
+
+## www.docker.io
+This is hosted under the docker account on dotCloud's PaaS. 
+
+### Source Code
+The source code for the website lives here:
+https://github.com/dotcloud/www.docker.io
+
+## Docker Registry
+The registry is where the image data is store.
+
+### URL:
+- registry-1.docker.io
+- cdn-registry-1.docker.io
+
+There are two urls, one is behind a CDN the other isn't this is because when
+you pull, you pull from the CDN url, to help with pull speeds. We don't push
+through the CDN as well, because it doesn't help us, so we bypass it.
+
+### Data Store:
+The data store for the registry is using Amazon S3 in a bucket under the docker
+aws account.
+
+### Source Code
+The source code for the registry lives here: https://github.com/dotcloud/docker-registry
+
+### Hosted:
+Hosted on the Docker account on dotCloud's PaaS
+
+## index.docker.io
+This is the docker index, it stores all of the meta information about the 
+docker images, but all data is stored in the registry.
+
+### Source Code:
+Not available
+
+### Hosted:
+Hosted on the Docker account on dotCloud's PaaS
+
+## blog.docker.io
+This is a wordpress based Docker blog.
+
+### URL:
+http://blog.docker.io
+
+### Source Code:
+https://github.com/dotcloud/blog.docker.io
+
+## docs.docker.io
+This is where all of the documentation for docker lives.
+
+### Hosted:
+This website is hosted on ReadTheDocs.org.
+
+### Updates
+These docs get automatically updated when the Docker repo on github has
+new commits. It does this via a webhook.
+
+### Proxy:
+This is a simple dotcloud app, with its main and only purpose to forward
+http (and https) requests to docker.readthedocs.org.
+
+https://github.com/dotcloud/docker-docs-dotcloud-proxy
+
+## get.docker.io
+This is the docker repository where we store images
+
+TODO: need more here. jerome?
diff --git a/hack/install.sh b/hack/install.sh
new file mode 100755
index 0000000..e184a87
--- /dev/null
+++ b/hack/install.sh
@@ -0,0 +1,136 @@
+#!/bin/sh
+set -e
+#
+# This script is meant for quick & easy install via:
+#   'curl -sL https://get.docker.io/ | sh'
+# or:
+#   'wget -qO- https://get.docker.io/ | sh'
+#
+#
+# Docker Maintainers:
+#   To update this script on https://get.docker.io,
+#   use hack/release.sh during a normal release,
+#   or the following one-liner for script hotfixes:
+#     s3cmd put --acl-public -P hack/install.sh s3://get.docker.io/index
+#
+
+url='https://get.docker.io/'
+
+command_exists() {
+	command -v "$@" > /dev/null 2>&1
+}
+
+case "$(uname -m)" in
+	*64)
+		;;
+	*)
+		echo >&2 'Error: you are not using a 64bit platform.'
+		echo >&2 'Docker currently only supports 64bit platforms.'
+		exit 1
+		;;
+esac
+
+if command_exists docker || command_exists lxc-docker; then
+	echo >&2 'Warning: "docker" or "lxc-docker" command appears to already exist.'
+	echo >&2 'Please ensure that you do not already have docker installed.'
+	echo >&2 'You may press Ctrl+C now to abort this process and rectify this situation.'
+	( set -x; sleep 20 )
+fi
+
+sh_c='sh -c'
+if [ "$(whoami 2>/dev/null || true)" != 'root' ]; then
+	if command_exists sudo; then
+		sh_c='sudo sh -c'
+	elif command_exists su; then
+		sh_c='su -c'
+	else
+		echo >&2 'Error: this installer needs the ability to run commands as root.'
+		echo >&2 'We are unable to find either "sudo" or "su" available to make this happen.'
+		exit 1
+	fi
+fi
+
+curl=''
+if command_exists curl; then
+	curl='curl -sL'
+elif command_exists wget; then
+	curl='wget -qO-'
+elif command_exists busybox && busybox --list-modules | grep -q wget; then
+	curl='busybox wget -qO-'
+fi
+
+# perform some very rudimentary platform detection
+lsb_dist=''
+if command_exists lsb_release; then
+	lsb_dist="$(lsb_release -si)"
+fi
+if [ -z "$lsb_dist" ] && [ -r /etc/lsb-release ]; then
+	lsb_dist="$(. /etc/lsb-release && echo "$DISTRIB_ID")"
+fi
+if [ -z "$lsb_dist" ] && [ -r /etc/debian_version ]; then
+	lsb_dist='Debian'
+fi
+
+case "$lsb_dist" in
+	Ubuntu|Debian)
+		export DEBIAN_FRONTEND=noninteractive
+		
+		# TODO remove this comment/section once device-mapper lands
+		echo 'Warning: Docker currently requires AUFS support in the kernel.'
+		echo 'Please ensure that your kernel includes such support.'
+		( set -x; sleep 10 )
+		
+		if [ ! -e /usr/lib/apt/methods/https ]; then
+			( set -x; $sh_c 'sleep 3; apt-get update; apt-get install -y -q apt-transport-https' )
+		fi
+		if [ -z "$curl" ]; then
+			( set -x; $sh_c 'sleep 3; apt-get update; apt-get install -y -q curl' )
+			curl='curl -sL'
+		fi
+		(
+			set -x
+			$sh_c "$curl ${url}gpg | apt-key add -"
+			$sh_c "echo deb ${url}ubuntu docker main > /etc/apt/sources.list.d/docker.list"
+			$sh_c 'sleep 3; apt-get update; apt-get install -y -q lxc-docker'
+		)
+		if command_exists docker && [ -e /var/run/docker.sock ]; then
+			(
+				set -x
+				$sh_c 'docker run busybox echo "Docker has been successfully installed!"'
+			)
+		fi
+		exit 0
+		;;
+		
+	Gentoo)
+		if [ "$url" = "https://test.docker.io/" ]; then
+			echo >&2
+			echo >&2 '  You appear to be trying to install the latest nightly build in Gentoo.'
+			echo >&2 '  The portage tree should contain the latest stable release of Docker, but'
+			echo >&2 '  if you want something more recent, you can always use the live ebuild'
+			echo >&2 '  provided in the "docker" overlay available via layman.  For more'
+			echo >&2 '  instructions, please see the following URL:'
+			echo >&2 '    https://github.com/tianon/docker-overlay#using-this-overlay'
+			echo >&2 '  After adding the "docker" overlay, you should be able to:'
+			echo >&2 '    emerge -av =app-emulation/docker-9999'
+			echo >&2
+			exit 1
+		fi
+		
+		(
+			set -x
+			$sh_c 'sleep 3; emerge app-emulation/docker'
+		)
+		exit 0
+		;;
+esac
+
+echo >&2
+echo >&2 '  Either your platform is not easily detectable, is not supported by this'
+echo >&2 '  installer script (yet - PRs welcome!), or does not yet have a package for'
+echo >&2 '  Docker.  Please visit the following URL for more detailed installation'
+echo >&2 '  instructions:'
+echo >&2
+echo >&2 '    http://docs.docker.io/en/latest/installation/'
+echo >&2
+exit 1
diff --git a/hack/make.sh b/hack/make.sh
index 9414a5c..98b62ea 100755
--- a/hack/make.sh
+++ b/hack/make.sh
@@ -16,8 +16,8 @@
 #   DO NOT CALL THIS SCRIPT DIRECTLY.
 # - The right way to call this script is to invoke "docker build ." from
 #   your checkout of the Docker repository, and then
-#   "docker run hack/make.sh" in the resulting container image. 
-# 
+#   "docker run hack/make.sh" in the resulting container image.
+#
 
 set -e
 
@@ -25,9 +25,9 @@
 # but really, they shouldn't. We want to be in a container!
 RESOLVCONF=$(readlink --canonicalize /etc/resolv.conf)
 grep -q "$RESOLVCONF" /proc/mounts || {
-	echo "# WARNING! I don't seem to be running in a docker container.
-	echo "# The result of this command might be an incorrect build, and will not be officially supported."
-	echo "# Try this: 'docker build -t docker . && docker run docker ./hack/make.sh'
+	echo >&2 "# WARNING! I don't seem to be running in a docker container."
+	echo >&2 "# The result of this command might be an incorrect build, and will not be officially supported."
+	echo >&2 "# Try this: 'docker build -t docker . && docker run docker ./hack/make.sh'"
 }
 
 # List of bundles to create when no argument is passed
@@ -39,8 +39,7 @@
 
 VERSION=$(cat ./VERSION)
 GITCOMMIT=$(git rev-parse --short HEAD)
-if test -n "$(git status --porcelain)"
-then
+if [ -n "$(git status --porcelain)" ]; then
 	GITCOMMIT="$GITCOMMIT-dirty"
 fi
 
@@ -51,19 +50,19 @@
 bundle() {
 	bundlescript=$1
 	bundle=$(basename $bundlescript)
-	echo "---> Making bundle: $bundle"
+	echo "---> Making bundle: $bundle (in bundles/$VERSION/$bundle)"
 	mkdir -p bundles/$VERSION/$bundle
 	source $bundlescript $(pwd)/bundles/$VERSION/$bundle
 }
 
 main() {
-
-	# We want this to fail if the bundles already exist.
+	# We want this to fail if the bundles already exist and cannot be removed.
 	# This is to avoid mixing bundles from different versions of the code.
 	mkdir -p bundles
 	if [ -e "bundles/$VERSION" ]; then
 		echo "bundles/$VERSION already exists. Removing."
 		rm -fr bundles/$VERSION && mkdir bundles/$VERSION || exit 1
+		echo
 	fi
 	SCRIPTDIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
 	if [ $# -lt 1 ]; then
@@ -73,19 +72,8 @@
 	fi
 	for bundle in ${bundles[@]}; do
 		bundle $SCRIPTDIR/make/$bundle
+		echo
 	done
-	cat <<EOF
-###############################################################################
-Now run the resulting image, making sure that you set AWS_S3_BUCKET,
-AWS_ACCESS_KEY, and AWS_SECRET_KEY environment variables:
-
-docker run -e AWS_S3_BUCKET=get-staging.docker.io \\
-              AWS_ACCESS_KEY=AKI1234... \\
-              AWS_SECRET_KEY=sEs3mE... \\
-              GPG_PASSPHRASE=sesame... \\
-              image_id_or_name
-###############################################################################
-EOF
 }
 
 main "$@"
diff --git a/hack/make/binary b/hack/make/binary
index 52d6a47..cff9f5c 100644
--- a/hack/make/binary
+++ b/hack/make/binary
@@ -1,4 +1,7 @@
+#!/bin/sh
 
 DEST=$1
 
-go build -o $DEST/docker-$VERSION -ldflags "$LDFLAGS" ./docker
+if go build -o $DEST/docker-$VERSION -ldflags "$LDFLAGS" ./docker; then
+	echo "Created binary: $DEST/docker-$VERSION"
+fi
diff --git a/hack/make/test b/hack/make/test
index 9334c8b..c097277 100644
--- a/hack/make/test
+++ b/hack/make/test
@@ -3,13 +3,18 @@
 set -e
 
 # Run Docker's test suite, including sub-packages, and store their output as a bundle
+# If $TESTFLAGS is set in the environment, it is passed as extra arguments to 'go test'.
+# You can use this to select certain tests to run, eg.
+# 
+# 	TESTFLAGS='-run ^TestBuild$' ./hack/make.sh test
+#
 bundle_test() {
 	{
 		date
 		for test_dir in $(find_test_dirs); do (
 			set -x
 			cd $test_dir
-			go test -v -ldflags "$LDFLAGS"
+			go test -v -ldflags "$LDFLAGS" $TESTFLAGS
 		)  done
 	} 2>&1 | tee $DEST/test.log
 }
diff --git a/hack/make/ubuntu b/hack/make/ubuntu
index 772fa91..23e02ab 100644
--- a/hack/make/ubuntu
+++ b/hack/make/ubuntu
@@ -79,6 +79,7 @@
 		    --replaces lxc-docker-virtual-package \
 		    --url "$PACKAGE_URL" \
 		    --vendor "$PACKAGE_VENDOR" \
+		    --config-files /etc/init/docker.conf \
 		    -t deb .
 		mkdir empty
 		fpm -s dir -C empty \
@@ -89,6 +90,7 @@
 		    --maintainer "$PACKAGE_MAINTAINER" \
 		    --url "$PACKAGE_URL" \
 		    --vendor "$PACKAGE_VENDOR" \
+		    --config-files /etc/init/docker.conf \
 		    -t deb .
 	)
 }
diff --git a/hack/release.sh b/hack/release.sh
index 237b5fb..12ad27d 100755
--- a/hack/release.sh
+++ b/hack/release.sh
@@ -67,7 +67,14 @@
 }
 
 s3_url() {
-	echo "http://$BUCKET.s3.amazonaws.com"
+	case "$BUCKET" in
+		get.docker.io|test.docker.io)
+			echo "https://$BUCKET"
+			;;
+		*)
+			echo "http://$BUCKET.s3.amazonaws.com"
+			;;
+	esac
 }
 
 # Upload the 'ubuntu' bundle to S3:
@@ -125,13 +132,13 @@
 	s3cmd --acl-public sync $APTDIR/ s3://$BUCKET/ubuntu/
 	cat <<EOF | write_to_s3 s3://$BUCKET/ubuntu/info
 # Add the repository to your APT sources
-echo deb $(s3_url $BUCKET)/ubuntu docker main > /etc/apt/sources.list.d/docker.list
+echo deb $(s3_url)/ubuntu docker main > /etc/apt/sources.list.d/docker.list
 # Then import the repository key
-curl $(s3_url $BUCKET)/gpg | apt-key add -
+curl $(s3_url)/gpg | apt-key add -
 # Install docker
 apt-get update ; apt-get install -y lxc-docker
 EOF
-	echo "APT repository uploaded. Instructions available at $(s3_url $BUCKET)/ubuntu/info"
+	echo "APT repository uploaded. Instructions available at $(s3_url)/ubuntu/info"
 }
 
 # Upload a static binary to S3
@@ -141,7 +148,7 @@
 	s3cmd --acl-public put bundles/$VERSION/binary/docker-$VERSION $S3DIR/docker-$VERSION
 	cat <<EOF | write_to_s3 s3://$BUCKET/builds/info
 # To install, run the following command as root:
-curl -O http://$BUCKET.s3.amazonaws.com/builds/Linux/x86_64/docker-$VERSION && chmod +x docker-$VERSION && sudo mv docker-$VERSION /usr/local/bin/docker
+curl -O $(s3_url)/builds/Linux/x86_64/docker-$VERSION && chmod +x docker-$VERSION && sudo mv docker-$VERSION /usr/local/bin/docker
 # Then start docker in daemon mode:
 sudo /usr/local/bin/docker -d
 EOF
@@ -155,14 +162,7 @@
 
 # Upload the index script
 release_index() {
-	(
-	if [ "$BUCKET" != "get.docker.io" ]
-	then
-		sed s,https://get.docker.io/,http://$BUCKET.s3.amazonaws.com/, contrib/install.sh
-	else
-		cat contrib/install.sh
-	fi
-	) | write_to_s3 s3://$BUCKET/index
+	sed "s,https://get.docker.io/,$(s3_url)/," hack/install.sh | write_to_s3 s3://$BUCKET/index
 }
 
 release_test() {
diff --git a/hack/vendor.sh b/hack/vendor.sh
index 8651a15..a2411c8 100755
--- a/hack/vendor.sh
+++ b/hack/vendor.sh
@@ -21,7 +21,7 @@
   )
 }
 
-git_clone github.com/kr/pty 27435c699
+git_clone github.com/kr/pty 3b1f6487b
 
 git_clone github.com/gorilla/context/ 708054d61e5
 
diff --git a/lxc_template.go b/lxc_template.go
index b34ff85..0e2dfaf 100644
--- a/lxc_template.go
+++ b/lxc_template.go
@@ -111,7 +111,7 @@
 #  (Note: 'lxc.cap.keep' is coming soon and should replace this under the
 #         security principle 'deny all unless explicitly permitted', see
 #         http://sourceforge.net/mailarchive/message.php?msg_id=31054627 )
-lxc.cap.drop = audit_control audit_write mac_admin mac_override mknod setfcap setpcap sys_admin sys_boot sys_module sys_nice sys_pacct sys_rawio sys_resource sys_time sys_tty_config
+lxc.cap.drop = audit_control audit_write mac_admin mac_override mknod setpcap sys_admin sys_boot sys_module sys_nice sys_pacct sys_rawio sys_resource sys_time sys_tty_config
 {{end}}
 
 # limits
diff --git a/mount.go b/mount.go
index 541c29c..f4a4dfb 100644
--- a/mount.go
+++ b/mount.go
@@ -12,7 +12,7 @@
 
 func Unmount(target string) error {
 	if err := exec.Command("auplink", target, "flush").Run(); err != nil {
-		utils.Debugf("[warning]: couldn't run auplink before unmount: %s", err)
+		utils.Errorf("[warning]: couldn't run auplink before unmount: %s", err)
 	}
 	if err := syscall.Unmount(target, 0); err != nil {
 		return err
diff --git a/network.go b/network.go
index b552919..59d8257 100644
--- a/network.go
+++ b/network.go
@@ -336,13 +336,20 @@
 type PortAllocator struct {
 	sync.Mutex
 	inUse    map[int]struct{}
-	fountain chan (int)
+	fountain chan int
+	quit     chan bool
 }
 
 func (alloc *PortAllocator) runFountain() {
 	for {
 		for port := portRangeStart; port < portRangeEnd; port++ {
-			alloc.fountain <- port
+			select {
+			case alloc.fountain <- port:
+			case quit := <-alloc.quit:
+				if quit {
+					return
+				}
+			}
 		}
 	}
 }
@@ -376,10 +383,18 @@
 	return port, nil
 }
 
+func (alloc *PortAllocator) Close() error {
+	alloc.quit <- true
+	close(alloc.quit)
+	close(alloc.fountain)
+	return nil
+}
+
 func newPortAllocator() (*PortAllocator, error) {
 	allocator := &PortAllocator{
 		inUse:    make(map[int]struct{}),
 		fountain: make(chan int),
+		quit:     make(chan bool),
 	}
 	go allocator.runFountain()
 	return allocator, nil
@@ -391,6 +406,7 @@
 	queueAlloc    chan allocatedIP
 	queueReleased chan net.IP
 	inUse         map[int32]struct{}
+	quit          chan bool
 }
 
 type allocatedIP struct {
@@ -435,6 +451,10 @@
 		}
 
 		select {
+		case quit := <-alloc.quit:
+			if quit {
+				return
+			}
 		case alloc.queueAlloc <- ip:
 			alloc.inUse[newNum] = struct{}{}
 		case released := <-alloc.queueReleased:
@@ -467,12 +487,21 @@
 	alloc.queueReleased <- ip
 }
 
+func (alloc *IPAllocator) Close() error {
+	alloc.quit <- true
+	close(alloc.quit)
+	close(alloc.queueAlloc)
+	close(alloc.queueReleased)
+	return nil
+}
+
 func newIPAllocator(network *net.IPNet) *IPAllocator {
 	alloc := &IPAllocator{
 		network:       network,
 		queueAlloc:    make(chan allocatedIP),
 		queueReleased: make(chan net.IP),
 		inUse:         make(map[int32]struct{}),
+		quit:          make(chan bool),
 	}
 
 	go alloc.run()
@@ -662,6 +691,19 @@
 	return iface, nil
 }
 
+func (manager *NetworkManager) Close() error {
+	err1 := manager.tcpPortAllocator.Close()
+	err2 := manager.udpPortAllocator.Close()
+	err3 := manager.ipAllocator.Close()
+	if err1 != nil {
+		return err1
+	}
+	if err2 != nil {
+		return err2
+	}
+	return err3
+}
+
 func newNetworkManager(bridgeIface string) (*NetworkManager, error) {
 
 	if bridgeIface == DisableNetworkBridge {
@@ -708,5 +750,6 @@
 		udpPortAllocator: udpPortAllocator,
 		portMapper:       portMapper,
 	}
+
 	return manager, nil
 }
diff --git a/network_proxy.go b/network_proxy.go
index fb91cc1..8654580 100644
--- a/network_proxy.go
+++ b/network_proxy.go
@@ -61,10 +61,9 @@
 	var broker = func(to, from *net.TCPConn) {
 		written, err := io.Copy(to, from)
 		if err != nil {
-			err, ok := err.(*net.OpError)
 			// If the socket we are writing to is shutdown with
 			// SHUT_WR, forward it to the other end of the pipe:
-			if ok && err.Err == syscall.EPIPE {
+			if err, ok := err.(*net.OpError); ok && err.Err == syscall.EPIPE {
 				from.CloseWrite()
 			}
 		}
@@ -99,11 +98,16 @@
 func (proxy *TCPProxy) Run() {
 	quit := make(chan bool)
 	defer close(quit)
+
 	utils.Debugf("Starting proxy on tcp/%v for tcp/%v", proxy.frontendAddr, proxy.backendAddr)
 	for {
 		client, err := proxy.listener.Accept()
 		if err != nil {
-			utils.Debugf("Stopping proxy on tcp/%v for tcp/%v (%v)", proxy.frontendAddr, proxy.backendAddr, err.Error())
+			if utils.IsClosedError(err) {
+				utils.Debugf("Stopping proxy on tcp/%v for tcp/%v (socket was closed)", proxy.frontendAddr, proxy.backendAddr)
+			} else {
+				utils.Errorf("Stopping proxy on tcp/%v for tcp/%v (%v)", proxy.frontendAddr, proxy.backendAddr, err.Error())
+			}
 			return
 		}
 		go proxy.clientLoop(client.(*net.TCPConn), quit)
@@ -205,7 +209,11 @@
 			// NOTE: Apparently ReadFrom doesn't return
 			// ECONNREFUSED like Read do (see comment in
 			// UDPProxy.replyLoop)
-			utils.Debugf("Stopping proxy on udp/%v for udp/%v (%v)", proxy.frontendAddr, proxy.backendAddr, err.Error())
+			if utils.IsClosedError(err) {
+				utils.Debugf("Stopping proxy on udp/%v for udp/%v (socket was closed)", proxy.frontendAddr, proxy.backendAddr)
+			} else {
+				utils.Errorf("Stopping proxy on udp/%v for udp/%v (%v)", proxy.frontendAddr, proxy.backendAddr, err.Error())
+			}
 			break
 		}
 
diff --git a/packaging/README.md b/packaging/README.md
deleted file mode 100644
index 1efe79a..0000000
--- a/packaging/README.md
+++ /dev/null
@@ -1,12 +0,0 @@
-# Docker packaging
-
-This directory has one subdirectory per packaging distribution.
-At minimum, each of these subdirectories should contain a
-README.$DISTRIBUTION explaining how to create the native
-docker package and how to install it.
-
-**Important:** the debian and ubuntu directories are here for
-reference only. Since we experienced many issues with Launchpad,
-we gave up on using it to have a Docker PPA (at least, for now!)
-and we are using a simpler process.
-See [/hack/release](../hack/release) for details.
diff --git a/packaging/archlinux/README.archlinux b/packaging/archlinux/README.archlinux
deleted file mode 100644
index f20d2d2..0000000
--- a/packaging/archlinux/README.archlinux
+++ /dev/null
@@ -1,25 +0,0 @@
-Docker on Arch
-==============
-
-The AUR lxc-docker and lxc-docker-git packages handle building docker on Arch
-linux.  The PKGBUILD specifies all dependencies, build, and packaging steps.
-
-Dependencies
-============
-
-The only buildtime dependencies are git and go which are available via pacman.
-The -s flag can be used on makepkg commands below to automatically install
-these dependencies.
-
-Building Package
-================
-
-Download the tarball for either AUR packaged to a local directory.  In that
-directory makepkg can be run to build the package.
-
-# Build the binary package
-makepkg
-
-# Build an updated source tarball
-makepkg --source
-
diff --git a/packaging/debian/Makefile b/packaging/debian/Makefile
deleted file mode 100644
index 1f544b5..0000000
--- a/packaging/debian/Makefile
+++ /dev/null
@@ -1,59 +0,0 @@
-# Debian package Makefile
-#
-# Dependencies:  git debhelper build-essential autotools-dev devscripts golang
-# Notes:
-# Use 'make debian' to create the debian package
-# To create a specific version, use 'VERSION_TAG=v0.2.0 make debian'
-# GPG_KEY environment variable needs to contain a GPG private key for package
-# to be signed and uploaded to debian.
-# If GPG_KEY is not defined, make debian will create docker package and exit
-# with status code 2
-
-PKG_NAME=lxc-docker
-ROOT_PATH=$(shell git rev-parse --show-toplevel)
-GITHUB_PATH=github.com/dotcloud/docker
-BUILD_SRC=build_src
-VERSION=$(shell sed -En '0,/^\#\# /{s/^\#\# ([^ ]+).+/\1/p}' ../../CHANGELOG.md)
-VERSION_TAG?=v${VERSION}
-DOCKER_VERSION=${PKG_NAME}_${VERSION}
-
-all:
-	# Compile docker. Used by debian dpkg-buildpackage.
-	cd src/${GITHUB_PATH}/docker; GOPATH=${CURDIR} go build
-
-install:
-	# Used by debian dpkg-buildpackage
-	mkdir -p $(DESTDIR)/usr/bin
-	mkdir -p $(DESTDIR)/usr/share/man/man1
-	mkdir -p $(DESTDIR)/usr/share/doc/lxc-docker
-	install -m 0755 src/${GITHUB_PATH}/docker/docker $(DESTDIR)/usr/bin/lxc-docker
-	cp debian/lxc-docker.1 $(DESTDIR)/usr/share/man/man1
-
-debian:
-	# Prepare docker source from revision ${VERSION_TAG}
-	rm -rf ${BUILD_SRC} ${PKG_NAME}_[0-9]*
-	git clone file://$(ROOT_PATH) ${BUILD_SRC}/src/${GITHUB_PATH} --branch ${VERSION_TAG} --depth 1
-	GOPATH=${CURDIR}/${BUILD_SRC} go get -d ${GITHUB_PATH}
-	# Add debianization
-	mkdir ${BUILD_SRC}/debian
-	cp Makefile ${BUILD_SRC}
-	cp -r `ls | grep -v ${BUILD_SRC}` ${BUILD_SRC}/debian
-	cp ${ROOT_PATH}/README.md ${BUILD_SRC}
-	cp ${ROOT_PATH}/CHANGELOG.md ${BUILD_SRC}/debian
-	./parse_changelog.py < ../../CHANGELOG.md  > ${BUILD_SRC}/debian/changelog
-	# Cleanup
-	rm -rf `find . -name '.git*'`
-	rm -f ${DOCKER_VERSION}*
-	# Create docker debian files
-	cd ${BUILD_SRC}; tar czf ../${DOCKER_VERSION}.orig.tar.gz .
-	cd ${BUILD_SRC}; dpkg-buildpackage -us -uc
-	rm -rf ${BUILD_SRC}
-	# Sign package and upload it to PPA if GPG_KEY environment variable
-	# holds a private GPG KEY
-	if /usr/bin/test "$${GPG_KEY}" == ""; then exit 2; fi
-	mkdir ${BUILD_SRC}
-	# Import gpg signing key
-	echo "$${GPG_KEY}" | gpg --allow-secret-key-import --import
-	# Sign the package
-	cd ${BUILD_SRC}; dpkg-source -x ${CURDIR}/${DOCKER_VERSION}-1.dsc
-	cd ${BUILD_SRC}/${PKG_NAME}-${VERSION}; debuild -S -sa
diff --git a/packaging/debian/README.Debian b/packaging/debian/README.Debian
deleted file mode 100644
index cb09477..0000000
--- a/packaging/debian/README.Debian
+++ /dev/null
@@ -1,28 +0,0 @@
-Docker on Debian
-================
-
-Docker has been built and tested on Wheezy. All docker functionality works
-out of the box, except for memory limitation as the stock debian kernel
-disables it by default. To enable docker memory limitation, the kernel needs
-to be loaded with boot parameters: cgroup_enable=memory swapaccount=1
-
-
-Building docker package
-~~~~~~~~~~~~~~~~~~~~~~~
-
-Assuming you have a wheezy system up and running
-
-# Get building dependencies
-sudo apt-get update
-sudo apt-get install -y debhelper build-essential autotools-dev golang
-
-# Make the debian package
-git clone https://github.com/dotcloud/docker.git
-cd docker/packaging/debian
-make debian
-
-
-Install docker package
-~~~~~~~~~~~~~~~~~~~~~~
-
-sudo dpkg -i lxc-docker_*-1_amd64.deb; sudo apt-get install -f -y
diff --git a/packaging/debian/Vagrantfile b/packaging/debian/Vagrantfile
deleted file mode 100644
index cb84ed5..0000000
--- a/packaging/debian/Vagrantfile
+++ /dev/null
@@ -1,21 +0,0 @@
-VM_IP = "192.168.33.31"
-PKG_DEP = "git debhelper build-essential autotools-dev devscripts golang"
-
-Vagrant::Config.run do |config|
-  config.vm.box = 'debian-7.0.rc1.64'
-  config.vm.box_url = 'http://puppet-vagrant-boxes.puppetlabs.com/debian-70rc1-x64-vbox4210-nocm.box'
-  config.vm.share_folder 'v-data', '/data/docker', "#{File.dirname(__FILE__)}/../.."
-  config.vm.network :hostonly,VM_IP
-
-  # Add kernel cgroup memory limitation boot parameters
-  grub_cmd="sed -i 's#DEFAULT=\"quiet\"#DEFAULT=\"cgroup_enable=memory swapaccount=1 quiet\"#' /etc/default/grub"
-  config.vm.provision :shell, :inline => "#{grub_cmd};update-grub"
-
-  # Install debian packaging dependencies and create debian packages
-  pkg_cmd = "apt-get -qq update; DEBIAN_FRONTEND=noninteractive apt-get install -qq -y #{PKG_DEP}; " \
-      "curl -s -o /go.tar.gz https://go.googlecode.com/files/go1.1.1.linux-amd64.tar.gz; " \
-      "tar -C /usr/local -xzf /go.tar.gz; rm /usr/bin/go; " \
-      "ln -s /usr/local/go/bin/go /usr/bin; "\
-      "export GPG_KEY='#{ENV['GPG_KEY']}'; cd /data/docker/packaging/debian; make debian"
-  config.vm.provision :shell, :inline => pkg_cmd
-end
diff --git a/packaging/debian/changelog b/packaging/debian/changelog
deleted file mode 100644
index 55102dd..0000000
--- a/packaging/debian/changelog
+++ /dev/null
@@ -1,27 +0,0 @@
-lxc-docker (0.3.4-1) UNRELEASED; urgency=low
-  - Builder: 'docker build' builds a container, layer by layer, from a source repository containing a Dockerfile
-  - Builder: 'docker build -t FOO' applies the tag FOO to the newly built container.
-  - Runtime: interactive TTYs correctly handle window resize
-  - Runtime: fix how configuration is merged between layers
-  - Remote API: split stdout and stderr on 'docker run'
-  - Remote API: optionally listen on a different IP and port (use at your own risk)
-  - Documentation: improved install instructions.
-
- -- dotCloud <ops@dotcloud.com>  Thu, 30 May 2013 00:00:00 -0700
-
-lxc-docker (0.3.2-1) UNRELEASED; urgency=low
-  - Runtime: Store the actual archive on commit
-  - Registry: Improve the checksum process
-  - Registry: Use the size to have a good progress bar while pushing
-  - Registry: Use the actual archive if it exists in order to speed up the push
-  - Registry: Fix error 400 on push
-
- -- Daniel Mizyrycki <daniel@dotcloud.com>  Sun, 12 May 2013 00:00:00 -0700
-
-
-lxc-docker (0.2.0-1) UNRELEASED; urgency=low
- 
-  - Pre-release (Closes: #706060)
-
- -- Daniel Mizyrycki <daniel@dotcloud.com>  Fri, 26 Apr 2013 23:41:29 -0700
-
diff --git a/packaging/debian/compat b/packaging/debian/compat
deleted file mode 100644
index ec63514..0000000
--- a/packaging/debian/compat
+++ /dev/null
@@ -1 +0,0 @@
-9
diff --git a/packaging/debian/control b/packaging/debian/control
deleted file mode 100644
index 62a963f..0000000
--- a/packaging/debian/control
+++ /dev/null
@@ -1,20 +0,0 @@
-Source: lxc-docker
-Section: admin
-Priority: optional
-Maintainer: Daniel Mizyrycki <daniel@dotcloud.com>
-Build-Depends: debhelper (>=9), autotools-dev, golang
-Standards-Version: 3.9.4
-Vcs-Git: git://git.debian.org/git/collab-maint/lxc-docker.git
-Vcs-Browser: http://anonscm.debian.org/gitweb/?p=collab-maint/lxc-docker.git;a=summary
-Homepage: http://github.com/dotcloud/docker
-
-Package: lxc-docker
-Architecture: linux-any
-Depends: ${shlibs:Depends}, ${misc:Depends}, lxc, bsdtar, aufs-tools
-Description: Linux container runtime
- Docker complements LXC with a high-level API which operates at the process
- level. It runs unix processes with strong guarantees of isolation and
- repeatability across servers.
- Docker is a great building block for automating distributed systems:
- large-scale web deployments, database clusters, continuous deployment systems,
- private PaaS, service-oriented architectures, etc.
diff --git a/packaging/debian/copyright b/packaging/debian/copyright
deleted file mode 100644
index 8bb4003..0000000
--- a/packaging/debian/copyright
+++ /dev/null
@@ -1,22 +0,0 @@
-Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
-Upstream-Name: docker
-Upstream-Contact: dotCloud Inc <opensource@dotcloud.com>
-Source: http://github.com/dotcloud/docker
-
-Files: *
-Copyright: 2012, dotCloud Inc <opensource@dotcloud.com>
-License: Apache-2.0
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
- .
- http://www.apache.org/licenses/LICENSE-2.0
- .
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
- .
- On Debian systems, the complete text of the Apache version 2.0 license
- can be found in "/usr/share/common-licenses/Apache-2.0".
diff --git a/packaging/debian/docs b/packaging/debian/docs
deleted file mode 100644
index b43bf86..0000000
--- a/packaging/debian/docs
+++ /dev/null
@@ -1 +0,0 @@
-README.md
diff --git a/packaging/debian/lxc-docker.1 b/packaging/debian/lxc-docker.1
deleted file mode 100644
index b92853f..0000000
--- a/packaging/debian/lxc-docker.1
+++ /dev/null
@@ -1,1155 +0,0 @@
-.TH "DOCKER" "1" "May 07, 2013" "0.1" "Docker"
-.SH NAME
-docker \- Docker Documentation
-.
-.nr rst2man-indent-level 0
-.
-.de1 rstReportMargin
-\\$1 \\n[an-margin]
-level \\n[rst2man-indent-level]
-level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
--
-\\n[rst2man-indent0]
-\\n[rst2man-indent1]
-\\n[rst2man-indent2]
-..
-.de1 INDENT
-.\" .rstReportMargin pre:
-. RS \\$1
-. nr rst2man-indent\\n[rst2man-indent-level] \\n[an-margin]
-. nr rst2man-indent-level +1
-.\" .rstReportMargin post:
-..
-.de UNINDENT
-. RE
-.\" indent \\n[an-margin]
-.\" old: \\n[rst2man-indent\\n[rst2man-indent-level]]
-.nr rst2man-indent-level -1
-.\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
-.in \\n[rst2man-indent\\n[rst2man-indent-level]]u
-..
-.\" Man page generated from reStructeredText.
-.
-.sp
-This documentation has the following resources:
-.SH CONCEPTS
-.sp
-Contents:
-.SS Standard Containers
-.SS What is a Standard Container?
-.sp
-Docker defines a unit of software delivery called a Standard Container. The goal of a Standard Container is to encapsulate a software component and all its dependencies in
-a format that is self\-describing and portable, so that any compliant runtime can run it without extra dependency, regardless of the underlying machine and the contents of the container.
-.sp
-The spec for Standard Containers is currently work in progress, but it is very straightforward. It mostly defines 1) an image format, 2) a set of standard operations, and 3) an execution environment.
-.sp
-A great analogy for this is the shipping container. Just like Standard Containers are a fundamental unit of software delivery, shipping containers (\fI\%http://bricks.argz.com/ins/7823-1/12\fP) are a fundamental unit of physical delivery.
-.SS Standard operations
-.sp
-Just like shipping containers, Standard Containers define a set of STANDARD OPERATIONS. Shipping containers can be lifted, stacked, locked, loaded, unloaded and labelled. Similarly, standard containers can be started, stopped, copied, snapshotted, downloaded, uploaded and tagged.
-.SS Content\-agnostic
-.sp
-Just like shipping containers, Standard Containers are CONTENT\-AGNOSTIC: all standard operations have the same effect regardless of the contents. A shipping container will be stacked in exactly the same way whether it contains Vietnamese powder coffee or spare Maserati parts. Similarly, Standard Containers are started or uploaded in the same way whether they contain a postgres database, a php application with its dependencies and application server, or Java build artifacts.
-.SS Infrastructure\-agnostic
-.sp
-Both types of containers are INFRASTRUCTURE\-AGNOSTIC: they can be transported to thousands of facilities around the world, and manipulated by a wide variety of equipment. A shipping container can be packed in a factory in Ukraine, transported by truck to the nearest routing center, stacked onto a train, loaded into a German boat by an Australian\-built crane, stored in a warehouse at a US facility, etc. Similarly, a standard container can be bundled on my laptop, uploaded to S3, downloaded, run and snapshotted by a build server at Equinix in Virginia, uploaded to 10 staging servers in a home\-made Openstack cluster, then sent to 30 production instances across 3 EC2 regions.
-.SS Designed for automation
-.sp
-Because they offer the same standard operations regardless of content and infrastructure, Standard Containers, just like their physical counterpart, are extremely well\-suited for automation. In fact, you could say automation is their secret weapon.
-.sp
-Many things that once required time\-consuming and error\-prone human effort can now be programmed. Before shipping containers, a bag of powder coffee was hauled, dragged, dropped, rolled and stacked by 10 different people in 10 different locations by the time it reached its destination. 1 out of 50 disappeared. 1 out of 20 was damaged. The process was slow, inefficient and cost a fortune \- and was entirely different depending on the facility and the type of goods.
-.sp
-Similarly, before Standard Containers, by the time a software component ran in production, it had been individually built, configured, bundled, documented, patched, vendored, templated, tweaked and instrumented by 10 different people on 10 different computers. Builds failed, libraries conflicted, mirrors crashed, post\-it notes were lost, logs were misplaced, cluster updates were half\-broken. The process was slow, inefficient and cost a fortune \- and was entirely different depending on the language and infrastructure provider.
-.SS Industrial\-grade delivery
-.sp
-There are 17 million shipping containers in existence, packed with every physical good imaginable. Every single one of them can be loaded on the same boats, by the same cranes, in the same facilities, and sent anywhere in the World with incredible efficiency. It is embarrassing to think that a 30 ton shipment of coffee can safely travel half\-way across the World in \fIless time\fP than it takes a software team to deliver its code from one datacenter to another sitting 10 miles away.
-.sp
-With Standard Containers we can put an end to that embarrassment, by making INDUSTRIAL\-GRADE DELIVERY of software a reality.
-.SS Standard Container Specification
-.sp
-(TODO)
-.SS Image format
-.SS Standard operations
-.INDENT 0.0
-.IP \(bu 2
-Copy
-.IP \(bu 2
-Run
-.IP \(bu 2
-Stop
-.IP \(bu 2
-Wait
-.IP \(bu 2
-Commit
-.IP \(bu 2
-Attach standard streams
-.IP \(bu 2
-List filesystem changes
-.IP \(bu 2
-.UNINDENT
-.SS Execution environment
-.SS Root filesystem
-.SS Environment variables
-.SS Process arguments
-.SS Networking
-.SS Process namespacing
-.SS Resource limits
-.SS Process monitoring
-.SS Logging
-.SS Signals
-.SS Pseudo\-terminal allocation
-.SS Security
-.SH INSTALLATION
-.sp
-Contents:
-.SS Ubuntu Linux
-.INDENT 0.0
-.INDENT 3.5
-\fBPlease note this project is currently under heavy development. It should not be used in production.\fP
-.UNINDENT
-.UNINDENT
-.sp
-Installing on Ubuntu 12.04 and 12.10
-.sp
-Right now, the officially supported distributions are:
-.sp
-Ubuntu 12.04 (precise LTS)
-Ubuntu 12.10 (quantal)
-Docker probably works on other distributions featuring a recent kernel, the AUFS patch, and up\-to\-date lxc. However this has not been tested.
-.SS Install dependencies:
-.sp
-.nf
-.ft C
-sudo apt\-get install lxc wget bsdtar curl
-sudo apt\-get install linux\-image\-extra\-\(gauname \-r\(ga
-.ft P
-.fi
-.sp
-The linux\-image\-extra package is needed on standard Ubuntu EC2 AMIs in order to install the aufs kernel module.
-.sp
-Install the latest docker binary:
-.sp
-.nf
-.ft C
-wget http://get.docker.io/builds/$(uname \-s)/$(uname \-m)/docker\-master.tgz
-tar \-xf docker\-master.tgz
-.ft P
-.fi
-.sp
-Run your first container!
-.sp
-.nf
-.ft C
-cd docker\-master
-.ft P
-.fi
-.sp
-.nf
-.ft C
-sudo ./docker run \-i \-t ubuntu /bin/bash
-.ft P
-.fi
-.sp
-Consider adding docker to your PATH for simplicity.
-.sp
-Continue with the \fIhello_world\fP example.
-.SS Mac OS X and other linux
-.INDENT 0.0
-.INDENT 3.5
-Please note this is a community contributed installation path. The only \(aqofficial\(aq installation is using the \fIubuntu_linux\fP installation path. This version
-may be out of date because it depends on some binaries to be updated and published
-.UNINDENT
-.UNINDENT
-.SS Requirements
-.sp
-We currently rely on some Ubuntu\-linux specific packages, this will change in the future, but for now we provide a
-streamlined path to install Virtualbox with a Ubuntu 12.10 image using Vagrant.
-.INDENT 0.0
-.IP 1. 3
-Install virtualbox from \fI\%https://www.virtualbox.org/\fP (or use your package manager)
-.IP 2. 3
-Install vagrant from \fI\%http://www.vagrantup.com/\fP (or use your package manager)
-.IP 3. 3
-Install git if you had not installed it before, check if it is installed by running
-\fBgit\fP in a terminal window
-.UNINDENT
-.sp
-We recommend having at least about 2Gb of free disk space and 2Gb RAM (or more).
-.SS Installation
-.INDENT 0.0
-.IP 1. 3
-Fetch the docker sources
-.UNINDENT
-.sp
-.nf
-.ft C
-git clone https://github.com/dotcloud/docker.git
-.ft P
-.fi
-.INDENT 0.0
-.IP 2. 3
-Run vagrant from the sources directory
-.UNINDENT
-.sp
-.nf
-.ft C
-vagrant up
-.ft P
-.fi
-.sp
-Vagrant will:
-.INDENT 0.0
-.IP \(bu 2
-Download the Quantal64 base ubuntu virtual machine image from get.docker.io/
-.IP \(bu 2
-Boot this image in virtualbox
-.UNINDENT
-.sp
-Then it will use Puppet to perform an initial setup in this machine:
-.INDENT 0.0
-.IP \(bu 2
-Download & untar the most recent docker binary tarball to vagrant homedir.
-.IP \(bu 2
-Debootstrap to /var/lib/docker/images/ubuntu.
-.IP \(bu 2
-Install & run dockerd as service.
-.IP \(bu 2
-Put docker in /usr/local/bin.
-.IP \(bu 2
-Put latest Go toolchain in /usr/local/go.
-.UNINDENT
-.sp
-You now have a Ubuntu Virtual Machine running with docker pre\-installed.
-.sp
-To access the VM and use Docker, Run \fBvagrant ssh\fP from the same directory as where you ran
-\fBvagrant up\fP. Vagrant will make sure to connect you to the correct VM.
-.sp
-.nf
-.ft C
-vagrant ssh
-.ft P
-.fi
-.sp
-Now you are in the VM, run docker
-.sp
-.nf
-.ft C
-docker
-.ft P
-.fi
-.sp
-Continue with the \fIhello_world\fP example.
-.SS Windows
-.INDENT 0.0
-.INDENT 3.5
-Please note this is a community contributed installation path. The only \(aqofficial\(aq installation is using the \fIubuntu_linux\fP installation path. This version
-may be out of date because it depends on some binaries to be updated and published
-.UNINDENT
-.UNINDENT
-.SS Requirements
-.INDENT 0.0
-.IP 1. 3
-Install virtualbox from \fI\%https://www.virtualbox.org\fP \- or follow this \fI\%tutorial\fP
-.UNINDENT
-.INDENT 0.0
-.IP 2. 3
-Install vagrant from \fI\%http://www.vagrantup.com\fP \- or follow this \fI\%tutorial\fP
-.UNINDENT
-.INDENT 0.0
-.IP 3. 3
-Install git with ssh from \fI\%http://git-scm.com/downloads\fP \- or follow this \fI\%tutorial\fP
-.UNINDENT
-.sp
-We recommend having at least 2Gb of free disk space and 2Gb of RAM (or more).
-.SS Opening a command prompt
-.sp
-First open a cmd prompt. Press Windows key and then press “R” key. This will open the RUN dialog box for you. Type “cmd” and press Enter. Or you can click on Start, type “cmd” in the “Search programs and files” field, and click on cmd.exe.
-[image: Git install]
-[image]
-.sp
-This should open a cmd prompt window.
-[image: run docker]
-[image]
-.sp
-Alternatively, you can also use a Cygwin terminal, or Git Bash (or any other command line program you are usually using). The next steps would be the same.
-.SS Launch an Ubuntu virtual server
-.sp
-Let’s download and run an Ubuntu image with docker binaries already installed.
-.sp
-.nf
-.ft C
-git clone https://github.com/dotcloud/docker.git
-cd docker
-vagrant up
-.ft P
-.fi
-[image: run docker]
-[image]
-.sp
-Congratulations! You are running an Ubuntu server with docker installed on it. You do not see it though, because it is running in the background.
-.SS Log onto your Ubuntu server
-.sp
-Let’s log into your Ubuntu server now. To do so you have two choices:
-.INDENT 0.0
-.IP \(bu 2
-Use Vagrant on Windows command prompt OR
-.IP \(bu 2
-Use SSH
-.UNINDENT
-.SS Using Vagrant on Windows Command Prompt
-.sp
-Run the following command
-.sp
-.nf
-.ft C
-vagrant ssh
-.ft P
-.fi
-.sp
-You may see an error message starting with “\fIssh\fP executable not found”. In this case it means that you do not have SSH in your PATH. If you do not have SSH in your PATH you can set it up with the “set” command. For instance, if your ssh.exe is in the folder named “C:Program Files (x86)Gitbin”, then you can run the following command:
-.sp
-.nf
-.ft C
-set PATH=%PATH%;C:\eProgram Files (x86)\eGit\ebin
-.ft P
-.fi
-[image: run docker]
-[image]
-.SS Using SSH
-.sp
-First step is to get the IP and port of your Ubuntu server. Simply run:
-.sp
-.nf
-.ft C
-vagrant ssh\-config
-.ft P
-.fi
-.sp
-You should see an output with HostName and Port information. In this example, HostName is 127.0.0.1 and port is 2222. And the User is “vagrant”. The password is not shown, but it is also “vagrant”.
-[image: run docker]
-[image]
-.sp
-You can now use this information for connecting via SSH to your server. To do so you can:
-.INDENT 0.0
-.IP \(bu 2
-Use putty.exe OR
-.IP \(bu 2
-Use SSH from a terminal
-.UNINDENT
-.SS Use putty.exe
-.sp
-You can download putty.exe from this page \fI\%http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html\fP
-Launch putty.exe and simply enter the information you got from last step.
-[image: run docker]
-[image]
-.sp
-Open, and enter user = vagrant and password = vagrant.
-[image: run docker]
-[image]
-.SS SSH from a terminal
-.sp
-You can also run this command on your favorite terminal (windows prompt, cygwin, git\-bash, …). Make sure to adapt the IP and port from what you got from the vagrant ssh\-config command.
-.sp
-.nf
-.ft C
-ssh vagrant@127.0.0.1 –p 2222
-.ft P
-.fi
-.sp
-Enter user = vagrant and password = vagrant.
-[image: run docker]
-[image]
-.sp
-Congratulations, you are now logged onto your Ubuntu Server, running on top of your Windows machine !
-.SS Running Docker
-.sp
-First you have to be root in order to run docker. Simply run the following command:
-.sp
-.nf
-.ft C
-sudo su
-.ft P
-.fi
-.sp
-You are now ready for the docker’s “hello world” example. Run
-.sp
-.nf
-.ft C
-docker run \-a busybox echo hello world
-.ft P
-.fi
-[image: run docker]
-[image]
-.sp
-All done!
-.sp
-Now you can continue with the \fIhello_world\fP example.
-.SS Amazon EC2
-.INDENT 0.0
-.INDENT 3.5
-Please note this is a community contributed installation path. The only \(aqofficial\(aq installation is using the \fIubuntu_linux\fP installation path. This version
-may be out of date because it depends on some binaries to be updated and published
-.UNINDENT
-.UNINDENT
-.SS Installation
-.sp
-Docker can now be installed on Amazon EC2 with a single vagrant command. Vagrant 1.1 or higher is required.
-.INDENT 0.0
-.IP 1. 3
-Install vagrant from \fI\%http://www.vagrantup.com/\fP (or use your package manager)
-.IP 2. 3
-Install the vagrant aws plugin
-.sp
-.nf
-.ft C
-vagrant plugin install vagrant\-aws
-.ft P
-.fi
-.IP 3. 3
-Get the docker sources, this will give you the latest Vagrantfile and puppet manifests.
-.sp
-.nf
-.ft C
-git clone https://github.com/dotcloud/docker.git
-.ft P
-.fi
-.IP 4. 3
-Check your AWS environment.
-.sp
-Create a keypair specifically for EC2, give it a name and save it to your disk. \fII usually store these in my ~/.ssh/ folder\fP.
-.sp
-Check that your default security group has an inbound rule to accept SSH (port 22) connections.
-.IP 5. 3
-Inform Vagrant of your settings
-.sp
-Vagrant will read your access credentials from your environment, so we need to set them there first. Make sure
-you have everything on amazon aws setup so you can (manually) deploy a new image to EC2.
-.sp
-.nf
-.ft C
-export AWS_ACCESS_KEY_ID=xxx
-export AWS_SECRET_ACCESS_KEY=xxx
-export AWS_KEYPAIR_NAME=xxx
-export AWS_SSH_PRIVKEY=xxx
-.ft P
-.fi
-.sp
-The environment variables are:
-.INDENT 3.0
-.IP \(bu 2
-\fBAWS_ACCESS_KEY_ID\fP \- The API key used to make requests to AWS
-.IP \(bu 2
-\fBAWS_SECRET_ACCESS_KEY\fP \- The secret key to make AWS API requests
-.IP \(bu 2
-\fBAWS_KEYPAIR_NAME\fP \- The name of the keypair used for this EC2 instance
-.IP \(bu 2
-\fBAWS_SSH_PRIVKEY\fP \- The path to the private key for the named keypair, for example \fB~/.ssh/docker.pem\fP
-.UNINDENT
-.sp
-You can check if they are set correctly by doing something like
-.sp
-.nf
-.ft C
-echo $AWS_ACCESS_KEY_ID
-.ft P
-.fi
-.IP 6. 3
-Do the magic!
-.sp
-.nf
-.ft C
-vagrant up \-\-provider=aws
-.ft P
-.fi
-.sp
-If it stalls indefinitely on \fB[default] Waiting for SSH to become available...\fP, Double check your default security
-zone on AWS includes rights to SSH (port 22) to your container.
-.sp
-If you have an advanced AWS setup, you might want to have a look at the \fI\%https://github.com/mitchellh/vagrant-aws\fP
-.IP 7. 3
-Connect to your machine
-.sp
-.nf
-.ft C
-vagrant ssh
-.ft P
-.fi
-.IP 8. 3
-Your first command
-.sp
-Now you are in the VM, run docker
-.sp
-.nf
-.ft C
-docker
-.ft P
-.fi
-.UNINDENT
-.sp
-Continue with the \fIhello_world\fP example.
-.SH EXAMPLES
-.sp
-Contents:
-.SS Hello World
-.sp
-This is the most basic example available for using docker
-.sp
-This example assumes you have Docker installed.
-.sp
-Download the ubuntu container
-.sp
-.nf
-.ft C
-# Download an ubuntu image
-docker pull ubuntu
-.ft P
-.fi
-.sp
-Alternatively you can select \fIbusybox\fP, a bare minimal linux system. The
-images are retrieved from the docker repository.
-.sp
-.nf
-.ft C
-#run a simple echo command, that will echo hello world back to the console over standard out.
-docker run ubuntu /bin/echo hello world
-.ft P
-.fi
-.sp
-\fBExplanation:\fP
-.INDENT 0.0
-.IP \(bu 2
-\fB"docker run"\fP run a command in a new container
-.IP \(bu 2
-\fB"ubuntu"\fP is the image we want to run the command inside of.
-.IP \(bu 2
-\fB"/bin/echo"\fP is the command we want to run in the container
-.IP \(bu 2
-\fB"hello world"\fP is the input for the echo command
-.UNINDENT
-.sp
-\fBVideo:\fP
-.sp
-See the example in action
-.sp
-Continue to the \fIhello_world_daemon\fP example.
-.SS Hello World Daemon
-.sp
-The most boring daemon ever written.
-.sp
-This example assumes you have Docker installed and with the ubuntu image already imported \fBdocker pull ubuntu\fP.
-We will use the ubuntu image to run a simple hello world daemon that will just print hello world to standard
-out every second. It will continue to do this until we stop it.
-.sp
-\fBSteps:\fP
-.sp
-.nf
-.ft C
-$ CONTAINER_ID=$(docker run \-d ubuntu /bin/sh \-c "while true; do echo hello world; sleep 1; done")
-.ft P
-.fi
-.sp
-We are going to run a simple hello world daemon in a new container made from the busybox daemon.
-.INDENT 0.0
-.IP \(bu 2
-\fB"docker run \-d "\fP run a command in a new container. We pass "\-d" so it runs as a daemon.
-.IP \(bu 2
-\fB"ubuntu"\fP is the image we want to run the command inside of.
-.IP \(bu 2
-\fB"/bin/sh \-c"\fP is the command we want to run in the container
-.IP \(bu 2
-\fB"while true; do echo hello world; sleep 1; done"\fP is the mini script we want to run, that will just print hello world once a second until we stop it.
-.IP \(bu 2
-\fB$CONTAINER_ID\fP the output of the run command will return a container id, we can use in future commands to see what is going on with this process.
-.UNINDENT
-.sp
-.nf
-.ft C
-$ docker logs $CONTAINER_ID
-.ft P
-.fi
-.sp
-Check the logs make sure it is working correctly.
-.INDENT 0.0
-.IP \(bu 2
-\fB"docker logs\fP" This will return the logs for a container
-.IP \(bu 2
-\fB$CONTAINER_ID\fP The Id of the container we want the logs for.
-.UNINDENT
-.sp
-.nf
-.ft C
-docker attach $CONTAINER_ID
-.ft P
-.fi
-.sp
-Attach to the container to see the results in realtime.
-.INDENT 0.0
-.IP \(bu 2
-\fB"docker attach\fP" This will allow us to attach to a background process to see what is going on.
-.IP \(bu 2
-\fB$CONTAINER_ID\fP The Id of the container we want to attach too.
-.UNINDENT
-.sp
-.nf
-.ft C
-docker ps
-.ft P
-.fi
-.sp
-Check the process list to make sure it is running.
-.INDENT 0.0
-.IP \(bu 2
-\fB"docker ps"\fP this shows all running process managed by docker
-.UNINDENT
-.sp
-.nf
-.ft C
-$ docker stop $CONTAINER_ID
-.ft P
-.fi
-.sp
-Stop the container, since we don\(aqt need it anymore.
-.INDENT 0.0
-.IP \(bu 2
-\fB"docker stop"\fP This stops a container
-.IP \(bu 2
-\fB$CONTAINER_ID\fP The Id of the container we want to stop.
-.UNINDENT
-.sp
-.nf
-.ft C
-docker ps
-.ft P
-.fi
-.sp
-Make sure it is really stopped.
-.sp
-\fBVideo:\fP
-.sp
-See the example in action
-.sp
-Continue to the \fIpython_web_app\fP example.
-.SS Notes:
-.INDENT 0.0
-.IP \(bu 2
-\fBDocker daemon\fP The docker daemon is started by \fBsudo docker \-d\fP, Vagrant may have started
-the Docker daemon for you, but you will need to restart it this way if it was terminated. Otherwise
-it may give you \fBCouldn\(aqt create Tag store: open /var/lib/docker/repositories: permission denied\fP
-.UNINDENT
-.SS Building a python web app
-.sp
-The goal of this example is to show you how you can author your own docker images using a parent image, making changes to it, and then saving the results as a new image. We will do that by making a simple hello flask web application image.
-.sp
-\fBSteps:\fP
-.sp
-.nf
-.ft C
-$ docker import shykes/pybuilder
-.ft P
-.fi
-.sp
-We are importing the "shykes/pybuilder" docker image
-.sp
-.nf
-.ft C
-$ URL=http://github.com/shykes/helloflask/archive/master.tar.gz
-.ft P
-.fi
-.sp
-We set a URL variable that points to a tarball of a simple helloflask web app
-.sp
-.nf
-.ft C
-$ BUILD_JOB=$(docker run \-t shykes/pybuilder:1d9aab3737242c65 /usr/local/bin/buildapp $URL)
-.ft P
-.fi
-.sp
-Inside of the "shykes/pybuilder" image there is a command called buildapp, we are running that command and passing the $URL variable from step 2 to it, and running the whole thing inside of a new container. BUILD_JOB will be set with the new container_id. "1d9aab3737242c65" came from the output of step 1 when importing image. also available from \(aqdocker images\(aq.
-.sp
-.nf
-.ft C
-$ docker attach $BUILD_JOB
-[...]
-.ft P
-.fi
-.sp
-We attach to the new container to see what is going on. Ctrl\-C to disconnect
-.sp
-.nf
-.ft C
-$ BUILD_IMG=$(docker commit $BUILD_JOB _/builds/github.com/hykes/helloflask/master)
-.ft P
-.fi
-.sp
-Save the changed we just made in the container to a new image called "_/builds/github.com/hykes/helloflask/master" and save the image id in the BUILD_IMG variable name.
-.sp
-.nf
-.ft C
-$ WEB_WORKER=$(docker run \-p 5000 $BUILD_IMG /usr/local/bin/runapp)
-.ft P
-.fi
-.sp
-Use the new image we just created and create a new container with network port 5000, and return the container id and store in the WEB_WORKER variable.
-.sp
-.nf
-.ft C
-$ docker logs $WEB_WORKER
- * Running on http://0.0.0.0:5000/
-.ft P
-.fi
-.sp
-view the logs for the new container using the WEB_WORKER variable, and if everything worked as planned you should see the line "Running on \fI\%http://0.0.0.0:5000/\fP" in the log output.
-.sp
-\fBVideo:\fP
-.sp
-See the example in action
-.sp
-Continue to the \fI\%base commands\fP
-.SH CONTRIBUTING
-.SS Contributing to Docker
-.sp
-Want to hack on Docker? Awesome! There are instructions to get you
-started on the website: \fI\%http://docker.io/gettingstarted.html\fP
-.sp
-They are probably not perfect, please let us know if anything feels
-wrong or incomplete.
-.SS Contribution guidelines
-.SS Pull requests are always welcome
-.sp
-We are always thrilled to receive pull requests, and do our best to
-process them as fast as possible. Not sure if that typo is worth a pull
-request? Do it! We will appreciate it.
-.sp
-If your pull request is not accepted on the first try, don\(aqt be
-discouraged! If there\(aqs a problem with the implementation, hopefully you
-received feedback on what to improve.
-.sp
-We\(aqre trying very hard to keep Docker lean and focused. We don\(aqt want it
-to do everything for everybody. This means that we might decide against
-incorporating a new feature. However, there might be a way to implement
-that feature \fIon top of\fP docker.
-.SS Discuss your design on the mailing list
-.sp
-We recommend discussing your plans \fI\%on the mailing
-list\fP
-before starting to code \- especially for more ambitious contributions.
-This gives other contributors a chance to point you in the right
-direction, give feedback on your design, and maybe point out if someone
-else is working on the same thing.
-.SS Create issues...
-.sp
-Any significant improvement should be documented as \fI\%a github
-issue\fP before anybody
-starts working on it.
-.SS ...but check for existing issues first!
-.sp
-Please take a moment to check that an issue doesn\(aqt already exist
-documenting your bug report or improvement proposal. If it does, it
-never hurts to add a quick "+1" or "I have this problem too". This will
-help prioritize the most common problems and requests.
-.SS Write tests
-.sp
-Golang has a great testing suite built in: use it! Take a look at
-existing tests for inspiration.
-.SS Setting up a dev environment
-.sp
-Instructions that have been verified to work on Ubuntu 12.10,
-.sp
-Then run the docker daemon,
-.sp
-Run the \fBgo install\fP command (above) to recompile docker.
-.SH COMMANDS
-.sp
-Contents:
-.SS Base commands
-.SS Running an interactive shell
-.sp
-.nf
-.ft C
-# Download an ubuntu image
-docker import ubuntu
-
-# Run an interactive shell in the ubuntu image,
-# allocate a tty, attach stdin and stdout
-docker run \-a \-i \-t ubuntu /bin/bash
-.ft P
-.fi
-.SS Starting a long\-running worker process
-.sp
-.nf
-.ft C
-# Run docker in daemon mode
-(docker \-d || echo "Docker daemon already running") &
-
-# Start a very useful long\-running process
-JOB=$(docker run ubuntu /bin/sh \-c "while true; do echo Hello world!; sleep 1; done")
-
-# Collect the output of the job so far
-docker logs $JOB
-
-# Kill the job
-docker kill $JOB
-.ft P
-.fi
-.SS Listing all running containers
-.sp
-.nf
-.ft C
-docker ps
-.ft P
-.fi
-.SS Expose a service on a TCP port
-.sp
-.nf
-.ft C
-# Expose port 4444 of this container, and tell netcat to listen on it
-JOB=$(docker run \-p 4444 ubuntu /bin/nc \-l \-p 4444)
-
-# Which public port is NATed to my container?
-PORT=$(docker port $JOB 4444)
-
-# Connect to the public port via the host\(aqs public address
-echo hello world | nc $(hostname) $PORT
-
-# Verify that the network connection worked
-echo "Daemon received: $(docker logs $JOB)"
-.ft P
-.fi
-.sp
-Continue to the complete \fI\%Command Line Interface\fP
-.SS Command Line Interface
-.SS Docker Usage
-.sp
-.nf
-.ft C
-$ docker
-  Usage: docker COMMAND [arg...]
-
-  A self\-sufficient runtime for linux containers.
-
-  Commands:
-      attach    Attach to a running container
-      commit    Create a new image from a container\(aqs changes
-      diff      Inspect changes on a container\(aqs filesystem
-      export    Stream the contents of a container as a tar archive
-      history   Show the history of an image
-      images    List images
-      import    Create a new filesystem image from the contents of a tarball
-      info      Display system\-wide information
-      inspect   Return low\-level information on a container
-      kill      Kill a running container
-      login     Register or Login to the docker registry server
-      logs      Fetch the logs of a container
-      port      Lookup the public\-facing port which is NAT\-ed to PRIVATE_PORT
-      ps        List containers
-      pull      Pull an image or a repository to the docker registry server
-      push      Push an image or a repository to the docker registry server
-      restart   Restart a running container
-      rm        Remove a container
-      rmi       Remove an image
-      run       Run a command in a new container
-      start     Start a stopped container
-      stop      Stop a running container
-      tag       Tag an image into a repository
-      version   Show the docker version information
-      wait      Block until a container stops, then print its exit code
-.ft P
-.fi
-.SS attach
-.sp
-.nf
-.ft C
-Usage: docker attach [OPTIONS]
-
-Attach to a running container
-
-  \-e=true: Attach to stderr
-  \-i=false: Attach to stdin
-  \-o=true: Attach to stdout
-.ft P
-.fi
-.SS commit
-.sp
-.nf
-.ft C
-Usage: docker commit [OPTIONS] CONTAINER [DEST]
-
-Create a new image from a container\(aqs changes
-
-\-m="": Commit message
-.ft P
-.fi
-.SS diff
-.sp
-.nf
-.ft C
-Usage: docker diff CONTAINER [OPTIONS]
-
-Inspect changes on a container\(aqs filesystem
-.ft P
-.fi
-.SS export
-.sp
-.nf
-.ft C
-Usage: docker export CONTAINER
-
-Export the contents of a filesystem as a tar archive
-.ft P
-.fi
-.SS history
-.sp
-.nf
-.ft C
-Usage: docker history [OPTIONS] IMAGE
-
-Show the history of an image
-.ft P
-.fi
-.SS images
-.sp
-.nf
-.ft C
-Usage: docker images [OPTIONS] [NAME]
-
-List images
-
-  \-a=false: show all images
-  \-q=false: only show numeric IDs
-.ft P
-.fi
-.SS import
-.sp
-Usage: docker import [OPTIONS] URL|\- [REPOSITORY [TAG]]
-.sp
-Create a new filesystem image from the contents of a tarball
-
-At this time, the URL must start with ``http`` and point to a single file archive
-(.tar, .tar.gz, .tgz, .bzip, .tar.xz, .txz)
-containing a root filesystem. If you would like to import from a local directory or archive,
-you can use the ``-`` parameter to take the data from standard in.
-
-.SS info
-.sp
-.nf
-.ft C
-Usage: docker info
-
-Display system\-wide information.
-.ft P
-.fi
-.SS inspect
-.sp
-.nf
-.ft C
-Usage: docker inspect [OPTIONS] CONTAINER
-
-Return low\-level information on a container
-.ft P
-.fi
-.SS kill
-.sp
-.nf
-.ft C
-Usage: docker kill [OPTIONS] CONTAINER [CONTAINER...]
-
-Kill a running container
-.ft P
-.fi
-.SS login
-.sp
-.nf
-.ft C
-Usage: docker login
-
-Register or Login to the docker registry server
-.ft P
-.fi
-.SS logs
-.sp
-.nf
-.ft C
-Usage: docker logs [OPTIONS] CONTAINER
-
-Fetch the logs of a container
-.ft P
-.fi
-.SS port
-.sp
-.nf
-.ft C
-Usage: docker port [OPTIONS] CONTAINER PRIVATE_PORT
-
-Lookup the public\-facing port which is NAT\-ed to PRIVATE_PORT
-.ft P
-.fi
-.SS ps
-.sp
-.nf
-.ft C
-Usage: docker ps [OPTIONS]
-
-List containers
-
-  \-a=false: Show all containers. Only running containers are shown by default.
-  \-notrunc=false: Don\(aqt truncate output
-  \-q=false: Only display numeric IDs
-.ft P
-.fi
-.SS pull
-.sp
-.nf
-.ft C
-Usage: docker pull NAME
-
-Pull an image or a repository from the registry
-.ft P
-.fi
-.SS push
-.sp
-.nf
-.ft C
-Usage: docker push NAME
-
-Push an image or a repository to the registry
-.ft P
-.fi
-.SS restart
-.sp
-.nf
-.ft C
-Usage: docker restart [OPTIONS] NAME
-
-Restart a running container
-.ft P
-.fi
-.SS rm
-.sp
-.nf
-.ft C
-Usage: docker rm [OPTIONS] CONTAINER
-
-Remove a container
-.ft P
-.fi
-.SS rmi
-.sp
-.nf
-.ft C
-Usage: docker rmi [OPTIONS] IMAGE
-
-Remove an image
-
-  \-a=false: Use IMAGE as a path and remove ALL images in this path
-  \-r=false: Use IMAGE as a regular expression instead of an exact name
-.ft P
-.fi
-.SS run
-.sp
-.nf
-.ft C
-Usage: docker run [OPTIONS] IMAGE COMMAND [ARG...]
-
-Run a command in a new container
-
-  \-a=false: Attach stdin and stdout
-  \-c="": Comment
-  \-i=false: Keep stdin open even if not attached
-  \-m=0: Memory limit (in bytes)
-  \-p=[]: Map a network port to the container
-  \-t=false: Allocate a pseudo\-tty
-  \-u="": Username or UID
-.ft P
-.fi
-.SS start
-.sp
-.nf
-.ft C
-Usage: docker start [OPTIONS] NAME
-
-Start a stopped container
-.ft P
-.fi
-.SS stop
-.sp
-.nf
-.ft C
-Usage: docker stop [OPTIONS] NAME
-
-Stop a running container
-.ft P
-.fi
-.SS tag
-.sp
-.nf
-.ft C
-Usage: docker tag [OPTIONS] IMAGE REPOSITORY [TAG]
-
-Tag an image into a repository
-
-  \-f=false: Force
-.ft P
-.fi
-.SS version
-.sp
-.nf
-.ft C
-Usage: docker version
-
-Show the docker version information
-.ft P
-.fi
-.SS wait
-.sp
-.nf
-.ft C
-Usage: docker wait [OPTIONS] NAME
-
-Block until a container stops, then print its exit code.
-.ft P
-.fi
-.SH FAQ
-.SS Most frequently asked questions.
-.sp
-\fB1. How much does Docker cost?\fP
-.sp
-Docker is 100% free, it is open source, so you can use it without paying.
-.sp
-\fB2. What open source license are you using?\fP
-.sp
-We are using the Apache License Version 2.0, see it here: \fI\%https://github.com/dotcloud/docker/blob/master/LICENSE\fP
-.sp
-\fB3. Does Docker run on Mac OS X or Windows?\fP
-.sp
-Not at this time, Docker currently only runs on Linux, but you can use VirtualBox to run Docker in a virtual machine on your box, and get the best of both worlds. Check out the \fI\%MacOSX\fP and \fI\%Windows\fP intallation guides.
-.sp
-\fB4. How do containers compare to virtual machines?\fP
-.sp
-They are complementary. VMs are best used to allocate chunks of hardware resources. Containers operate at the process level, which makes them very lightweight and perfect as a unit of software delivery.
-.sp
-\fB5. Can I help by adding some questions and answers?\fP
-.sp
-Definitely! You can fork \fI\%the repo\fP and edit the documentation sources.
-.sp
-\fB42. Where can I find more answers?\fP
-.sp
-You can find more answers on:
-.INDENT 0.0
-.IP \(bu 2
-\fI\%IRC: docker on freenode\fP
-.IP \(bu 2
-\fI\%Github\fP
-.IP \(bu 2
-\fI\%Ask questions on Stackoverflow\fP
-.IP \(bu 2
-\fI\%Join the conversation on Twitter\fP
-.UNINDENT
-.sp
-Looking for something else to read? Checkout the \fIhello_world\fP example.
-.SH AUTHOR
-Team Docker
-.SH COPYRIGHT
-2013, Team Docker
-.\" Generated by docutils manpage writer.
-.\" 
-.
diff --git a/packaging/debian/lxc-docker.init b/packaging/debian/lxc-docker.init
deleted file mode 100755
index b85acfe..0000000
--- a/packaging/debian/lxc-docker.init
+++ /dev/null
@@ -1,74 +0,0 @@
-#!/bin/sh
-
-### BEGIN INIT INFO
-# Provides:             lxc-docker
-# Required-Start:       $syslog $remote_fs
-# Required-Stop:        $syslog $remote_fs
-# Default-Start:        2 3 4 5
-# Default-Stop:         0 1 6
-# Short-Description:    Linux container runtime
-# Description:          Linux container runtime
-### END INIT INFO
-
-DOCKER=/usr/bin/lxc-docker
-
-# Check lxc-docker is present
-[ -x $DOCKER ] || (log_failure_msg "lxc-docker not present"; exit 1)
-
-PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/sbin:/usr/local/bin
-
-# Get lsb functions
-. /lib/lsb/init-functions
-
-check_root_id ()
-{
-  if [ "$(id -u)" != "0" ]; then
-    log_failure_msg "LXC Docker must be run as root"; exit 1
-  fi
-}
-
-case "$1" in
-  start)
-    check_root_id || exit 1
-    log_begin_msg "Starting LXC Docker"
-    mount | grep cgroup >/dev/null || mount -t cgroup none /sys/fs/cgroup
-    start-stop-daemon --start --background --exec "$DOCKER" -- -d
-    log_end_msg $?
-    ;;
-
-  stop)
-    check_root_id || exit 1
-    log_begin_msg "Stopping LXC Docker"
-    docker_pid=`pgrep -f "$DOCKER -d"`
-    [ -n "$docker_pid" ] && kill $docker_pid
-    log_end_msg $?
-    ;;
-
-  restart)
-    check_root_id || exit 1
-    docker_pid=`pgrep -f "$DOCKER -d"`
-    [ -n "$docker_pid" ] && /etc/init.d/lxc-docker stop
-    /etc/init.d/lxc-docker start
-    ;;
-
-  force-reload)
-    check_root_id || exit 1
-    /etc/init.d/lxc-docker restart
-    ;;
-
-  status)
-    docker_pid=`pgrep -f "$DOCKER -d"`
-    if [ -z "$docker_pid" ] ; then
-      echo "lxc-docker not running"
-    else
-      echo "lxc-docker running (pid $docker_pid)"
-    fi
-    ;;
-
-  *)
-    echo "Usage: /etc/init.d/lxc-docker {start|stop|restart|status}"
-    exit 1
-    ;;
-esac
-
-exit 0
diff --git a/packaging/debian/maintainer.rst b/packaging/debian/maintainer.rst
deleted file mode 100644
index 111d4fc..0000000
--- a/packaging/debian/maintainer.rst
+++ /dev/null
@@ -1,16 +0,0 @@
-Maintainer duty
-===============
-
-The Debian project specifies the role of a 'maintainer' which is the person
-making the Debian package of the program. This role requires an 'sponsor' to
-upload the package. As a maintainer you should follow the guide
-http://www.debian.org/doc/manuals/maint-guide . Your sponsor will be there
-helping you succeed.
-
-The most relevant information to update is the changelog file:
-Each new release should create a new first paragraph with new release version,
-changes, and the maintainer information.
-
-After this is done, follow README.debian to generate the actual source
-packages and talk with your sponsor to upload them into the official Debian
-package archive.
diff --git a/packaging/debian/parse_changelog.py b/packaging/debian/parse_changelog.py
deleted file mode 100755
index f14805d..0000000
--- a/packaging/debian/parse_changelog.py
+++ /dev/null
@@ -1,23 +0,0 @@
-#!/usr/bin/env python
-
-'Parse main CHANGELOG.md from stdin outputing on stdout the debian changelog'
-
-import sys,re, datetime
-
-on_block=False
-for line in sys.stdin.readlines():
-    line = line.strip()
-    if line.startswith('# ') or len(line) == 0:
-        continue
-    if line.startswith('## '):
-        if on_block:
-            print '\n -- dotCloud <ops@dotcloud.com>  {0}\n'.format(date)
-        version, date = line[3:].split()
-        date = datetime.datetime.strptime(date, '(%Y-%m-%d)').strftime(
-            '%a, %d %b %Y 00:00:00 -0700')
-        on_block = True
-        print 'lxc-docker ({0}-1) precise; urgency=low'.format(version)
-        continue
-    if on_block:
-        print '  ' + line
-print '\n -- dotCloud <ops@dotcloud.com>  {0}'.format(date)
diff --git a/packaging/debian/rules b/packaging/debian/rules
deleted file mode 100755
index b81f131..0000000
--- a/packaging/debian/rules
+++ /dev/null
@@ -1,7 +0,0 @@
-#!/usr/bin/make -f
-# -*- makefile -*-
-
-#export DH_VERBOSE=1
-
-%:
-	dh ${@} --with autotools_dev
diff --git a/packaging/debian/source/format b/packaging/debian/source/format
deleted file mode 100644
index 163aaf8..0000000
--- a/packaging/debian/source/format
+++ /dev/null
@@ -1 +0,0 @@
-3.0 (quilt)
diff --git a/packaging/ubuntu/Makefile b/packaging/ubuntu/Makefile
deleted file mode 100644
index a1e53b1..0000000
--- a/packaging/ubuntu/Makefile
+++ /dev/null
@@ -1,62 +0,0 @@
-# Ubuntu package Makefile
-#
-# Dependencies:  debhelper autotools-dev devscripts golang-stable
-# Notes:
-# Use 'make ubuntu' to create the ubuntu package and push it to stating PPA by
-# default. To push to production, set PUBLISH_PPA=1 before doing 'make ubuntu'
-# GPG_KEY environment variable needs to contain a GPG private key for package
-# to be signed and uploaded to docker PPA. If GPG_KEY is not defined,
-# make ubuntu will create docker package and exit with status code 2
-
-PKG_NAME=lxc-docker
-GITHUB_PATH=github.com/dotcloud/docker
-BUILD_SRC=${CURDIR}/../../build_src
-VERSION=$(shell sed -En '0,/^\#\# /{s/^\#\# ([^ ]+).+/\1/p}' ../../CHANGELOG.md)
-
-all:
-	# Compile docker. Used by dpkg-buildpackage.
-	cd src/${GITHUB_PATH}/docker; GOPATH=${CURDIR} CGO_ENABLED=0 go build -a -ldflags '-d -w'
-
-install:
-	# Used by dpkg-buildpackage
-	mkdir -p ${DESTDIR}/usr/bin
-	mkdir -p ${DESTDIR}/etc/init
-	mkdir -p ${DESTDIR}/DEBIAN
-	install -m 0755 src/${GITHUB_PATH}/docker/docker ${DESTDIR}/usr/bin
-	install -o root -m 0644 debian/docker.upstart ${DESTDIR}/etc/init/docker.conf
-	install debian/lxc-docker.prerm ${DESTDIR}/DEBIAN/prerm
-	install debian/lxc-docker.postinst ${DESTDIR}/DEBIAN/postinst
-
-ubuntu:
-	# This Makefile will compile the github master branch of dotcloud/docker
-	# Retrieve docker project and its go structure from internet
-	rm -rf ${BUILD_SRC}
-	git clone $(shell git rev-parse --show-toplevel) ${BUILD_SRC}/${GITHUB_PATH}
-	cd ${BUILD_SRC}/${GITHUB_PATH}; git checkout v${VERSION} && GOPATH=${BUILD_SRC} go get -d && cd ${BUILD_SRC}/src/${GITHUB_PATH} && git checkout v${VERSION}
-	# Add debianization
-	mkdir ${BUILD_SRC}/debian
-	cp Makefile ${BUILD_SRC}
-	cp -r * ${BUILD_SRC}/debian
-	cp ../../README.md ${BUILD_SRC}
-	./parse_changelog.py < ../../CHANGELOG.md  > ${BUILD_SRC}/debian/changelog
-	# Cleanup
-	for d in `find ${BUILD_SRC} -name '.git*'`; do rm -rf $$d; done
-	rm -rf ${BUILD_SRC}/../${PKG_NAME}_${VERSION}.orig.tar.gz
-	rm -rf ${BUILD_SRC}/pkg
-	# Create docker debian files
-	cd ${BUILD_SRC}; tar czf ../${PKG_NAME}_${VERSION}.orig.tar.gz .
-	cd ${BUILD_SRC}; dpkg-buildpackage -us -uc
-	rm -rf ${BUILD_SRC}
-	# Sign package and upload it to PPA if GPG_KEY environment variable
-	# holds a private GPG KEY
-	if /usr/bin/test "$${GPG_KEY}" == ""; then exit 2; fi
-	mkdir ${BUILD_SRC}
-	# Import gpg signing key
-	echo "$${GPG_KEY}" | gpg --allow-secret-key-import --import || true
-	# Sign the package
-	cd ${BUILD_SRC}; dpkg-source -x ${BUILD_SRC}/../${PKG_NAME}_${VERSION}-1.dsc
-	cd ${BUILD_SRC}/${PKG_NAME}-${VERSION}; debuild -S -sa
-	# Upload to PPA
-	if [ "${PUBLISH_PPA}" = "1" ];  then cd ${BUILD_SRC};dput ppa:dotcloud/lxc-docker ${PKG_NAME}_${VERSION}-1_source.changes; fi
-	if [ "${PUBLISH_PPA}" != "1" ]; then cd ${BUILD_SRC};dput ppa:dotcloud/docker-staging ${PKG_NAME}_${VERSION}-1_source.changes; fi
-	rm -rf ${BUILD_SRC}
diff --git a/packaging/ubuntu/README.ubuntu b/packaging/ubuntu/README.ubuntu
deleted file mode 100644
index 286a6f8..0000000
--- a/packaging/ubuntu/README.ubuntu
+++ /dev/null
@@ -1,37 +0,0 @@
-Docker on Ubuntu
-================
-
-The easiest way to get docker up and running natively on Ubuntu is installing
-it from its official PPA::
-
-  sudo sh -c "echo 'deb http://ppa.launchpad.net/dotcloud/lxc-docker/ubuntu precise main' >>/etc/apt/sources.list"
-  sudo apt-get update
-  sudo apt-get install lxc-docker
-
-
-Building docker package
-~~~~~~~~~~~~~~~~~~~~~~~
-
-The building process is shared by both, developers and maintainers. If you are
-a developer, the Makefile will stop with exit status 2 right before signing
-the built packages.
-
-Assuming you are working on an Ubuntu 12.04 TLS system ::
-
-  # Download a fresh copy of the docker project
-  git clone https://github.com/dotcloud/docker.git
-  cd docker
-
-  # Get building dependencies
-  sudo apt-get update; sudo apt-get install -y debhelper autotools-dev devscripts golang
-
-  # Make the ubuntu package
-  (cd packaging/ubuntu; make ubuntu)
-
-
-Install docker built package
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-
-::
-
-  sudo dpkg -i lxc-docker_*_amd64.deb; sudo apt-get install -f -y
diff --git a/packaging/ubuntu/Vagrantfile b/packaging/ubuntu/Vagrantfile
deleted file mode 100644
index 0636b01..0000000
--- a/packaging/ubuntu/Vagrantfile
+++ /dev/null
@@ -1,15 +0,0 @@
-GOPHERS_KEY = "308C15A29AD198E9"
-
-Vagrant::Config.run do |config|
-  config.vm.box = 'precise64'
-  config.vm.box_url = 'http://files.vagrantup.com/precise64.box'
-  config.vm.share_folder 'v-data', '/data/docker', "#{File.dirname(__FILE__)}/../.."
-
-  # Add docker PPA key to the local repository and install docker
-  pkg_cmd = "apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys #{GOPHERS_KEY}; " \
-    "echo 'deb http://ppa.launchpad.net/gophers/go/ubuntu precise main' >/etc/apt/sources.list.d/gophers-go.list; " \
-  # Install ubuntu packaging dependencies and create ubuntu packages
-  pkg_cmd << "export DEBIAN_FRONTEND=noninteractive; apt-get -qq update; apt-get install -qq -y git debhelper autotools-dev devscripts golang-stable; " \
-    "export GPG_KEY='#{ENV['GPG_KEY']}'; cd /data/docker/packaging/ubuntu; make ubuntu"
-  config.vm.provision :shell, :inline => pkg_cmd
-end
diff --git a/packaging/ubuntu/compat b/packaging/ubuntu/compat
deleted file mode 100644
index 45a4fb7..0000000
--- a/packaging/ubuntu/compat
+++ /dev/null
@@ -1 +0,0 @@
-8
diff --git a/packaging/ubuntu/control b/packaging/ubuntu/control
deleted file mode 100644
index 404f38a..0000000
--- a/packaging/ubuntu/control
+++ /dev/null
@@ -1,19 +0,0 @@
-Source: lxc-docker
-Section: misc
-Priority: extra
-Maintainer: Daniel Mizyrycki <daniel@dotcloud.com>
-Build-Depends: debhelper,autotools-dev,devscripts,golang-stable
-Standards-Version: 3.9.3
-Homepage: http://github.com/dotcloud/docker
-
-Package: lxc-docker
-Architecture: linux-any
-Depends: ${misc:Depends},${shlibs:Depends},lxc,bsdtar,aufs-tools
-Conflicts: docker
-Description: lxc-docker is a Linux container runtime
- Docker complements LXC with a high-level API which operates at the process
- level. It runs unix processes with strong guarantees of isolation and
- repeatability across servers.
- Docker is a great building block for automating distributed systems:
- large-scale web deployments, database clusters, continuous deployment systems,
- private PaaS, service-oriented architectures, etc.
diff --git a/packaging/ubuntu/copyright b/packaging/ubuntu/copyright
deleted file mode 100644
index 668c863..0000000
--- a/packaging/ubuntu/copyright
+++ /dev/null
@@ -1,237 +0,0 @@
-Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
-Upstream-Name: docker
-Upstream-Contact: DotCloud Inc <opensource@dotcloud.com>
-Source: http://github.com/dotcloud/docker
-
-Files: *
-Copyright: 2012, DotCloud Inc <opensource@dotcloud.com>
-License: Apache-2.0
- Apache License
- Version 2.0, January 2004
- http://www.apache.org/licenses/
- 
- TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
- 
- 1. Definitions.
- 
- "License" shall mean the terms and conditions for use, reproduction,
- and distribution as defined by Sections 1 through 9 of this document.
- 
- "Licensor" shall mean the copyright owner or entity authorized by
- the copyright owner that is granting the License.
- 
- "Legal Entity" shall mean the union of the acting entity and all
- other entities that control, are controlled by, or are under common
- control with that entity. For the purposes of this definition,
- "control" means (i) the power, direct or indirect, to cause the
- direction or management of such entity, whether by contract or
- otherwise, or (ii) ownership of fifty percent (50%) or more of the
- outstanding shares, or (iii) beneficial ownership of such entity.
- 
- "You" (or "Your") shall mean an individual or Legal Entity
- exercising permissions granted by this License.
- 
- "Source" form shall mean the preferred form for making modifications,
- including but not limited to software source code, documentation
- source, and configuration files.
- 
- "Object" form shall mean any form resulting from mechanical
- transformation or translation of a Source form, including but
- not limited to compiled object code, generated documentation,
- and conversions to other media types.
- 
- "Work" shall mean the work of authorship, whether in Source or
- Object form, made available under the License, as indicated by a
- copyright notice that is included in or attached to the work
- (an example is provided in the Appendix below).
- 
- "Derivative Works" shall mean any work, whether in Source or Object
- form, that is based on (or derived from) the Work and for which the
- editorial revisions, annotations, elaborations, or other modifications
- represent, as a whole, an original work of authorship. For the purposes
- of this License, Derivative Works shall not include works that remain
- separable from, or merely link (or bind by name) to the interfaces of,
- the Work and Derivative Works thereof.
- 
- "Contribution" shall mean any work of authorship, including
- the original version of the Work and any modifications or additions
- to that Work or Derivative Works thereof, that is intentionally
- submitted to Licensor for inclusion in the Work by the copyright owner
- or by an individual or Legal Entity authorized to submit on behalf of
- the copyright owner. For the purposes of this definition, "submitted"
- means any form of electronic, verbal, or written communication sent
- to the Licensor or its representatives, including but not limited to
- communication on electronic mailing lists, source code control systems,
- and issue tracking systems that are managed by, or on behalf of, the
- Licensor for the purpose of discussing and improving the Work, but
- excluding communication that is conspicuously marked or otherwise
- designated in writing by the copyright owner as "Not a Contribution."
- 
- "Contributor" shall mean Licensor and any individual or Legal Entity
- on behalf of whom a Contribution has been received by Licensor and
- subsequently incorporated within the Work.
- 
- 2. Grant of Copyright License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- copyright license to reproduce, prepare Derivative Works of,
- publicly display, publicly perform, sublicense, and distribute the
- Work and such Derivative Works in Source or Object form.
- 
- 3. Grant of Patent License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- (except as stated in this section) patent license to make, have made,
- use, offer to sell, sell, import, and otherwise transfer the Work,
- where such license applies only to those patent claims licensable
- by such Contributor that are necessarily infringed by their
- Contribution(s) alone or by combination of their Contribution(s)
- with the Work to which such Contribution(s) was submitted. If You
- institute patent litigation against any entity (including a
- cross-claim or counterclaim in a lawsuit) alleging that the Work
- or a Contribution incorporated within the Work constitutes direct
- or contributory patent infringement, then any patent licenses
- granted to You under this License for that Work shall terminate
- as of the date such litigation is filed.
- 
- 4. Redistribution. You may reproduce and distribute copies of the
- Work or Derivative Works thereof in any medium, with or without
- modifications, and in Source or Object form, provided that You
- meet the following conditions:
- 
- (a) You must give any other recipients of the Work or
- Derivative Works a copy of this License; and
- 
- (b) You must cause any modified files to carry prominent notices
- stating that You changed the files; and
- 
- (c) You must retain, in the Source form of any Derivative Works
- that You distribute, all copyright, patent, trademark, and
- attribution notices from the Source form of the Work,
- excluding those notices that do not pertain to any part of
- the Derivative Works; and
- 
- (d) If the Work includes a "NOTICE" text file as part of its
- distribution, then any Derivative Works that You distribute must
- include a readable copy of the attribution notices contained
- within such NOTICE file, excluding those notices that do not
- pertain to any part of the Derivative Works, in at least one
- of the following places: within a NOTICE text file distributed
- as part of the Derivative Works; within the Source form or
- documentation, if provided along with the Derivative Works; or,
- within a display generated by the Derivative Works, if and
- wherever such third-party notices normally appear. The contents
- of the NOTICE file are for informational purposes only and
- do not modify the License. You may add Your own attribution
- notices within Derivative Works that You distribute, alongside
- or as an addendum to the NOTICE text from the Work, provided
- that such additional attribution notices cannot be construed
- as modifying the License.
- 
- You may add Your own copyright statement to Your modifications and
- may provide additional or different license terms and conditions
- for use, reproduction, or distribution of Your modifications, or
- for any such Derivative Works as a whole, provided Your use,
- reproduction, and distribution of the Work otherwise complies with
- the conditions stated in this License.
- 
- 5. Submission of Contributions. Unless You explicitly state otherwise,
- any Contribution intentionally submitted for inclusion in the Work
- by You to the Licensor shall be under the terms and conditions of
- this License, without any additional terms or conditions.
- Notwithstanding the above, nothing herein shall supersede or modify
- the terms of any separate license agreement you may have executed
- with Licensor regarding such Contributions.
- 
- 6. Trademarks. This License does not grant permission to use the trade
- names, trademarks, service marks, or product names of the Licensor,
- except as required for reasonable and customary use in describing the
- origin of the Work and reproducing the content of the NOTICE file.
- 
- 7. Disclaimer of Warranty. Unless required by applicable law or
- agreed to in writing, Licensor provides the Work (and each
- Contributor provides its Contributions) on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
- implied, including, without limitation, any warranties or conditions
- of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
- PARTICULAR PURPOSE. You are solely responsible for determining the
- appropriateness of using or redistributing the Work and assume any
- risks associated with Your exercise of permissions under this License.
- 
- 8. Limitation of Liability. In no event and under no legal theory,
- whether in tort (including negligence), contract, or otherwise,
- unless required by applicable law (such as deliberate and grossly
- negligent acts) or agreed to in writing, shall any Contributor be
- liable to You for damages, including any direct, indirect, special,
- incidental, or consequential damages of any character arising as a
- result of this License or out of the use or inability to use the
- Work (including but not limited to damages for loss of goodwill,
- work stoppage, computer failure or malfunction, or any and all
- other commercial damages or losses), even if such Contributor
- has been advised of the possibility of such damages.
- 
- 9. Accepting Warranty or Additional Liability. While redistributing
- the Work or Derivative Works thereof, You may choose to offer,
- and charge a fee for, acceptance of support, warranty, indemnity,
- or other liability obligations and/or rights consistent with this
- License. However, in accepting such obligations, You may act only
- on Your own behalf and on Your sole responsibility, not on behalf
- of any other Contributor, and only if You agree to indemnify,
- defend, and hold each Contributor harmless for any liability
- incurred by, or claims asserted against, such Contributor by reason
- of your accepting any such warranty or additional liability.
- 
- END OF TERMS AND CONDITIONS
- 
- APPENDIX: How to apply the Apache License to your work.
- 
- To apply the Apache License to your work, attach the following
- boilerplate notice, with the fields enclosed by brackets "[]"
- replaced with your own identifying information. (Don't include
- the brackets!) The text should be enclosed in the appropriate
- comment syntax for the file format. We also recommend that a
- file or class name and description of purpose be included on the
- same "printed page" as the copyright notice for easier
- identification within third-party archives.
- 
- Copyright 2012 DotCloud Inc
- 
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
- 
- http://www.apache.org/licenses/LICENSE-2.0
- 
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
- 
- 
-Files: src/github.com/kr/pty/*
-Copyright: Copyright (c) 2011 Keith Rarick
-License: Expat
- Copyright (c) 2011 Keith Rarick
- 
- Permission is hereby granted, free of charge, to any person
- obtaining a copy of this software and associated
- documentation files (the "Software"), to deal in the
- Software without restriction, including without limitation
- the rights to use, copy, modify, merge, publish, distribute,
- sublicense, and/or sell copies of the Software, and to
- permit persons to whom the Software is furnished to do so,
- subject to the following conditions:
- 
- The above copyright notice and this permission notice shall
- be included in all copies or substantial portions of the
- Software.
- 
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY
- KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
- WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
- PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS
- OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR
- OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
- SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
diff --git a/packaging/ubuntu/docker.upstart b/packaging/ubuntu/docker.upstart
deleted file mode 100644
index 2370cb5..0000000
--- a/packaging/ubuntu/docker.upstart
+++ /dev/null
@@ -1,10 +0,0 @@
-description     "Run docker"
-
-start on filesystem and started lxc-net
-stop on runlevel [!2345]
-
-respawn
-
-script
-    /usr/bin/docker -d
-end script
diff --git a/packaging/ubuntu/docs b/packaging/ubuntu/docs
deleted file mode 100644
index b43bf86..0000000
--- a/packaging/ubuntu/docs
+++ /dev/null
@@ -1 +0,0 @@
-README.md
diff --git a/packaging/ubuntu/lxc-docker.postinst b/packaging/ubuntu/lxc-docker.postinst
deleted file mode 100644
index 5d04c5b..0000000
--- a/packaging/ubuntu/lxc-docker.postinst
+++ /dev/null
@@ -1,4 +0,0 @@
-#!/bin/sh
-
-# Start docker
-/sbin/start docker
diff --git a/packaging/ubuntu/lxc-docker.prerm b/packaging/ubuntu/lxc-docker.prerm
deleted file mode 100644
index aed7d97..0000000
--- a/packaging/ubuntu/lxc-docker.prerm
+++ /dev/null
@@ -1,4 +0,0 @@
-#!/bin/sh
-
-# Stop docker
-if [ "`pgrep -f '/usr/bin/docker -d'`" != "" ]; then /sbin/stop docker; fi
diff --git a/packaging/ubuntu/maintainer.ubuntu b/packaging/ubuntu/maintainer.ubuntu
deleted file mode 100644
index 07ab0a1..0000000
--- a/packaging/ubuntu/maintainer.ubuntu
+++ /dev/null
@@ -1,39 +0,0 @@
-Maintainer duty
-===============
-
-Ubuntu allows developers to use their PPA (Personal Package Archive)
-repository. This is very convenient for the users as they just need to add
-the PPA address, update their package database and use the apt-get tool.
-
-For now, the official lxc-docker package is located on launchpad and can be
-accessed adding the following line to /etc/apt/sources.list ::
-
-
-  deb http://ppa.launchpad.net/dotcloud/lxc-docker/ubuntu precise main
-
-
-Releasing a new package
-~~~~~~~~~~~~~~~~~~~~~~~
-
-The most relevant information to update is the packaging/ubuntu/changelog file:
-Each new release should create a new first paragraph with new release version,
-changes, and the maintainer information. The core of this paragraph is
-located on CHANGELOG.md. Make sure to transcribe it and translate the formats
-(eg: packaging/ubuntu/changelog uses 2 spaces for body change descriptions
-instead of 1 space from CHANGELOG.md)
-
-Assuming your PPA GPG signing key is on /media/usbdrive/docker.key, load it
-into the GPG_KEY environment variable with::
-
-  export GPG_KEY=`cat /media/usbdrive/docker.key`
-
-
-After this is done and you are ready to upload the package to the PPA, you have
-a couple of choices:
-
-* Follow packaging/ubuntu/README.ubuntu to generate the actual source packages
-  and upload them to the PPA
-
-* Let vagrant do all the work for you::
-
-  ( cd docker/packaging/ubuntu; vagrant up )
diff --git a/packaging/ubuntu/parse_changelog.py b/packaging/ubuntu/parse_changelog.py
deleted file mode 100755
index d19a342..0000000
--- a/packaging/ubuntu/parse_changelog.py
+++ /dev/null
@@ -1,23 +0,0 @@
-#!/usr/bin/env python
-
-'Parse main CHANGELOG.md from stdin outputing on stdout the ubuntu changelog'
-
-import sys,re, datetime
-
-on_block=False
-for line in sys.stdin.readlines():
-    line = line.strip()
-    if line.startswith('# ') or len(line) == 0:
-        continue
-    if line.startswith('## '):
-        if on_block:
-            print '\n -- dotCloud <ops@dotcloud.com>  {0}\n'.format(date)
-        version, date = line[3:].split()
-        date = datetime.datetime.strptime(date, '(%Y-%m-%d)').strftime(
-            '%a, %d %b %Y 00:00:00 -0700')
-        on_block = True
-        print 'lxc-docker ({0}-1) precise; urgency=low'.format(version)
-        continue
-    if on_block:
-        print '  ' + line
-print '\n -- dotCloud <ops@dotcloud.com>  {0}'.format(date)
diff --git a/packaging/ubuntu/rules b/packaging/ubuntu/rules
deleted file mode 100755
index 955dd78..0000000
--- a/packaging/ubuntu/rules
+++ /dev/null
@@ -1,13 +0,0 @@
-#!/usr/bin/make -f
-# -*- makefile -*-
-# Sample debian/rules that uses debhelper.
-# This file was originally written by Joey Hess and Craig Small.
-# As a special exception, when this file is copied by dh-make into a
-# dh-make output file, you may use that output file without restriction.
-# This special exception was added by Craig Small in version 0.37 of dh-make.
-
-# Uncomment this to turn on verbose mode.
-#export DH_VERBOSE=1
-
-%:
-	dh $@
diff --git a/packaging/ubuntu/source/format b/packaging/ubuntu/source/format
deleted file mode 100644
index 163aaf8..0000000
--- a/packaging/ubuntu/source/format
+++ /dev/null
@@ -1 +0,0 @@
-3.0 (quilt)
diff --git a/registry/registry.go b/registry/registry.go
index 770399e..0079215 100644
--- a/registry/registry.go
+++ b/registry/registry.go
@@ -72,7 +72,7 @@
 	}
 	validRepo := regexp.MustCompile(`^([a-z0-9-_.]+)$`)
 	if !validRepo.MatchString(name) {
-		return fmt.Errorf("Invalid repository name (%s), only [a-zA-Z0-9-_.] are allowed", name)
+		return fmt.Errorf("Invalid repository name (%s), only [a-z0-9-_.] are allowed", name)
 	}
 	return nil
 }
@@ -160,16 +160,16 @@
 	}
 	req.Header.Set("Authorization", "Token "+strings.Join(token, ", "))
 	res, err := doWithCookies(r.client, req)
-	if err != nil || res.StatusCode != 200 {
-		if res != nil {
-			if res.StatusCode == 401 {
-				return nil, ErrLoginRequired
-			}
-			return nil, utils.NewHTTPRequestError(fmt.Sprintf("Internal server error: %d trying to fetch remote history for %s", res.StatusCode, imgID), res)
-		}
+	if err != nil {
 		return nil, err
 	}
 	defer res.Body.Close()
+	if res.StatusCode != 200 {
+		if res.StatusCode == 401 {
+			return nil, ErrLoginRequired
+		}
+		return nil, utils.NewHTTPRequestError(fmt.Sprintf("Server error: %d trying to fetch remote history for %s", res.StatusCode, imgID), res)
+	}
 
 	jsonString, err := ioutil.ReadAll(res.Body)
 	if err != nil {
@@ -240,6 +240,7 @@
 		return nil, err
 	}
 	if res.StatusCode != 200 {
+		res.Body.Close()
 		return nil, fmt.Errorf("Server error: Status %d while fetching image layer (%s)",
 			res.StatusCode, imgID)
 	}
diff --git a/runtime.go b/runtime.go
index aff1773..f218521 100644
--- a/runtime.go
+++ b/runtime.go
@@ -174,7 +174,8 @@
 		close(container.waitLock)
 	} else if !nomonitor {
 		container.allocateNetwork()
-		go container.monitor()
+		// hostConfig isn't needed here and can be nil
+		go container.monitor(nil)
 	}
 	return nil
 }
@@ -234,7 +235,7 @@
 			fmt.Printf("\b%c", wheel[i%4])
 		}
 		if err != nil {
-			utils.Debugf("Failed to load container %v: %v", id, err)
+			utils.Errorf("Failed to load container %v: %v", id, err)
 			continue
 		}
 		utils.Debugf("Loaded container %v", container.ID)
@@ -282,7 +283,9 @@
 	}
 
 	if img.Config != nil {
-		MergeConfig(config, img.Config)
+		if err := MergeConfig(config, img.Config); err != nil {
+			return nil, err
+		}
 	}
 
 	if len(config.Entrypoint) != 0 && config.Cmd == nil {
diff --git a/runtime_test.go b/runtime_test.go
index f4f5d5a..1abbcc5 100644
--- a/runtime_test.go
+++ b/runtime_test.go
@@ -42,6 +42,7 @@
 		}(container)
 	}
 	wg.Wait()
+	runtime.networkManager.Close()
 	return os.RemoveAll(runtime.root)
 }
 
@@ -88,11 +89,18 @@
 
 	// Make it our Store root
 	if runtime, err := NewRuntimeFromDirectory(unitTestStoreBase, false); err != nil {
-		panic(err)
+		log.Fatalf("Unable to create a runtime for tests:", err)
 	} else {
 		globalRuntime = runtime
 	}
 
+	// Cleanup any leftover container
+	for _, container := range globalRuntime.List() {
+		if err := globalRuntime.Destroy(container); err != nil {
+			log.Fatalf("Error destroying leftover container: %s", err)
+		}
+	}
+
 	// Create the "Server"
 	srv := &Server{
 		runtime:     globalRuntime,
@@ -104,13 +112,13 @@
 	if img, err := globalRuntime.repositories.LookupImage(unitTestImageName); err != nil || img.ID != unitTestImageID {
 		// Retrieve the Image
 		if err := srv.ImagePull(unitTestImageName, "", os.Stdout, utils.NewStreamFormatter(false), nil, nil, true); err != nil {
-			panic(err)
+			log.Fatalf("Unable to pull the test image:", err)
 		}
 	}
 	// Spawn a Daemon
 	go func() {
 		if err := ListenAndServe(testDaemonProto, testDaemonAddr, srv, os.Getenv("DEBUG") != ""); err != nil {
-			panic(err)
+			log.Fatalf("Unable to spawn the test daemon:", err)
 		}
 	}()
 
@@ -125,14 +133,15 @@
 func GetTestImage(runtime *Runtime) *Image {
 	imgs, err := runtime.graph.Map()
 	if err != nil {
-		panic(err)
+		log.Fatalf("Unable to get the test image:", err)
 	}
 	for _, image := range imgs {
 		if image.ID == unitTestImageID {
 			return image
 		}
 	}
-	panic(fmt.Errorf("Test image %v not found", unitTestImageID))
+	log.Fatalf("Test image %v not found", unitTestImageID)
+	return nil
 }
 
 func TestRuntimeCreate(t *testing.T) {
@@ -203,6 +212,29 @@
 	if err == nil {
 		t.Fatal("Builder.Create should throw an error when Cmd is empty")
 	}
+
+	config := &Config{
+		Image:     GetTestImage(runtime).ID,
+		Cmd:       []string{"/bin/ls"},
+		PortSpecs: []string{"80"},
+	}
+	container, err = runtime.Create(config)
+
+	image, err := runtime.Commit(container, "testrepo", "testtag", "", "", config)
+	if err != nil {
+		t.Error(err)
+	}
+
+	_, err = runtime.Create(
+		&Config{
+			Image:     image.ID,
+			PortSpecs: []string{"80000:80"},
+		},
+	)
+	if err == nil {
+		t.Fatal("Builder.Create should throw an error when PortSpecs is invalid")
+	}
+
 }
 
 func TestDestroy(t *testing.T) {
diff --git a/server.go b/server.go
index 88c32d1..27d1968 100644
--- a/server.go
+++ b/server.go
@@ -16,6 +16,7 @@
 	"os"
 	"os/exec"
 	"path"
+	"path/filepath"
 	"runtime"
 	"strings"
 	"sync"
@@ -428,7 +429,7 @@
 
 		// ensure no two downloads of the same layer happen at the same time
 		if err := srv.poolAdd("pull", "layer:"+id); err != nil {
-			utils.Debugf("Image (id: %s) pull is already running, skipping: %v", id, err)
+			utils.Errorf("Image (id: %s) pull is already running, skipping: %v", id, err)
 			return nil
 		}
 		defer srv.poolRemove("pull", "layer:"+id)
@@ -477,7 +478,7 @@
 	utils.Debugf("Retrieving the tag list")
 	tagsList, err := r.GetRemoteTags(repoData.Endpoints, remoteName, repoData.Tokens)
 	if err != nil {
-		utils.Debugf("%v", err)
+		utils.Errorf("%v", err)
 		return err
 	}
 
@@ -525,7 +526,7 @@
 
 			// ensure no two downloads of the same image happen at the same time
 			if err := srv.poolAdd("pull", "img:"+img.ID); err != nil {
-				utils.Debugf("Image (id: %s) pull is already running, skipping: %v", img.ID, err)
+				utils.Errorf("Image (id: %s) pull is already running, skipping: %v", img.ID, err)
 				if parallel {
 					errors <- nil
 				}
@@ -958,6 +959,8 @@
 		volumes := make(map[string]struct{})
 		// Store all the deleted containers volumes
 		for _, volumeId := range container.Volumes {
+			volumeId = strings.TrimRight(volumeId, "/layer")
+			volumeId = filepath.Base(volumeId)
 			volumes[volumeId] = struct{}{}
 		}
 		if err := srv.runtime.Destroy(container); err != nil {
@@ -1177,47 +1180,52 @@
 	return fmt.Errorf("No such container: %s", name)
 }
 
-func (srv *Server) ContainerAttach(name string, logs, stream, stdin, stdout, stderr bool, in io.ReadCloser, out io.Writer) error {
+func (srv *Server) ContainerAttach(name string, logs, stream, stdin, stdout, stderr bool, inStream io.ReadCloser, outStream, errStream io.Writer) error {
 	container := srv.runtime.Get(name)
 	if container == nil {
 		return fmt.Errorf("No such container: %s", name)
 	}
+
 	//logs
 	if logs {
 		cLog, err := container.ReadLog("json")
 		if err != nil && os.IsNotExist(err) {
 			// Legacy logs
-			utils.Debugf("Old logs format")
+			utils.Errorf("Old logs format")
 			if stdout {
 				cLog, err := container.ReadLog("stdout")
 				if err != nil {
-					utils.Debugf("Error reading logs (stdout): %s", err)
-				} else if _, err := io.Copy(out, cLog); err != nil {
-					utils.Debugf("Error streaming logs (stdout): %s", err)
+					utils.Errorf("Error reading logs (stdout): %s", err)
+				} else if _, err := io.Copy(outStream, cLog); err != nil {
+					utils.Errorf("Error streaming logs (stdout): %s", err)
 				}
 			}
 			if stderr {
 				cLog, err := container.ReadLog("stderr")
 				if err != nil {
-					utils.Debugf("Error reading logs (stderr): %s", err)
-				} else if _, err := io.Copy(out, cLog); err != nil {
-					utils.Debugf("Error streaming logs (stderr): %s", err)
+					utils.Errorf("Error reading logs (stderr): %s", err)
+				} else if _, err := io.Copy(errStream, cLog); err != nil {
+					utils.Errorf("Error streaming logs (stderr): %s", err)
 				}
 			}
 		} else if err != nil {
-			utils.Debugf("Error reading logs (json): %s", err)
+			utils.Errorf("Error reading logs (json): %s", err)
 		} else {
 			dec := json.NewDecoder(cLog)
 			for {
-				var l utils.JSONLog
-				if err := dec.Decode(&l); err == io.EOF {
+				l := &utils.JSONLog{}
+
+				if err := dec.Decode(l); err == io.EOF {
 					break
 				} else if err != nil {
-					utils.Debugf("Error streaming logs: %s", err)
+					utils.Errorf("Error streaming logs: %s", err)
 					break
 				}
-				if (l.Stream == "stdout" && stdout) || (l.Stream == "stderr" && stderr) {
-					fmt.Fprintf(out, "%s", l.Log)
+				if l.Stream == "stdout" && stdout {
+					fmt.Fprintf(outStream, "%s", l.Log)
+				}
+				if l.Stream == "stderr" && stderr {
+					fmt.Fprintf(errStream, "%s", l.Log)
 				}
 			}
 		}
@@ -1240,16 +1248,16 @@
 			go func() {
 				defer w.Close()
 				defer utils.Debugf("Closing buffered stdin pipe")
-				io.Copy(w, in)
+				io.Copy(w, inStream)
 			}()
 			cStdin = r
-			cStdinCloser = in
+			cStdinCloser = inStream
 		}
 		if stdout {
-			cStdout = out
+			cStdout = outStream
 		}
 		if stderr {
-			cStderr = out
+			cStderr = errStream
 		}
 
 		<-container.Attach(cStdin, cStdinCloser, cStdout, cStderr)
diff --git a/server_test.go b/server_test.go
index ad87b4d..ee9549d 100644
--- a/server_test.go
+++ b/server_test.go
@@ -108,6 +108,45 @@
 
 }
 
+func TestCreateRmVolumes(t *testing.T) {
+	runtime := mkRuntime(t)
+	defer nuke(runtime)
+
+	srv := &Server{runtime: runtime}
+
+	config, hostConfig, _, err := ParseRun([]string{"-v", "/srv", GetTestImage(runtime).ID, "echo test"}, nil)
+	if err != nil {
+		t.Fatal(err)
+	}
+
+	id, err := srv.ContainerCreate(config)
+	if err != nil {
+		t.Fatal(err)
+	}
+
+	if len(runtime.List()) != 1 {
+		t.Errorf("Expected 1 container, %v found", len(runtime.List()))
+	}
+
+	err = srv.ContainerStart(id, hostConfig)
+	if err != nil {
+		t.Fatal(err)
+	}
+
+	err = srv.ContainerStop(id, 1)
+	if err != nil {
+		t.Fatal(err)
+	}
+
+	if err = srv.ContainerDestroy(id, true); err != nil {
+		t.Fatal(err)
+	}
+
+	if len(runtime.List()) != 0 {
+		t.Errorf("Expected 0 container, %v found", len(runtime.List()))
+	}
+}
+
 func TestCommit(t *testing.T) {
 	runtime := mkRuntime(t)
 	defer nuke(runtime)
diff --git a/state.go b/state.go
index 6480b9b..484032b 100644
--- a/state.go
+++ b/state.go
@@ -13,6 +13,7 @@
 	Pid       int
 	ExitCode  int
 	StartedAt time.Time
+	FinishedAt time.Time
 	Ghost     bool
 }
 
@@ -38,5 +39,6 @@
 func (s *State) setStopped(exitCode int) {
 	s.Running = false
 	s.Pid = 0
+	s.FinishedAt = time.Now()
 	s.ExitCode = exitCode
 }
diff --git a/term/term.go b/term/term.go
index 5929c2c..8c53a20 100644
--- a/term/term.go
+++ b/term/term.go
@@ -21,11 +21,19 @@
 func GetWinsize(fd uintptr) (*Winsize, error) {
 	ws := &Winsize{}
 	_, _, err := syscall.Syscall(syscall.SYS_IOCTL, fd, uintptr(syscall.TIOCGWINSZ), uintptr(unsafe.Pointer(ws)))
+	// Skipp errno = 0
+	if err == 0 {
+		return ws, nil
+	}
 	return ws, err
 }
 
 func SetWinsize(fd uintptr, ws *Winsize) error {
 	_, _, err := syscall.Syscall(syscall.SYS_IOCTL, fd, uintptr(syscall.TIOCSWINSZ), uintptr(unsafe.Pointer(ws)))
+	// Skipp errno = 0
+	if err == 0 {
+		return nil
+	}
 	return err
 }
 
diff --git a/testing/MAINTAINERS b/testing/MAINTAINERS
deleted file mode 100644
index 5dfc881..0000000
--- a/testing/MAINTAINERS
+++ /dev/null
@@ -1 +0,0 @@
-Daniel Mizyrycki <daniel@dotcloud.com> (@mzdaniel)
diff --git a/testing/README.rst b/testing/README.rst
deleted file mode 100644
index ce5aa83..0000000
--- a/testing/README.rst
+++ /dev/null
@@ -1,58 +0,0 @@
-=======
-testing
-=======
-
-This directory contains testing related files.
-
-
-Buildbot
-========
-
-Buildbot is a continuous integration system designed to automate the
-build/test cycle. By automatically rebuilding and testing the tree each time
-something has changed, build problems are pinpointed quickly, before other
-developers are inconvenienced by the failure.
-
-We are running buildbot in an AWS instance to verify docker passes all tests
-when commits get pushed to the master branch.
-
-You can check docker's buildbot instance at http://docker-ci.dotcloud.com/waterfall
-
-
-Deployment
-~~~~~~~~~~
-
-::
-
-  # Define AWS credential environment variables
-  export AWS_ACCESS_KEY_ID=xxxxxxxxxxxx
-  export AWS_SECRET_ACCESS_KEY=xxxxxxxxxxxx
-  export AWS_KEYPAIR_NAME=xxxxxxxxxxxx
-  export AWS_SSH_PRIVKEY=xxxxxxxxxxxx
-
-  # Define email recipient and IRC channel
-  export EMAIL_RCP=xxxxxx@domain.com
-  export IRC_CHANNEL=docker
-
-  # Define buildbot credentials
-  export BUILDBOT_PWD=xxxxxxxxxxxx
-  export IRC_PWD=xxxxxxxxxxxx
-  export SMTP_USER=xxxxxxxxxxxx
-  export SMTP_PWD=xxxxxxxxxxxx
-
-  # Define docker registry functional test credentials
-  export REGISTRY_USER=xxxxxxxxxxxx
-  export REGISTRY_PWD=xxxxxxxxxxxx
-
-  # Checkout docker
-  git clone git://github.com/dotcloud/docker.git
-
-  # Deploy docker on AWS
-  cd docker/testing
-  vagrant up --provider=aws
-
-
-Buildbot AWS dependencies
--------------------------
-
-vagrant, virtualbox packages and vagrant aws plugin
diff --git a/testing/Vagrantfile b/testing/Vagrantfile
deleted file mode 100644
index 1d15709..0000000
--- a/testing/Vagrantfile
+++ /dev/null
@@ -1,74 +0,0 @@
-# -*- mode: ruby -*-
-# vi: set ft=ruby :
-
-BOX_NAME = "docker-ci"
-BOX_URI = "http://cloud-images.ubuntu.com/vagrant/raring/current/raring-server-cloudimg-amd64-vagrant-disk1.box"
-AWS_AMI = "ami-10314d79"
-DOCKER_PATH = "/data/docker"
-CFG_PATH = "#{DOCKER_PATH}/testing/buildbot"
-on_vbox = File.file?("#{File.dirname(__FILE__)}/.vagrant/machines/default/virtualbox/id") | \
-  Dir.glob("#{File.dirname(__FILE__)}/.vagrant/machines/default/*/id").empty? & \
-  (on_vbox=true; ARGV.each do |arg| on_vbox &&= !arg.downcase.start_with?("--provider") end; on_vbox)
-USER = on_vbox ? "vagrant": "ubuntu"
-
-Vagrant::Config.run do |config|
-  # Setup virtual machine box. This VM configuration code is always executed.
-  config.vm.box = BOX_NAME
-  config.vm.box_url = BOX_URI
-  config.vm.forward_port 8010, 8010
-  config.vm.share_folder "v-data", DOCKER_PATH, "#{File.dirname(__FILE__)}/.."
-
-
-  # Deploy buildbot and its dependencies if it was not done
-  if Dir.glob("#{File.dirname(__FILE__)}/.vagrant/machines/default/*/id").empty?
-    # Add memory limitation capabilities
-    pkg_cmd = 'sed -Ei \'s/^(GRUB_CMDLINE_LINUX_DEFAULT)=.+/\\1="cgroup_enable=memory swapaccount=1 quiet"/\' /etc/default/grub; '
-    # Adjust kernel
-    pkg_cmd << "apt-get update -qq; "
-    if on_vbox
-      pkg_cmd << "apt-get install -q -y linux-image-extra-`uname -r`; "
-    else
-      pkg_cmd << "apt-get install -q -y linux-image-generic; "
-    end
-
-    # Deploy buildbot CI
-    pkg_cmd << "apt-get install -q -y python-dev python-pip supervisor; " \
-      "pip install -r #{CFG_PATH}/requirements.txt; " \
-      "chown #{USER}.#{USER} /data; cd /data; " \
-      "#{CFG_PATH}/setup.sh #{USER} #{CFG_PATH} #{ENV['BUILDBOT_PWD']} " \
-        "#{ENV['IRC_PWD']} #{ENV['IRC_CHANNEL']} #{ENV['SMTP_USER']} " \
-        "#{ENV['SMTP_PWD']} #{ENV['EMAIL_RCP']}; " \
-      "#{CFG_PATH}/setup_credentials.sh #{USER} " \
-        "#{ENV['REGISTRY_USER']} #{ENV['REGISTRY_PWD']}; "
-    # Install docker and testing dependencies
-    pkg_cmd << "curl -s https://go.googlecode.com/files/go1.1.2.linux-amd64.tar.gz | " \
-      "  tar -v -C /usr/local -xz; ln -s /usr/local/go/bin/go /usr/bin/go; " \
-      "curl -s https://phantomjs.googlecode.com/files/phantomjs-1.9.1-linux-x86_64.tar.bz2 | " \
-      "  tar jx -C /usr/bin --strip-components=2 phantomjs-1.9.1-linux-x86_64/bin/phantomjs; " \
-      "DEBIAN_FRONTEND=noninteractive apt-get install -q -y lxc git mercurial aufs-tools make libfontconfig; " \
-      "export GOPATH=/data/docker-dependencies; go get -d github.com/dotcloud/docker; " \
-      "rm -rf ${GOPATH}/src/github.com/dotcloud/docker; "
-    # Activate new kernel options
-    pkg_cmd << "shutdown -r +1; "
-    config.vm.provision :shell, :inline => pkg_cmd
-  end
-end
-
-# Providers were added on Vagrant >= 1.1.0
-Vagrant::VERSION >= "1.1.0" and Vagrant.configure("2") do |config|
-  config.vm.provider :aws do |aws, override|
-    aws.tags = { 'Name' => 'docker-ci' }
-    aws.access_key_id = ENV["AWS_ACCESS_KEY_ID"]
-    aws.secret_access_key = ENV["AWS_SECRET_ACCESS_KEY"]
-    aws.keypair_name = ENV["AWS_KEYPAIR_NAME"]
-    override.ssh.private_key_path = ENV["AWS_SSH_PRIVKEY"]
-    override.ssh.username = USER
-    aws.ami = AWS_AMI
-    aws.region = "us-east-1"
-    aws.instance_type = "m1.small"
-    aws.security_groups = "gateway"
-  end
-
-  config.vm.provider :virtualbox do |vb|
-  end
-end
diff --git a/testing/buildbot/README.rst b/testing/buildbot/README.rst
deleted file mode 100644
index 7edbf32..0000000
--- a/testing/buildbot/README.rst
+++ /dev/null
@@ -1 +0,0 @@
-Buildbot configuration and setup files (except Vagrantfile located on ..)
diff --git a/testing/buildbot/credentials.cfg b/testing/buildbot/credentials.cfg
deleted file mode 100644
index fbdd35d..0000000
--- a/testing/buildbot/credentials.cfg
+++ /dev/null
@@ -1,5 +0,0 @@
-# Credentials for tests. Buildbot source this file on tests
-# when needed.
-
-# Docker registry credentials. Format: 'username:password'
-export DOCKER_CREDS=''
diff --git a/testing/buildbot/setup_credentials.sh b/testing/buildbot/setup_credentials.sh
deleted file mode 100755
index f093815..0000000
--- a/testing/buildbot/setup_credentials.sh
+++ /dev/null
@@ -1,17 +0,0 @@
-#!/bin/bash
-
-# Setup of test credentials. Called by Vagrantfile
-export PATH="/bin:sbin:/usr/bin:/usr/sbin:/usr/local/bin"
-
-USER=$1
-REGISTRY_USER=$2
-REGISTRY_PWD=$3
-
-BUILDBOT_PATH="/data/buildbot"
-DOCKER_PATH="/data/docker"
-
-function run { su $USER -c "$1"; }
-
-run "cp $DOCKER_PATH/testing/buildbot/credentials.cfg $BUILDBOT_PATH/master"
-cd $BUILDBOT_PATH/master
-run "sed -i -E 's#(export DOCKER_CREDS=).+#\1\"$REGISTRY_USER:$REGISTRY_PWD\"#' credentials.cfg"
diff --git a/testing/functionaltests/test_registry.sh b/testing/functionaltests/test_registry.sh
deleted file mode 100755
index 095a731..0000000
--- a/testing/functionaltests/test_registry.sh
+++ /dev/null
@@ -1,11 +0,0 @@
-#!/bin/sh
-
-# Cleanup
-rm -rf docker-registry
-
-# Get latest docker registry
-git clone https://github.com/dotcloud/docker-registry.git
-
-# Configure and run registry tests
-cd docker-registry; cp config_sample.yml config.yml
-cd test; python -m unittest workflow
diff --git a/utils.go b/utils.go
index aed8ffd..8d821e8 100644
--- a/utils.go
+++ b/utils.go
@@ -65,7 +65,7 @@
 	return true
 }
 
-func MergeConfig(userConf, imageConf *Config) {
+func MergeConfig(userConf, imageConf *Config) error {
 	if userConf.User == "" {
 		userConf.User = imageConf.User
 	}
@@ -83,9 +83,15 @@
 	} else {
 		for _, imagePortSpec := range imageConf.PortSpecs {
 			found := false
-			imageNat, _ := parseNat(imagePortSpec)
+			imageNat, err := parseNat(imagePortSpec)
+			if err != nil {
+				return err
+			}
 			for _, userPortSpec := range userConf.PortSpecs {
-				userNat, _ := parseNat(userPortSpec)
+				userNat, err := parseNat(userPortSpec)
+				if err != nil {
+					return err
+				}
 				if imageNat.Proto == userNat.Proto && imageNat.Backend == userNat.Backend {
 					found = true
 				}
@@ -146,6 +152,7 @@
 			userConf.Volumes[k] = v
 		}
 	}
+	return nil
 }
 
 func parseLxcConfOpts(opts ListOpts) ([]KeyValuePair, error) {
diff --git a/utils/stdcopy.go b/utils/stdcopy.go
new file mode 100644
index 0000000..3cb8ab0
--- /dev/null
+++ b/utils/stdcopy.go
@@ -0,0 +1,154 @@
+package utils
+
+import (
+	"encoding/binary"
+	"errors"
+	"io"
+)
+
+const (
+	StdWriterPrefixLen = 8
+	StdWriterFdIndex   = 0
+	StdWriterSizeIndex = 4
+)
+
+type StdType [StdWriterPrefixLen]byte
+
+var (
+	Stdin  StdType = StdType{0: 0}
+	Stdout StdType = StdType{0: 1}
+	Stderr StdType = StdType{0: 2}
+)
+
+type StdWriter struct {
+	io.Writer
+	prefix  StdType
+	sizeBuf []byte
+}
+
+func (w *StdWriter) Write(buf []byte) (n int, err error) {
+	if w == nil || w.Writer == nil {
+		return 0, errors.New("Writer not instanciated")
+	}
+	binary.BigEndian.PutUint32(w.prefix[4:], uint32(len(buf)))
+	buf = append(w.prefix[:], buf...)
+
+	n, err = w.Writer.Write(buf)
+	return n - StdWriterPrefixLen, err
+}
+
+// NewStdWriter instanciates a new Writer.
+// Everything written to it will be encapsulated using a custom format,
+// and written to the underlying `w` stream.
+// This allows multiple write streams (e.g. stdout and stderr) to be muxed into a single connection.
+// `t` indicates the id of the stream to encapsulate.
+// It can be utils.Stdin, utils.Stdout, utils.Stderr.
+func NewStdWriter(w io.Writer, t StdType) *StdWriter {
+	if len(t) != StdWriterPrefixLen {
+		return nil
+	}
+
+	return &StdWriter{
+		Writer:  w,
+		prefix:  t,
+		sizeBuf: make([]byte, 4),
+	}
+}
+
+var ErrInvalidStdHeader = errors.New("Unrecognized input header")
+
+// StdCopy is a modified version of io.Copy.
+//
+// StdCopy will demultiplex `src`, assuming that it contains two streams,
+// previously multiplexed together using a StdWriter instance.
+// As it reads from `src`, StdCopy will write to `dstout` and `dsterr`.
+//
+// StdCopy will read until it hits EOF on `src`. It will then return a nil error.
+// In other words: if `err` is non nil, it indicates a real underlying error.
+//
+// `written` will hold the total number of bytes written to `dstout` and `dsterr`.
+func StdCopy(dstout, dsterr io.Writer, src io.Reader) (written int64, err error) {
+	var (
+		buf       = make([]byte, 32*1024+StdWriterPrefixLen+1)
+		bufLen    = len(buf)
+		nr, nw    int
+		er, ew    error
+		out       io.Writer
+		frameSize int
+	)
+
+	for {
+		// Make sure we have at least a full header
+		for nr < StdWriterPrefixLen {
+			var nr2 int
+			nr2, er = src.Read(buf[nr:])
+			if er == io.EOF {
+				return written, nil
+			}
+			if er != nil {
+				return 0, er
+			}
+			nr += nr2
+		}
+
+		// Check the first byte to know where to write
+		switch buf[StdWriterFdIndex] {
+		case 0:
+			fallthrough
+		case 1:
+			// Write on stdout
+			out = dstout
+		case 2:
+			// Write on stderr
+			out = dsterr
+		default:
+			Debugf("Error selecting output fd: (%d)", buf[StdWriterFdIndex])
+			return 0, ErrInvalidStdHeader
+		}
+
+		// Retrieve the size of the frame
+		frameSize = int(binary.BigEndian.Uint32(buf[StdWriterSizeIndex : StdWriterSizeIndex+4]))
+
+		// Check if the buffer is big enough to read the frame.
+		// Extend it if necessary.
+		if frameSize+StdWriterPrefixLen > bufLen {
+			Debugf("Extending buffer cap.")
+			buf = append(buf, make([]byte, frameSize-len(buf)+1)...)
+			bufLen = len(buf)
+		}
+
+		// While the amount of bytes read is less than the size of the frame + header, we keep reading
+		for nr < frameSize+StdWriterPrefixLen {
+			var nr2 int
+			nr2, er = src.Read(buf[nr:])
+			if er == io.EOF {
+				return written, nil
+			}
+			if er != nil {
+				Debugf("Error reading frame: %s", er)
+				return 0, er
+			}
+			nr += nr2
+		}
+
+		// Write the retrieved frame (without header)
+		nw, ew = out.Write(buf[StdWriterPrefixLen : frameSize+StdWriterPrefixLen])
+		if nw > 0 {
+			written += int64(nw)
+		}
+		if ew != nil {
+			Debugf("Error writing frame: %s", ew)
+			return 0, ew
+		}
+		// If the frame has not been fully written: error
+		if nw != frameSize {
+			Debugf("Error Short Write: (%d on %d)", nw, frameSize)
+			return 0, io.ErrShortWrite
+		}
+
+		// Move the rest of the buffer to the beginning
+		copy(buf, buf[frameSize+StdWriterPrefixLen:])
+		// Move the index
+		nr -= frameSize + StdWriterPrefixLen
+	}
+}
diff --git a/utils/utils.go b/utils/utils.go
index d417690..b0327dd 100644
--- a/utils/utils.go
+++ b/utils/utils.go
@@ -45,24 +45,31 @@
 	return resp, nil
 }
 
+func logf(level string, format string, a ...interface{}) {
+	// Retrieve the stack infos
+	_, file, line, ok := runtime.Caller(2)
+	if !ok {
+		file = "<unknown>"
+		line = -1
+	} else {
+		file = file[strings.LastIndex(file, "/")+1:]
+	}
+
+	fmt.Fprintf(os.Stderr, fmt.Sprintf("[%s] %s:%d %s\n", level, file, line, format), a...)
+}
+
 // Debug function, if the debug flag is set, then display. Do nothing otherwise
 // If Docker is in damon mode, also send the debug info on the socket
 func Debugf(format string, a ...interface{}) {
 	if os.Getenv("DEBUG") != "" {
-
-		// Retrieve the stack infos
-		_, file, line, ok := runtime.Caller(1)
-		if !ok {
-			file = "<unknown>"
-			line = -1
-		} else {
-			file = file[strings.LastIndex(file, "/")+1:]
-		}
-
-		fmt.Fprintf(os.Stderr, fmt.Sprintf("[debug] %s:%d %s\n", file, line, format), a...)
+		logf("debug", format, a...)
 	}
 }
 
+func Errorf(format string, a ...interface{}) {
+	logf("error", format, a...)
+}
+
 // Reader with progress bar
 type progressReader struct {
 	reader       io.ReadCloser // Stream to read from
@@ -319,7 +326,7 @@
 
 func GetTotalUsedFds() int {
 	if fds, err := ioutil.ReadDir(fmt.Sprintf("/proc/%d/fd", os.Getpid())); err != nil {
-		Debugf("Error opening /proc/%d/fd: %s", os.Getpid(), err)
+		Errorf("Error opening /proc/%d/fd: %s", os.Getpid(), err)
 	} else {
 		return len(fds)
 	}
@@ -771,7 +778,7 @@
 func GetResolvConf() ([]byte, error) {
 	resolv, err := ioutil.ReadFile("/etc/resolv.conf")
 	if err != nil {
-		Debugf("Error openning resolv.conf: %s", err)
+		Errorf("Error openning resolv.conf: %s", err)
 		return nil, err
 	}
 	return resolv, nil
@@ -1021,3 +1028,13 @@
 func (e *StatusError) Error() string {
 	return fmt.Sprintf("Status: %d", e.Status)
 }
+
+func IsClosedError(err error) bool {
+	/* This comparison is ugly, but unfortunately, net.go doesn't export errClosing.
+	 * See:
+	 * http://golang.org/src/pkg/net/net.go
+	 * https://code.google.com/p/go/issues/detail?id=4337
+	 * https://groups.google.com/forum/#!msg/golang-nuts/0_aaCvBmOcM/SptmDyX1XJMJ
+	 */
+	return strings.HasSuffix(err.Error(), "use of closed network connection")
+}
diff --git a/vendor/src/github.com/kr/pty/pty_linux.go b/vendor/src/github.com/kr/pty/pty_linux.go
index 3df1847..a5edfbb 100644
--- a/vendor/src/github.com/kr/pty/pty_linux.go
+++ b/vendor/src/github.com/kr/pty/pty_linux.go
@@ -28,7 +28,7 @@
 		return nil, nil, err
 	}
 
-	t, err := os.OpenFile(sname, os.O_RDWR, 0)
+	t, err := os.OpenFile(sname, os.O_RDWR|syscall.O_NOCTTY, 0)
 	if err != nil {
 		return nil, nil, err
 	}