Skip to content

Commit a3dbc59

Browse files
committed
Update according to @rfay's recommendations
1 parent 864fb9e commit a3dbc59

File tree

2 files changed

+68
-52
lines changed

2 files changed

+68
-52
lines changed

public/img/blog/2026/01/ddev-podman-docker-rootless.png renamed to public/img/blog/2026/02/ddev-podman-docker-rootless.png

File renamed without changes.

src/content/blog/podman-and-docker-rootless.md

Lines changed: 68 additions & 52 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,18 @@
11
---
22
title: "Podman and Docker Rootless in DDEV"
3-
pubDate: 2026-01-08
4-
#modifiedDate: 2026-01-08
3+
pubDate: 2026-02-03
4+
#modifiedDate: 2026-02-03
55
summary: After years of development, DDEV now supports Podman and Docker Rootless for secure, rootless container development.
66
author: Stas Zhuk
77
featureImage:
8-
src: /img/blog/2026/01/ddev-podman-docker-rootless.png
8+
src: /img/blog/2026/02/ddev-podman-docker-rootless.png
99
alt: DDEV logo with Podman and Docker logos
1010
categories:
1111
- Announcements
1212
- Guides
1313
---
1414

15-
**TL;DR**: DDEV now supports Podman and Docker Rootless in [DDEV HEAD](https://docs.ddev.com/en/stable/developers/building-contributing/#testing-latest-commits-on-head) (coming in v1.25.0). Podman and Docker Rootless are a bit more trouble than the [recommended normal traditional docker providers](https://docs.ddev.com/en/stable/users/install/docker-installation/) and have some serious trade-offs. On macOS you can't use the normal default ports 80 and 443. On Linux Docker Rootless you can't bind-mount directories, so the entire project has to mutagen-synced.
15+
**TL;DR**: DDEV supports Podman and Docker Rootless as of v1.25.0. Podman and Docker Rootless are a bit more trouble than the [recommended normal traditional Docker providers](https://docs.ddev.com/en/stable/users/install/docker-installation/) and have some serious trade-offs. On macOS you can't use the normal default ports 80 and 443. On Linux Docker Rootless you can't bind-mount directories, so the entire project has to be mutagen-synced.
1616

1717
Jump to setup instructions: [Linux/WSL2](#key-aim-linux-and-wsl2-users) · [macOS](#macos) · [Windows](#windows)
1818

@@ -25,17 +25,20 @@ Jump to setup instructions: [Linux/WSL2](#key-aim-linux-and-wsl2-users) · [macO
2525
- [Why Choose Podman?](#why-choose-podman)
2626
- [Why Choose Docker Rootless?](#why-choose-docker-rootless)
2727
- [Key aim: Linux and WSL2 users](#key-aim-linux-and-wsl2-users)
28+
- [Do You Need an Alternative to Docker?](#do-you-need-an-alternative-to-docker)
2829
- [Installing Podman](#installing-podman)
2930
- [Installing Docker CLI](#installing-docker-cli)
3031
- [Configuring Podman Rootless](#configuring-podman-rootless)
3132
- [Podman Rootless Performance Optimization](#podman-rootless-performance-optimization)
3233
- [Configuring Podman Rootful](#configuring-podman-rootful)
3334
- [Setting Up Docker Rootless](#setting-up-docker-rootless)
3435
- [macOS](#macos)
36+
- [Do You Need an Alternative to Docker?](#do-you-need-an-alternative-to-docker-1)
3537
- [Installing Podman](#installing-podman-1)
3638
- [Installing Docker CLI](#installing-docker-cli-1)
3739
- [Configuring Podman](#configuring-podman)
3840
- [Windows](#windows)
41+
- [Do You Need an Alternative to Docker?](#do-you-need-an-alternative-to-docker-2)
3942
- [Installing Podman](#installing-podman-2)
4043
- [Running Multiple Container Runtimes](#running-multiple-container-runtimes)
4144
- [Switching Runtimes with DDEV](#switching-runtimes-with-ddev)
@@ -86,6 +89,19 @@ Unlike Podman which is rootless by default, Docker Rootless requires special set
8689

8790
The primary focus for this article is Linux and WSL2 (we have test coverage for Linux only for now). Most features and configurations are well-tested on these platforms.
8891

92+
### Do You Need an Alternative to Docker?
93+
94+
Before diving into setup, consider whether you need an alternative to traditional Docker:
95+
96+
| Runtime | Why would you do this? | Key trade-offs | Performance | Setup | Recommendation |
97+
| ---------------------- | ---------------------------------------------------- | -------------------------------------------------------------------------------- | --------------------------- | -------- | ------------------------------------------------ |
98+
| **Traditional Docker** | Standard, widely-used option | None | Excellent | Simple | **Recommended for most users** |
99+
| **Docker Rootless** | Security requirement for rootless daemon | Must use `--no-bind-mounts` (everything via Mutagen), can't use default workflow | Moderate (Mutagen overhead) | Moderate | Only if rootless security is required |
100+
| **Podman Rootful** | Organization forbids Docker | Slower than Docker, different behavior | Slower than Docker | Moderate | Only if Docker not allowed |
101+
| **Podman Rootless** | Organization forbids Docker + want rootless security | May need sysctl changes for ports <1024, slower than Docker | Slower than Docker | Moderate | Only if Docker not allowed and rootless required |
102+
103+
**Bottom line**: Stick with traditional Docker unless organizational policy or security requirements force you to use an alternative. The alternatives work, but have significant trade-offs.
104+
89105
### Installing Podman
90106

91107
Install Podman using your distribution's package manager. See the [official Podman installation guide for Linux](https://podman.io/docs/installation#installing-on-linux).
@@ -120,7 +136,7 @@ Podman provides a Docker-compatible API, which means you can use the Docker CLI
120136

121137
This is the recommended configuration for most users.
122138

123-
1. Prepare the system:
139+
1. Prepare the system by configuring subuid and subgid ranges and enabling userns options, see the [Arch Linux Wiki](https://wiki.archlinux.org/title/Podman#Rootless_Podman) for details:
124140

125141
```bash
126142
# Add subuid and subgid ranges if they don't exist for the current user
@@ -151,9 +167,7 @@ This is the recommended configuration for most users.
151167
fi
152168
```
153169

154-
For more details, see the [Arch Linux Wiki](https://wiki.archlinux.org/title/Podman).
155-
156-
2. Enable the Podman socket and verify it's running:
170+
2. Enable the Podman socket and verify it's running ([Podman socket activation documentation](https://github.com/containers/podman/blob/main/docs/tutorials/socket_activation.md)):
157171

158172
```bash
159173
systemctl --user enable --now podman.socket
@@ -165,9 +179,7 @@ This is the recommended configuration for most users.
165179
podman info --format '{{.Host.RemoteSocket.Path}}'
166180
```
167181

168-
For more details, see the [Podman socket activation documentation](https://github.com/containers/podman/blob/main/docs/tutorials/socket_activation.md).
169-
170-
3. Configure Docker API to use Podman:
182+
3. Configure Docker API to use Podman ([Podman rootless tutorial](https://github.com/containers/podman/blob/main/docs/tutorials/rootless_tutorial.md)):
171183

172184
```bash
173185
# View existing contexts
@@ -185,8 +197,6 @@ This is the recommended configuration for most users.
185197
docker ps
186198
```
187199

188-
For more details, see [Podman rootless tutorial](https://github.com/containers/podman/blob/main/docs/tutorials/rootless_tutorial.md)
189-
190200
4. Proceed with [DDEV installation](https://docs.ddev.com/en/stable/users/install/ddev-installation/#ddev-installation-linux).
191201

192202
### Podman Rootless Performance Optimization
@@ -335,6 +345,15 @@ Docker Rootless on Linux offers rootless security with full Docker compatibility
335345
336346
macOS users can use Podman and Podman Desktop, but setup has its own challenges. Docker Rootless is not available on macOS.
337347
348+
### Do You Need an Alternative to Docker?
349+
350+
| Runtime | Why would you do this? | Key trade-offs | Performance | Setup | Recommendation |
351+
| ---------------------- | --------------------------------------------- | ------------------------------------------------------------------------ | ------------------ | -------- | ------------------------------ |
352+
| **Traditional Docker** | Standard, widely-used option | None | Excellent | Simple | **Recommended for most users** |
353+
| **Podman** | Avoid Docker entirely (organizational policy) | Cannot use ports 80/443 (must use 8080/8443 instead), different behavior | Slower than Docker | Moderate | Only if Docker not allowed |
354+
355+
**Bottom line**: Use traditional Docker (OrbStack, Docker Desktop, Lima, Colima, or Rancher Desktop) unless your organization forbids it. The inability to use standard ports 80/443 with Podman creates a significantly different development experience.
356+
338357
### Installing Podman
339358
340359
Install Podman using Homebrew:
@@ -361,52 +380,51 @@ brew install docker
361380
362381
### Configuring Podman
363382
364-
1. Initialize and start the Podman machine:
383+
1. Handle privileged ports (<1024):
384+
385+
**Important**: Podman on macOS cannot bind to privileged ports (80/443). You must configure DDEV to use unprivileged ports:
365386
366387
```bash
367-
# check `podman machine init -h` for more options
368-
podman machine init --memory 8192
369-
podman machine start
388+
ddev config global --router-http-port=8080 \
389+
--router-https-port=8443
370390
```
371391
372-
Example output from `podman machine start`:
373-
374-
```text
375-
~ % podman machine start
376-
Starting machine "podman-machine-default"
377-
378-
This machine is currently configured in rootless mode. If your containers
379-
require root permissions (e.g. ports < 1024), or if you run into compatibility
380-
issues with non-podman clients, you can switch using the following command:
392+
This means your DDEV projects will be accessible at `https://yourproject.ddev.site:8443` instead of the standard `https://yourproject.ddev.site`.
381393
382-
podman machine set --rootful
383-
384-
API forwarding listening on: /var/folders/x3/r1wk89cd3_x0yb_21dgnj53m0000gn/T/podman/podman-machine-default-api.sock
385-
386-
The system helper service is not installed; the default Docker API socket
387-
address can't be used by podman. If you would like to install it, run the following commands:
394+
Note: switching to rootful mode with `podman machine set --rootful --user-mode-networking=false` doesn't help with privileged ports because the `--user-mode-networking=false` flag is [not supported on macOS](https://github.com/containers/podman/issues/26780) (it's only available for WSL).
388395
389-
sudo /opt/homebrew/Cellar/podman/5.7.1/bin/podman-mac-helper install
390-
podman machine stop; podman machine start
396+
2. Initialize and start the Podman machine:
391397
392-
You can still connect Docker API clients by setting DOCKER_HOST using the
393-
following command in your terminal session:
398+
```bash
399+
# check `podman machine init -h` for more options
400+
podman machine init --memory 8192
401+
podman machine start
402+
```
394403
395-
export DOCKER_HOST='unix:///var/folders/x3/r1wk89cd3_x0yb_21dgnj53m0000gn/T/podman/podman-machine-default-api.sock'
404+
Check for the Podman socket path using `podman machine inspect`:
396405
397-
Machine "podman-machine-default" started successfully
406+
```text
407+
~ % podman machine inspect
408+
...
409+
"ConnectionInfo": {
410+
"PodmanSocket": {
411+
"Path": "/var/folders/z5/lhpyjf2n7xj2djl0bw_7kb3m0000gn/T/podman/podman-machine-default-api.sock"
412+
},
413+
"PodmanPipe": null
414+
},
415+
...
398416
```
399417
400-
2. Configure Docker CLI to use Podman. Choose one of two approaches:
418+
3. Configure Docker CLI to use Podman. Choose one of two approaches:
401419
402420
**Option 1: Create a Docker context** (recommended, more flexible):
403421
404422
```bash
405423
# Create Podman context (path to socket may vary)
406-
# Use the socket path from `podman machine start` output
424+
# Use the socket path from `podman machine inspect` output
407425
docker context create podman-rootless \
408426
--description "Podman (rootless)" \
409-
--docker host="unix:///var/folders/x3/r1wk89cd3_x0yb_21dgnj53m0000gn/T/podman/podman-machine-default-api.sock"
427+
--docker host="unix:///var/folders/z5/lhpyjf2n7xj2djl0bw_7kb3m0000gn/T/podman/podman-machine-default-api.sock"
410428
411429
# Switch to the new context
412430
docker context use podman
@@ -430,22 +448,20 @@ brew install docker
430448
docker ps
431449
```
432450
433-
3. Proceed with [DDEV installation](https://docs.ddev.com/en/stable/users/install/ddev-installation/).
434-
435-
4. Handle privileged ports (<1024):
451+
4. Proceed with [DDEV installation](https://docs.ddev.com/en/stable/users/install/ddev-installation/).
436452
437-
Podman on macOS cannot bind to privileged ports (80/443). Configure DDEV to use unprivileged ports:
453+
## Windows
438454
439-
```bash
440-
ddev config global --router-http-port=8080 \
441-
--router-https-port=8443
442-
```
455+
Windows users can use Podman Desktop, but setup has its own challenges. Docker Rootless is not available on traditional Windows (it works in WSL2, see the [Linux and WSL2](#key-aim-linux-and-wsl2-users) section).
443456
444-
Note: switching to rootful mode with `podman machine set --rootful --user-mode-networking=false` doesn't help with privileged ports because the `--user-mode-networking=false` flag is [not supported on macOS](https://github.com/containers/podman/issues/26780) (it's only available for WSL).
457+
### Do You Need an Alternative to Docker?
445458
446-
## Windows
459+
| Runtime | Why would you do this? | Key trade-offs | Performance | Setup | Recommendation |
460+
| ---------------------- | --------------------------------------------- | ------------------------------------------ | ------------------ | -------- | ------------------------------ |
461+
| **Traditional Docker** | Standard, widely-used option | None | Excellent | Simple | **Recommended for most users** |
462+
| **Podman** | Avoid Docker entirely (organizational policy) | Different behavior, less mature on Windows | Slower than Docker | Moderate | Only if Docker not allowed |
447463
448-
Windows users can use Podman Desktop, but setup has its own challenges. Docker Rootless is not available on traditional Windows (it works in WSL2, see the [Linux and WSL2](#key-aim-linux-and-wsl2-users) section).
464+
**Bottom line**: Use traditional Docker (Docker Desktop or alternatives) unless your organization forbids it. Podman on Windows works but is less mature than on Linux.
449465
450466
### Installing Podman
451467

0 commit comments

Comments
 (0)