Nginx can't create files inside 755 permissions folder
<p>I have a folder with 755 permissions with <code>foo-bar:foo-bar</code> chown. Nginx throws an error that it can't save a file inside it, it only can when I change the folder's recursive permissions to 777. How can I allow nginx to create the files inside this folder with 755 permissions?</p>

<p>My user groups:</p>

<pre><code>foo-bar: foo-bar www-data
www-data: www-data
</code></pre>

<p>Should I just add <code>www-data</code> to <code>foo-bar</code> group? Will this work? Or is it better to do something else?</p>