I'm trying to run a systemctl inside a debian container, unfortunately I'm getting this exception every time:

System has not been booted with systemd as init system (PID 1). Can't operate. Failed to connect to bus: Host is down

This is my docker-compose file:

    image: debian:buster
    privileged: true

Any help would be appreciated.

2 Answers 2


It seems there are some things that need a bit of clearing up.

Normally, when you run a container you aren’t running an init system (like systemd). The PID 1 of a Docker container should instead be the "entrypoint", the command that were used to launch the container.

If the entrypoint process no longer runs, the container goes down with it.

However, it seems that there is a Debian port with systemd enabled, but I haven't tried this myself.


It's possible to run systemd inside the container but both systemd and docker require proper config - see https://github.com/alehaa/docker-debian-systemd for example.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .