I'm trying to add a volume to a docker container. I get 403 permission denied from apache when accessing outside of my atomic vm. I've forwarded port 80 of my VM to the vm host.
In the VM I have a user and a directory in the users home. /home/test/code/index.php. I run,
docker run -d -p 80:80 -v /home/test/code:/app tutum/apache-php
I always get 403 forbidden unless i run,
docker run -d -p 80:80 -v /code:/app tutum/apache-php
where ive chmod 777 /code. im guessing this is selinux related as it works fine from home dirs on coreos. Another directory i tried was /opt/test/code, even with /opt/test/code chmod'd to 777 get a 403. I think this is because the sim link /opt -> /var/opt which is owned by root.