Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I've enabled userdir for Apache2, and I want to serve files from var/www symlinked to directories within my /home directory (i.e. /home/code/web) - but I need to extend permissions for that folder on account of it being within my home directory. Is it better to add all folders on the path to www-data, or make a folder at / and symlink it from my /home/code/web directory?

I've got a similar issue installing phantomjs - in that I'm keeping the lib in /home/code/libs/js and using a symlink from /usr/local/bin - but again when I try to execute the binary I get a permissions warning. I assume this is the same issue, in that I do not have permission to execute files within my home directory? Should I extend permissions on my homedir, or just keep these files in separate directories and link to there from my home dir?

share|improve this question

Perhaps bind options of mount command helps:

# mount -o bind,rw /home/code/web /var/www
share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .