Skip to content

Commit b634746

Browse files
author
Patrick M
committed
fix: update docker install instructions for debian 13
1 parent 551e4a3 commit b634746

File tree

1 file changed

+6
-30
lines changed

1 file changed

+6
-30
lines changed

src/data/blog/2023/lxc-docker-setup.md

Lines changed: 6 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ curl -s https://gist.githubusercontent.com/binarypatrick/1e9fcb79eec72fd82bde63a
2121
Then you'll need to login and install docker.
2222

2323
```bash
24-
sudo apt install docker.io -y && sudo systemctl enable docker
24+
sudo apt update && sudo apt install docker.io docker-compose -y && sudo systemctl enable docker
2525
```
2626

2727
Then start and confirm the service
@@ -30,41 +30,17 @@ Then start and confirm the service
3030
sudo systemctl start docker && sudo systemctl status docker
3131
```
3232

33-
To ensure Docker is running correctly you can try to run a simple hello-world container
34-
35-
```bash
36-
sudo docker run hello-world
37-
```
38-
39-
## Install Docker Compose
40-
41-
Debian unfortunately only ships with docker compose v1. The plugin for v2 needs to be [installed from dockers package repo](https://docs.docker.com/engine/install/debian/#install-using-the-repository)
42-
43-
```bash
44-
# Add Docker's official GPG key:
45-
sudo apt-get update
46-
sudo apt-get install ca-certificates curl gnupg
47-
sudo install -m 0755 -d /etc/apt/keyrings
48-
curl -fsSL https://download.docker.com/linux/debian/gpg | sudo gpg --dearmor -o /etc/apt/keyrings/docker.gpg
49-
sudo chmod a+r /etc/apt/keyrings/docker.gpg
50-
51-
# Add the repository to apt sources:
52-
echo \
53-
"deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/debian \
54-
$(. /etc/os-release && echo "$VERSION_CODENAME") stable" | \
55-
sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
56-
```
57-
58-
Then update and install docker compose
33+
Now check to make sure v2 is installed
5934

6035
```bash
61-
sudo apt update && sudo apt install docker-compose-plugin
36+
docker version
37+
docker compose version
6238
```
6339

64-
Now check to make sure v2 is installed
40+
To ensure Docker is running correctly you can try to run a simple hello-world container
6541

6642
```bash
67-
docker compose version
43+
sudo docker run hello-world
6844
```
6945

7046
## Run Docker from a non-root user without sudo

0 commit comments

Comments
 (0)