# Install docker on Debian

## Install Guide:

1. Install packages:

```bash
sudo apt install apt-transport-https ca-certificates curl software-properties-common gnupg2
```

2\. Import GPG Key:

```bash
curl -fsSL https://download.docker.com/linux/debian/gpg | sudo apt-key add -
```

3\. Add Repo:

```bash
sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/debian $(lsb_release -cs) stable"
```

4\. Install Docker CE:

```bash
sudo apt install docker-ce
```

5\. Verify Docker:

```bash
sudo systemctl status docker
```

{% hint style="info" %}
Output should look like:

```bash
● docker.service - Docker Application Container Engine
Loaded: loaded (/lib/systemd/system/docker.service; enabled; vendor preset: enabled)
Active: active (running) since Tue 2019-07-30 20:52:00 GMT; 1min 11s ago
    Docs: https://docs.docker.com
```

{% endhint %}

6\. Add user to docker group

{% hint style="info" %}
Optional to avoid using <mark style="color:green;">`sudo`</mark> all the time
{% endhint %}

```bash
sudo usermod -aG docker $USER
```

## Resources

* [Official installation guide from Docker site](https://docs.docker.com/engine/install/debian/)


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.arkannis.net/containerization/docker/install-docker-on-debian.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
