From 88afc8992f2ebd2fd95d87dfff720ff946183975 Mon Sep 17 00:00:00 2001 From: James Turnbull Date: Sat, 17 May 2014 22:28:39 +0200 Subject: [PATCH] Added basic Debian installation page Docker-DCO-1.1-Signed-off-by: James Turnbull (github: jamtur01) --- docs/mkdocs.yml | 1 + docs/sources/installation.md | 3 +- docs/sources/installation/debian.md | 77 +++++++++++++++++++++++++++++ 3 files changed, 80 insertions(+), 1 deletion(-) create mode 100644 docs/sources/installation/debian.md diff --git a/docs/mkdocs.yml b/docs/mkdocs.yml index 32d0852791..ca1a4d74ef 100755 --- a/docs/mkdocs.yml +++ b/docs/mkdocs.yml @@ -37,6 +37,7 @@ pages: - ['installation/mac.md', 'Installation', 'Mac OS X'] - ['installation/ubuntulinux.md', 'Installation', 'Ubuntu'] - ['installation/rhel.md', 'Installation', 'Red Hat Enterprise Linux'] +- ['installation/debian.md', 'Installation', 'Debian'] - ['installation/gentoolinux.md', 'Installation', 'Gentoo'] - ['installation/google.md', 'Installation', 'Google Cloud Platform'] - ['installation/rackspace.md', 'Installation', 'Rackspace Cloud'] diff --git a/docs/sources/installation.md b/docs/sources/installation.md index 66b28b2b3c..1c3c726594 100644 --- a/docs/sources/installation.md +++ b/docs/sources/installation.md @@ -12,6 +12,7 @@ techniques for installing Docker all the time. - [Ubuntu](ubuntulinux/) - [Red Hat Enterprise Linux](rhel/) - [Fedora](fedora/) + - [Debian](debian/) - [Arch Linux](archlinux/) - [CRUX Linux](cruxlinux/) - [Gentoo](gentoolinux/) @@ -22,4 +23,4 @@ techniques for installing Docker all the time. - [Amazon EC2](amazon/) - [Rackspace Cloud](rackspace/) - [Google Cloud Platform](google/) - - [Binaries](binaries/) \ No newline at end of file + - [Binaries](binaries/) diff --git a/docs/sources/installation/debian.md b/docs/sources/installation/debian.md new file mode 100644 index 0000000000..3deda47637 --- /dev/null +++ b/docs/sources/installation/debian.md @@ -0,0 +1,77 @@ +page_title: Installation on Debian +page_description: Instructions for installing Docker on Debian +page_keywords: Docker, Docker documentation, installation, debian + +# Debian + +> **Note**: +> Docker is still under heavy development! We don't recommend using it in +> production yet, but we're getting closer with each release. Please see +> our blog post, [Getting to Docker 1.0]( +> http://blog.docker.io/2013/08/getting-to-docker-1-0/) + +Docker is supported on the following versions of Debian: + + - [*Debian 8.0 Jessie (64-bit)*](#debian-jessie-8-64-bit) + +## Debian Jessie 8.0 (64-bit) + +Debian 8 comes with a 3.14.0 Linux kernel, and a `docker.io` package which +installs all its prerequisites from Debian's repository. + +> **Note**: +> Debian contains a much older KDE3/GNOME2 package called ``docker``, so the +> package and the executable are called ``docker.io``. + +### Installation + +To install the latest Debian package (may not be the latest Docker release): + + $ sudo apt-get update + $ sudo apt-get install docker.io + $ sudo ln -sf /usr/bin/docker.io /usr/local/bin/docker + +To verify that everything has worked as expected: + + $ sudo docker run -i -t ubuntu /bin/bash + +Which should download the `ubuntu` image, and then start `bash` in a container. + +> **Note**: +> If you want to enable memory and swap accounting see +> [this](/installation/ubuntulinux/#memory-and-swap-accounting). + +### Giving non-root access + +The `docker` daemon always runs as the `root` user, and since Docker +version 0.5.2, the `docker` daemon binds to a Unix socket instead of a +TCP port. By default that Unix socket is owned by the user `root`, and +so, by default, you can access it with `sudo`. + +Starting in version 0.5.3, if you (or your Docker installer) create a +Unix group called `docker` and add users to it, then the `docker` daemon +will make the ownership of the Unix socket read/writable by the `docker` +group when the daemon starts. The `docker` daemon must always run as the +root user, but if you run the `docker` client as a user in the `docker` +group then you don't need to add `sudo` to all the client commands. From +Docker 0.9.0 you can use the `-G` flag to specify an alternative group. + +> **Warning**: +> The `docker` group (or the group specified with the `-G` flag) is +> `root`-equivalent; see [*Docker Daemon Attack Surface*]( +> /articles/security/#dockersecurity-daemon) details. + +**Example:** + + # Add the docker group if it doesn't already exist. + $ sudo groupadd docker + + # Add the connected user "${USER}" to the docker group. + # Change the user name to match your preferred user. + # You may have to logout and log back in again for + # this to take effect. + $ sudo gpasswd -a ${USER} docker + + # Restart the Docker daemon. + $ sudo service docker restart +