I have a few CentOS servers which despite being dedicated server are being managed by web developers who want to do the whole thing with an FTP client. This is fine, however I needed to install and configure httpd-itk so that the whole apache process is taken care of by the FTP user in question.
1. Install wget
yum install wget
2. Install epel repositary
wget http://download.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm rpm -ivh epel-release-6-8.noarch.rpm
3. Install httpd-itk
yum install httpd-itk
4. Edit /etc/sysconfig/httpd
and add
HTTPD=/usr/sbin/httpd.itk
5. Set the default itk user by editing /etc/httpd/conf.d/itk.conf
AssignUserId apache apache
6. Modify /etc/httpd/conf.d/php.conf
to accommodate mod_php
<IfModule itk.c> LoadModule php5_module modules/libphp5.so </IfModule>
7. Reset all the file ownerships on the web space
chown -R ftp_user:ftp_user /var/www/home_directory/*
8. Specify the ftp user inside the VirtualHost
block
AssignUserId ftp_user ftp_user
9. Restart the Apache daemon
service httpd restart
All done!