I am facing a little issue: I have created an FTP server with vsftp and a web server with Apache 2.2.Now, my goal is to make so that anyone can log into the machine via FTP and upload files (.html, .php) so that they are executable by apache.The point is that they aren't.In fact, the files get created with 600 privileges, and with owner ftpadmin. Apache returns an error.Do you know a quick way to fix this?
FTP user creates file that are not executable by apache
debian;apache httpd;php;executable;vsftpd
Apache process started by the user www-data (in Ubuntu, check for Debian).Those files are created by ftp user. Owened by ftpadmin and have permissions read and write to owner only (group members and others cannot access).For currently uploaded filesAdd read and execute permissions to the other userssudo chmod o+rx *.phpsudo chmod o+rx *.html(OR)Change the group of the files to www-data and add read and execute permissions to the group userssudo chgrp www-data *.phpsudo chgrp www-data *.htmlsudo chmod g+rx *.phpsudo chmod g+rx *.htmlRefer the below link to set default file permissions for future file uploads.How to set default file permissions for all folders/files in a directory?