# CentOS 7 systemd

**URL:** <https://forums.docker.com/t/centos-7-systemd/54791>\
**Category:** General\
**Tags:** docker, build\
**Created:** [July 25, 2018, 3:07pm UTC](https://forums.docker.com/t/centos-7-systemd/54791 "2018-07-25T15:07:19Z")\
**Posts on this page:** 1\
**Showing post:** 6

<div class="post-metadata">

**Author:** ![terpz](https://sea3.discourse-cdn.com/docker/user_avatar/forums.docker.com/terpz/32/36125_2.png) [@terpz](https://forums.docker.com/u/terpz)\
**Post date:** [July 27, 2018, 10:59am UTC](https://forums.docker.com/t/centos-7-systemd/54791/6 "2018-07-27T10:59:13Z")

</div>

Hi

You are not going to get that to work in Docker.  
What I use, in the rare cases i need multiple services running in same container, is supervisor.

quick example:

services.conf:

> [program:sshd]  
> directory=/usr/local/  
> command=/usr/sbin/sshd -D  
> autostart=true  
> autorestart=true  
> redirect\_stderr=true
> 
> [program:someOtherService]  
> directory=/usr/local/  
> command=/usr/sbin/Otherservice -D  
> autostart=true  
> autorestart=true  
> redirect\_stderr=true

Dockerfile

> RUN apt-get install -y supervisor  
> ADD sshd.conf /etc/supervisor/conf.d/services.conf  
> CMD /usr/bin/supervisord -n

---

_[View the full topic](https://forums.docker.com/t/centos-7-systemd/54791)._
