11---
22description : Instructions for installing Docker on Debian
3- keywords : Docker, Docker documentation, requirements, apt, installation, debian, install, uninstall, upgrade, update
3+ keywords : Docker, Docker documentation, requirements, apt, installation, debian, raspbian, install, uninstall, upgrade, update
44redirect_from :
55- /engine/installation/debian/
6- title : Get Docker for Debian
6+ - /engine/installation/linux/raspbian/
7+ title : Get Docker for Debian or Raspbian
78---
89
910To get started with Docker on Debian, make sure you
@@ -14,10 +15,11 @@ To get started with Docker on Debian, make sure you
1415
1516### OS requirements
1617
17- To install Docker, you need the 64-bit version of one of these Debian versions:
18+ To install Docker, you need the 64-bit version of one of these Debian or
19+ Raspbian versions:
1820
1921- Stretch (testing)
20- - Jessie 8.0 (LTS)
22+ - Jessie 8.0 (LTS) / Raspbian Jessie
2123- Wheezy 7.7 (LTS)
2224
2325#### Extra steps for Wheezy 7.7
@@ -34,16 +36,6 @@ To install Docker, you need the 64-bit version of one of these Debian versions:
3436- Enable the ` backports ` repository. See the
3537 [ Debian documentation] ( https://backports.debian.org/Instructions/ ) {: target="_ blank" class"_ "}.
3638
37- ### Recommended extra packages
38-
39- You need ` curl ` if you don't have it.
40-
41- ``` bash
42- $ sudo apt-get update
43-
44- $ sudo apt-get install curl
45- ```
46-
4739## Install Docker
4840
4941You can install Docker in different ways, depending on your needs:
@@ -74,27 +66,29 @@ Docker from the repository.
7466 ** Jessie or Stretch** :
7567
7668 ``` bash
77- $ sudo apt-get install apt-transport-https \
78- ca-certificates \
79- software-properties-common
69+ $ sudo apt-get install -y --no-install-recommends
70+ apt-transport-https \
71+ ca-certificates \
72+ curl \
73+ software-properties-common
8074 ```
8175
8276 ** Wheezy** :
8377
8478 ` ` ` bash
85- $ sudo apt-get install apt-transport-https \
86- ca-certificates \
87- python-software-properties
79+ $ sudo apt-get install -y --no-install-recommends \
80+ apt-transport-https \
81+ ca-certificates \
82+ curl \
83+ python-software-properties
8884 ` ` `
8985
90862. Add Docker' s official GPG key:
9187
9288 ```bash
93- $ curl -fsSL https://yum .dockerproject.org/gpg | sudo apt-key add -
89+ $ curl -fsSL https://apt .dockerproject.org/gpg | sudo apt-key add -
9490 ```
9591
96- > **Note**: The URL is correct, even for Linux distributions that use `APT`.
97-
9892 Verify that the key ID is `58118E89F3A912897C070ADBF76221572C52609D`.
9993
10094 ```bash
@@ -105,20 +99,32 @@ Docker from the repository.
10599 uid Docker Release Tool (releasedocker) <docker@docker.com>
106100 ```
107101
108- 3. Use the following command to set up the **stable** repository. To also
109- enable the **testing** repository, add the words `testing` after `main` on
110- the last line.
111- **Do not use these unstable repositories on production systems or for non-testing workloads.**
102+ 3. Use the following command to set up the **stable** repository.
112103
113- ```bash
114- $ sudo add-apt-repository \
115- "deb https://apt.dockerproject.org/repo/ \
116- debian-$(lsb_release -cs) \
117- main"
118- ```
104+ > **Note**: The `lsb_release -cs` sub-command below returns the name of your
105+ > Debian distribution, such as `jessie`.
106+
107+ - **Debian**:
108+
109+ ```bash
110+ $ sudo add-apt-repository \
111+ "deb https://apt.dockerproject.org/repo/ \
112+ debian-$(lsb_release -cs) \
113+ main"
114+ ```
119115
120- To disable the `testing` repository, you can edit `/etc/apt/sources.list`
121- and remove the word `testing` from the appropriate line in the file.
116+ - **Raspbian**:
117+
118+ ```bash
119+ $ sudo add-apt-repository \
120+ "deb https://apt.dockerproject.org/repo/ \
121+ raspbian-$(lsb_release -cs) \
122+ main"
123+ ```
124+
125+ To enable the `testing` repository, you can edit `/etc/apt/sources.list`
126+ and add the word `testing` after `main` on the appropriate line of the file.
127+ **Do not use unstable repositories on production systems or for non-testing workloads.**
122128
123129#### Install Docker
124130
@@ -166,7 +172,11 @@ Docker from the repository.
166172 $ sudo apt-get -y install docker-engine=<VERSION_STRING>
167173 ```
168174
169- The Docker daemon starts automatically.
175+ On Debian, the Docker daemon starts automatically. On Raspbian, start Docker:
176+
177+ ```bash
178+ $ sudo service docker start
179+ ```
170180
1711814. Verify that `docker` is installed correctly by running the `hello-world`
172182 image.
@@ -197,7 +207,7 @@ a new file each time you want to upgrade Docker.
197207
1982081. Go to [https://apt.dockerproject.org/repo/pool/main/d/docker-engine/](https://apt.dockerproject.org/repo/pool/main/d/docker-engine/)
199209 and download the ` .deb` file for the Docker version you want to install and
200- for your version of Debian.
210+ for your version of Debian or Raspbian .
201211
202212 > ** Note** : To install a testing version, change the word ` main` in the
203213 > URL to ` testing` . Do not use unstable versions of Docker in production
@@ -210,7 +220,11 @@ a new file each time you want to upgrade Docker.
210220 $ sudo dpkg -i /path/to/package.deb
211221 ` ` `
212222
213- The Docker daemon starts automatically.
223+ On Debian, the Docker daemon starts automatically. On Raspbian, start Docker:
224+
225+ ` ` ` bash
226+ $ sudo service docker start
227+ ` ` `
214228
2152293. Verify that ` docker` is installed correctly by running the ` hello-world`
216230 image.
0 commit comments