All references to XXX should be replaced with the intended name/username for the new blog.
All references to YYY refer to the password for the new blog.
Account and wordpress setup
1 2 3 4 5 6 7 8 9 | useradd -d /home/XXX -m XXX -s /bin/bash passwd XXX su XXX cd wget http://wordpress.org/latest.zip unzip latest.zip mv wordpress/ public_html cd public_html cp wp-config-sample.php wp-config.php |
Edit wp-config with the new database settings and save.
Database setup
1 2 3 4 5 6 | mysql -u root -p create user 'XXX'@'localhost' identified by 'YYY'; create database XXX; grant all on XXX.* to 'XXX'@'localhost'; commit; exit; |
Add user to www-data group:
1 | usermod -a -G www-data XXX |
Add user to FTP list.
Edit /etc/proftpd/proftpd.conf:
1 2 3 4 | <Limit LOGIN> AllowUser foosite barsite XXX DenyALL </Limit> |
Add .htaccess file to installation directory:
1 2 | touch .htaccess chmod 664 .htaccess |
Other notes
Change database password:
1 2 3 | mysql -u root -p SET PASSWORD FOR 'XXX'@'hostname' = PASSWORD('YYY'); flush privileges; |
Fix permission on wp-content
1 | chown -R www-data:www-data wp-content/ |

