How to run systemd services inside ubi7-init containers?

Solution Verified - Updated -

Issue

  • Getting below error while starting a systemd service inside the container

    Failed to get D-Bus connection: No such file or directory
    
  • System has not been booted with systemd as init system (PID 1). Can't operate.

    Failed to connect to bus: Host is down
    Error: non zero exit code: 1: OCI runtime error
    

Environment

  • RHEL 7.9
  • podman-1.6.4
  • ubi7-init

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content