Quantcast
Channel: bad ownership or modes for chroot directory "/var/www" - Super User
Viewing all articles
Browse latest Browse all 3

Answer by Samir Ahmadli for bad ownership or modes for chroot directory "/var/www"

$
0
0

Here's the commands you need:

usermod -d /var/www/ sftponly

usermod -s /sbin/nologin sftponly

usermod -s /bin/false sftponly

After this best way to give permissions for any user to any folder is ACL:

setfacl -Rm "u:sftponly:rwx" /var/www/

setfacl -Rdm "u:sftponly:rwx" /var/www/

Then enjoy your life


Viewing all articles
Browse latest Browse all 3

Trending Articles