Issue
I set up a folder (/srv/www/). In this folder, all Apache virtual hosts are located. For example;
- /srv/www/domain.com
- /srv/www/domain2.com
I created a group ftp-users and executed the following commands:
- groupadd ftp-users
- chmod 755 /srv/www
- chown root:ftp-users /srv/www
Whenever I upload a file to /srv/www/domain.com/public_html/ it gets CHMOD 600 by default, this has to be 755.
How do I do this?
Using Debian Squeeze, Apache and vsFTPd.
Solution
From the vsftpd manpage:
file_open_mode The permissions with which uploaded files are created. Umasks are applied on top of this value. You may wish to change to 0777 if you want uploaded files to be executable. Default: 0666
local_umask The value that the umask for file creation is set to for local users. NOTE! If you want to specify octal values, remember the "0" prefix otherwise the value will be treated as a base 10 integer! Default: 077
Play around with theese two values to achiev what you want ;)
Answered By - Arne Böckmann Answer Checked By - Katrina (WPSolving Volunteer)