AdGuard Home

Network & Proxy rootful 1 container
adguard-home docker.io/adguard/adguardhome:latest · 53:53, 3000:3000, 80:80

Deployment rootful

1. Prepare the host

Operating System:
!

Prerequisites once as root

Install Podman (needs podman 4.3 or newer; Ubuntu 22.04 ships 3.4 and is too old, use 24.04)

apt update && apt install -y podman

2. Choose a format and deploy

The same pod in four forms. Pick one and follow only its steps.

Each tab says which podman it needs. Check yours with podman --version: Debian 12 ships 4.3, Ubuntu 24.04 4.9, Debian 13 5.4, Fedora 5.8, Arch 6.x.

Kubernetes YAML for podman kube play, started by systemd through a Quadlet .kube unit (podman 4.4+; older podman like Debian 12 uses podman-kube@, see the version check below).

Kubernetes YAML

apiVersion: v1
kind: Pod
metadata:
  name: adguard-home
  labels:
    app: adguard-home
spec:
  restartPolicy: Always
  containers:
  - name: adguard-home
    image: docker.io/adguard/adguardhome:latest
    imagePullPolicy: Always
    ports:
    - containerPort: 53
      hostPort: 53
    - containerPort: 3000
      hostPort: 3000
    - containerPort: 80
      hostPort: 80
    volumeMounts:
    - name: vol-0
      mountPath: /opt/adguardhome/work
    - name: vol-1
      mountPath: /opt/adguardhome/conf
  volumes:
  - name: vol-0
    persistentVolumeClaim:
      claimName: adguard-home-work
  - name: vol-1
    persistentVolumeClaim:
      claimName: adguard-home-conf
1

Save the YAML file

sudo mkdir -p /etc/containers/
sudo nano /etc/containers/adguard-home.yaml
2

Test the pod (without systemd)

sudo podman kube play /etc/containers/adguard-home.yaml

# Status:
sudo podman pod ps && sudo podman ps

# Stop:
sudo podman kube down /etc/containers/adguard-home.yaml

Check your podman version

podman --version

4.4 or newer: continue with step 3 below.

Older, e.g. 4.3 on Debian 12? There is no Quadlet yet: use podman's own podman-kube@ service instead of steps 3–5
sudo systemctl enable --now podman-kube@$(systemd-escape /etc/containers/adguard-home.yaml).service

# Status & logs:
sudo systemctl status podman-kube@$(systemd-escape /etc/containers/adguard-home.yaml).service
sudo journalctl -u podman-kube@$(systemd-escape /etc/containers/adguard-home.yaml).service -f

The day-to-day commands below have a block for this service.

3

Create Quadlet .kube file (systemd)

adguard-home.kube
[Unit]
Description=adguard-home pod
After=network-online.target
Wants=network-online.target

[Kube]
Yaml=/etc/containers/adguard-home.yaml

[Service]
Restart=always

[Install]
WantedBy=multi-user.target

Save to /etc/containers/systemd/:

sudo mkdir -p /etc/containers/systemd/
sudo nano /etc/containers/systemd/adguard-home.kube
4

Start systemd service (rootful)

sudo systemctl daemon-reload
sudo systemctl start adguard-home.service
5

Status & Logs

sudo systemctl status adguard-home.service
sudo journalctl -u adguard-home.service -f
sudo podman pod ps
sudo podman ps
6

Enable automatic image updates optional

Requires AutoUpdate=registry in the .kube file. Podman checks for new images and restarts the pod automatically:

sudo systemctl enable --now podman-auto-update.timer

# Check status:
sudo systemctl status podman-auto-update.timer

# Trigger manually:
sudo podman auto-update
Rootful mode:
  • Containers run as root — only use trusted images
  • Ports < 1024 can be bound directly
  • No loginctl enable-linger needed — systemd manages the service
  • Quadlet path: /etc/containers/systemd/ (not ~/.config/)
Day-to-day logs, restart, update, remove (click to open)

Logs & shell into a container

sudo podman logs -f adguard-home-adguard-home
sudo podman exec -it adguard-home-adguard-home /bin/sh

Restart

sudo systemctl restart adguard-home.service

Update an image by hand

Pull the new version, the restart recreates the containers from it:

sudo podman pull <image>:<tag>
sudo systemctl restart adguard-home.service

Stop & remove

Stop through systemd, otherwise Restart=always brings the pod back. To remove it for good, delete the unit files and reload:

sudo systemctl stop adguard-home.service
sudo rm /etc/containers/systemd/adguard-home.kube
sudo systemctl daemon-reload

podman older than 4.4 (podman-kube@ from step 3)

sudo systemctl restart podman-kube@$(systemd-escape /etc/containers/adguard-home.yaml).service

# Update an image: pull, then restart as above
sudo podman pull <image>:<tag>

# Stop and remove from autostart:
sudo systemctl disable --now podman-kube@$(systemd-escape /etc/containers/adguard-home.yaml).service

Delete the data — permanent, only after stop & remove

sudo podman volume rm adguard-home-work
sudo podman volume rm adguard-home-conf

Native systemd units without the Kubernetes YAML: one .pod plus one .container per container. Each container becomes its own systemd service (restart, logs and ordering per container). Needs podman 5.0 or newer — Debian 12 ships 4.3, use the Kube YAML tab there.

1

Save the unit files

adguard-home.pod
[Unit]
Description=adguard-home pod

[Pod]
PodName=adguard-home
PublishPort=53:53
PublishPort=3000:3000
PublishPort=80:80
adguard-home-adguard-home.container
[Unit]
Description=adguard-home-adguard-home container

[Container]
Image=docker.io/adguard/adguardhome:latest
Pod=adguard-home.pod
ContainerName=adguard-home-adguard-home
Pull=always
Volume=adguard-home-work:/opt/adguardhome/work:Z
Volume=adguard-home-conf:/opt/adguardhome/conf:Z

[Service]
Restart=always

[Install]
WantedBy=multi-user.target

Save all of them to /etc/containers/systemd/:

sudo mkdir -p /etc/containers/systemd/
sudo nano /etc/containers/systemd/adguard-home.pod
sudo nano /etc/containers/systemd/adguard-home-adguard-home.container
2

Start the pod

The pod service pulls in every container service. Autostart at boot comes from the [Install] section of the units, no enable needed.

sudo systemctl daemon-reload
sudo systemctl start adguard-home-pod.service
3

Status & Logs

sudo systemctl status adguard-home-pod.service
sudo journalctl -u adguard-home-adguard-home.service -f
sudo podman pod ps && sudo podman ps
Day-to-day logs, restart, update, remove (click to open)

Logs & shell into a container

sudo podman logs -f adguard-home-adguard-home
sudo podman exec -it adguard-home-adguard-home /bin/sh

Restart

sudo systemctl restart adguard-home-pod.service

Update an image by hand

Pull the new version, the restart recreates the containers from it:

sudo podman pull <image>:<tag>
sudo systemctl restart adguard-home-pod.service

Stop & remove

Stop through systemd, otherwise Restart=always brings the pod back. To remove it for good, delete the unit files and reload:

sudo systemctl stop adguard-home-pod.service
sudo rm /etc/containers/systemd/adguard-home.pod
sudo rm /etc/containers/systemd/adguard-home-adguard-home.container
sudo systemctl daemon-reload

Delete the data — permanent, only after stop & remove

sudo podman volume rm adguard-home-work
sudo podman volume rm adguard-home-conf

A docker-compose.yml for podman-compose. Handy if you already work with Compose; there are no per-container systemd services.

1

Install podman-compose as root

apt install -y podman-compose
2

Save the compose file

docker-compose.yml
services:
  adguard-home:
    image: docker.io/adguard/adguardhome:latest
    pull_policy: always
    restart: always
    ports:
    - '53:53'
    - 3000:3000
    - 80:80
    volumes:
    - adguard-home-work:/opt/adguardhome/work:Z
    - adguard-home-conf:/opt/adguardhome/conf:Z
volumes:
  adguard-home-work: null
  adguard-home-conf: null
sudo mkdir -p /opt/adguard-home
sudo nano /opt/adguard-home/docker-compose.yml
3

Start, status & logs

cd /opt/adguard-home
sudo podman-compose up -d
sudo podman-compose ps
sudo podman-compose logs -f

# Stop:
sudo podman-compose down
4

Start after reboot

podman-restart.service starts every container with restart: always at boot:

sudo systemctl enable podman-restart.service
5

Update images

cd /opt/adguard-home
sudo podman-compose pull
sudo podman-compose up -d
Day-to-day logs, restart, update, remove (click to open)

Logs & shell into a container

sudo podman logs -f adguard-home_adguard-home_1
sudo podman exec -it adguard-home_adguard-home_1 /bin/sh

Restart

cd /opt/adguard-home
sudo podman-compose restart

Stop & remove

cd /opt/adguard-home
sudo podman-compose down

Delete the data — permanent, only after stop & remove

sudo podman volume rm adguard-home_adguard-home-work
sudo podman volume rm adguard-home_adguard-home-conf

Plain podman pod create / podman create commands. Good for a quick test or to see what happens under the hood.

1

Save the script

adguard-home.sh
#!/bin/bash
set -e

# ── Create named volumes ───────────────────────────────────────────
# Named volumes are created automatically — no UID/GID permission adjustment needed.
sudo podman volume exists adguard-home-work || sudo podman volume create adguard-home-work
sudo podman volume exists adguard-home-conf || sudo podman volume create adguard-home-conf

# ── Create pod ─────────────────────────────────────────────────────
sudo podman pod create \
  --name adguard-home \
  -p 53:53 \
  -p 3000:3000 \
  -p 80:80

# ── Container: adguard-home-adguard-home ─────────────────────────────────────────────
sudo podman create \
  --pod adguard-home \
  --name adguard-home-adguard-home \
  --restart always \
  --pull always \
  -v adguard-home-work:/opt/adguardhome/work:Z \
  -v adguard-home-conf:/opt/adguardhome/conf:Z \
  docker.io/adguard/adguardhome:latest

# ── Start pod ──────────────────────────────────────────────────────
sudo podman pod start adguard-home

# ── Stop & clean up ───────────────────────────────────────────────
# sudo podman pod stop adguard-home
# sudo podman pod rm adguard-home
nano adguard-home.sh
2

Run it, status & logs

bash adguard-home.sh
sudo podman pod ps && sudo podman ps
sudo podman logs -f <container-name>
3

Start after reboot

podman-restart.service starts every container with --restart always at boot:

podman 6.1 does not bring rootful pods created by hand back after a reboot (the infra container fails with stale file handle, and the failing podman-restart.service then stops the other containers it started). If the pod must survive reboots, use the Kube YAML or Quadlet tab.

sudo systemctl enable podman-restart.service
4

Remove or rebuild

The script creates the pod once. To apply changes or new images, remove the pod and run the script again (named volumes stay):

sudo podman pod rm -f adguard-home
bash adguard-home.sh
Day-to-day logs, restart, update, remove (click to open)

Logs & shell into a container

sudo podman logs -f adguard-home-adguard-home
sudo podman exec -it adguard-home-adguard-home /bin/sh

Restart

sudo podman pod stop adguard-home
sudo podman pod start adguard-home

Stop & remove

sudo podman pod rm -f adguard-home

Delete the data — permanent, only after stop & remove

sudo podman volume rm adguard-home-work
sudo podman volume rm adguard-home-conf

Ports < 1024 (e.g. 80, 443)

Rootless cannot open privileged ports. Solution:

sysctl net.ipv4.ip_unprivileged_port_start=80

Make persistent in /etc/sysctl.d/99-podman.conf.

Containers communicate via localhost

All containers in the pod share the same network namespace. Always use localhost, not container names.

# Correct (e.g. app → db):
localhost:5432

# Wrong (doesn't work in a pod):
db-container:5432

List open ports

Which ports are the running containers publishing? See the PORTS column:

podman ps

Custom DNS for the pod

Set a custom DNS server (e.g. local Pi-hole) in the generator under DNS server. Every format picks it up.

Set volume ownership

Fix permission errors by adjusting UID/GID in the user namespace:

podman unshare chown 1000:1000 /path/to/volume

SELinux volume labels

On SELinux systems (RHEL, Fedora) set the volume suffix:

/host/path:/container/path:Z   # private
/host/path:/container/path:z   # shared

List all volumes

podman volume ls
podman volume inspect <volume-name>

Volume backup

Back up data from a named volume:

podman run --rm \
  -v <volume-name>:/data:ro \
  -v $(pwd):/backup \
  busybox tar czf /backup/backup.tar.gz /data

Cleanup

Remove unused images, containers and volumes:

podman system prune -f        # containers + images
podman image prune -f         # untagged images only
podman volume prune -f        # unused volumes

Check for outdated images

List local images; auto-update only covers units with AutoUpdate= (Kube and Quadlet tabs):

podman images
podman auto-update --dry-run

All containers, including stopped ones

podman pod ps
podman ps -a

Resource usage

podman stats --no-stream

Customize this stack
Change ports, volumes, environment variables and more in the generator.
Open in Generator