Saturday, 17 August 2013

/var/www owner for apache2 and ftp access

/var/www owner for apache2 and ftp access

I've got apache2 running on Ubuntu Server 12.04 LTS on an old laptop. It's
on my local network to act as a webserver to help me learn PHP (and
linux).
The default owner for the /var/www folder (where the webpages for apache
are stored) is www-data. With the owner set to www-data I can't copy
files/folders to that folder over ftp. If I change the owner of the
/var/www folder to james (my ftp user) then I can move files over ftp but
apache doesn't have access to display any pages or sub folders.
What should the correct owner be to allow access for ftp user james and
apache?

No comments:

Post a Comment