Score:0

SFTP user with web server files access

fr flag

I have a php website which is running on Nginx on Ubuntu using the www-data user.

I want to add SFTP only access (using ssh key) to a new user, having access to the /var/www/websites/company

I've followed this guide:

https://gist.github.com/lymanlai/3008244

The only difference for me is that the /var/www/websites/company already exists and it's owned by root.

I've added a symlink to my web directory, but the paths in PHP are not resolved properly, looks like it's a permission issue (user home dir is outside the web dir).

How do I do this properly including the permission settings?

cn flag
I think you want to read [NGINX and PHP-FPM. What my permissions should be?](https://www.getpagespeed.com/server-setup/nginx-and-php-fpm-what-my-permissions-should-be).
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.