Docker-compose help needed

Hi,

I am using docker-compose to launch a container. I need to start a service within the container through docker-compose.yml file but I am facing below error:

“Failed to get D-Bus connection: No connection to service manager”

I am using docker-compose 1.11.2 version and docker version is: Docker version 17.03.0-ce, build 60ccb22

My docker-compose.yml file is:

version: "2"
services:
apache:
image: rhel7.1:latest
ports:

  • "80:80"
    restart: always
    environment:
    container: 'docker’
    security_opt:
  • seccomp:unconfined
    cap_add:
  • SYS_ADMIN
    tmpfs:
  • /run
  • /run/lock
    volumes:
  • /sys/fs/cgroup:/sys/fs/cgroup:ro
  • /apps/assignments/scripts:/tmp
    command: /bin/bash -c “/tmp/script.sh”;"bash"
    tty: true
    privileged: true
    labels:
    webserver.type: “Apache Webserver”

Can you please help me with that?

Thanks,
Sanjiv