0

I have Owncloud on my server running, and it saves uploaded files unter /home/uid/files. But Apache is running as a non-root user, and it can't access(write) the files under /home/uid/files.

What is the best way to grant Owncloud access to a subdirectory of an userhome with 700 permissions? And how to implement it?

  • ACL?
  • Any NFS hack?
  • Loopback mount hack?
  • Anything else?

Thanks - Boris

djboris
  • 3
  • 2

2 Answers2

0

try: chmod(1), chown(1) or setfacl(1). With these you can specify to be able to write into that directory

example

chgrp -R owncloud /home/*/files
chmod -R g+w /home/*/files
alexus
  • 13,112
  • 32
  • 117
  • 174
0

ACL's are a great solution here. The two key benefits they will provide you with are being able to assign multiple permissions for multiple groups and users, and the ability to have permissions inherit from parent folders as files are created.

The process is different depending on which filesystem you're using, but enabling is typically just a matter of setting a flag in fstab and remounting the parition. http://nxlinuxadmin.blogspot.com/2010/05/how-to-set-acl-in-linux.html#.UDvVRvvYFyY Once you've enabled them, they are relatively easy to setup using setcfacl and getfacl

Univ426
  • 2,149
  • 14
  • 26