Deploy a CentOS container image with systemd enabled

In order to deploy a CentOS container with systemd enabled to perform and use commands as systemctl you could do the following:

Download the official Centos image with systemd integrated from DockerHub and create a file name Dockerfile on your current working directory. The following dockerfile will install/enable httpd package with yum and systemctl.

Build your image:

And then deploy a new container from your created image:

Verify that you can run successfully systemd commands: