Docker compose - volumes on aws giving not found error

Hi all,
getting an issue while running docker-compose (v1.8) and docker 17.03ce. Need an expert help to solve the issue or suggest better way. This is happening only on an aws vm. On my local ubuntu virtualbox works fine. Here is the scenario:

  • Generated a self signed cert on vm (openssl)
  • Configured certificate path as apache/etc/apache2/external/mycerts/apache.cert in ssl.conf file and copied it into container through Dockerfile
  • trying to map the cert and key from host into apache container with this snipped from docker-compose.yml
    ports:
    - “80:80”
    - “443:443”
    links:
    - mydb
    volumes:
    - “/home/ubuntu/mycerts:/etc/apache2/external/mycerts”

When the container startsup its exits with an error that /etc/apache2/external/mycerts/apache.cert is not found

Any suggestions?

anyone face this issue before? or any solutions / workarounds? Would i need to mount devices? My output for “df -k” is something like this
udev 499260 0 499260 0% /dev
tmpfs 101452 9804 91648 10% /run
/dev/xvda1 8065444 3314208 4734852 42% /
tmpfs 507248 0 507248 0% /dev/shm
tmpfs 5120 0 5120 0% /run/lock
tmpfs 507248 0 507248 0% /sys/fs/cgroup
/dev/loop0 89088 89088 0 100% /snap/core/5145

so do i need to add a devices: tag with /dev/xvda1? any help would be good

figured out the issue… my bad :slight_smile: