title: Issue with www-data and group read for site folder
body: <p>I'm locking down some permissions, and now nginx has trouble seeing my site</p>
  
  <p>Background:</p>
  
  <ul>
  <li>I deploy &amp; run CLI using the mysite user.</li>
  <li>I want both mysite and www-data to have access to the site's folder
  mysite and www-data users </li>
  <li>both belong to the www-data groups:</li>
  </ul>
  
  <p><code>root@dev:~# groups mysite
  mysite : mysite www-data
  root@dev:~#
  </code></p>
  
  <p><code>root@dev:~# groups www-data
  www-data : www-data
  </code></p>
  
  <p>The folder (has group permissions)</p>
  
  <p><code>drwxrwx---  3 mysite www-data  4096 Jun 26 14:12 sites/
  </code></p>
  
  <p>www-data trying to get to it:</p>
  
  <p><code>root@dev:~# sudo -u www-data stat /home/mysite/sites/
  stat: cannot stat ‘/home/mysite/sites/’: Permission denied
  </code></p>
  
  <p>www-data can see the parent folders fine:</p>
  
  <p><code>root@dev:~# sudo -u www-data stat /home/
    File: ‘/home/’
    Size: 4096        Blocks: 8          IO Block: 4096   directory
  Device: fd01h/64769d    Inode: 1179649     Links: 3
  Access: (0755/drwxr-xr-x)  Uid: (    0/    root)   Gid: (    0/    root)
  Access: 2016-10-19 10:59:05.845267219 -0400
  Modify: 2016-06-26 14:12:24.890310000 -0400
  Change: 2016-06-26 14:12:24.890310000 -0400
   Birth: -
  root@dev:~# sudo -u www-data stat /home/mysite/
    File: ‘/home/mysite/’
    Size: 4096        Blocks: 8          IO Block: 4096   directory
  Device: fd01h/64769d    Inode: 1180062     Links: 10
  Access: (0770/drwxrwx---)  Uid: ( 1000/ mysite)   Gid: ( 1000/ mysite)
  Access: 2016-10-19 10:59:10.081267219 -0400
  Modify: 2016-10-19 10:35:01.221267219 -0400
  Change: 2016-10-19 10:35:01.221267219 -0400
   Birth: -
  </code></p>
  
  <p>I've also checked to see if SELinux was messing with it</p>
  
  <p><code>root@dev:~# setenforce 0
  setenforce: SELinux is disabled
  </code></p>
  
  <p>I've also tried:</p>
  
  <p><code>chown www-data:www-data /home/mysite/sites/
  </code></p>
  
  <p>Update 10/19/2016:
  Setting the acl on the folder that 'sites' belongs to got this working the way I have it setup:</p>
  
  <p>setfacl --modify=g:www-data:x /home/mysite</p>