Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

In vsftpd, I would like to have user upload file directly to web directory(/var/www/site/) however, the web directory is owned by www user and group.

I know there is chown_username and such thing for anonymous user however that doesn't work for my case. What do I do in vsftp?

thanks.

share|improve this question

1 Answer 1

You can add local_root=/var/www/site/ in the vsftpd.conf file as the root directory ftp user.

share|improve this answer
    
that's not my problem. the problem is that the ftp directory is owned by www-user and ftp user is not allowed to write to it. –  perlwle Mar 8 '12 at 6:07
    
you can give the perm for the ftp user to access the folder using setfacl command –  Mughil Mar 8 '12 at 6:26
    
I am hoping for a vsftp solution. Now I am resorting to adding ftp user to www-data group, set umask to 002 in vsftp and have the web root dir group writtable. –  perlwle Mar 8 '12 at 6:57

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.