Translation(s): none
WordPress is a free and open source (GNU GPLv2 or later) blogging tool and a content management system (CMS) based on PHP and MySQL. Features include a plug-in architecture and a template system.
Contents
Basic Installation guide for Wheezy
# apt-get install wordpress curl apache2 mysql-server
Set the mysql admin root user password when prompted
Create a site
# nano /etc/apache2/sites-available/wp
Add this content:-
Alias /wp /usr/share/wordpress Alias /wp/wp-content /var/lib/wordpress/wp-content <Directory /usr/share/wordpress> Options FollowSymLinks AllowOverride Limit Options FileInfo DirectoryIndex index.php Order allow,deny Allow from all </Directory> <Directory /var/lib/wordpress/wp-content> Options FollowSymLinks Order allow,deny Allow from all </Directory>
Enable the site
# a2ensite wp
Restart the webserver
# service apache2 reload
Create /etc/wordpress/config-$DM.php (where $DM is the domain name e.g. if the fully qualified domain name is debianwordpress.dev create /etc/wordpress/config-dev.php)
# nano /etc/wordpress/config-dev.php
Add this content:-
replace password with a suitably secure password
Create a file to hold the database creation instructions
# nano ~/wp.sql
Add this content:-
replace password with your "suitably secure password"
Create the database:-
# cat ~/wp.sql | mysql --defaults-extra-file=/etc/mysql/debian.cnf
Navigate to the wordpress directory in browser e.g.:- http://debianwordpress.dev/wp which redirects to http://debianwordpress.dev/wp/wp-admin/install.php where you'll see the "classic" wordpress 5 minute install page (actually a 5 second install thanks to the Debian packaging)
replace debianwordpress.dev with your domain name (or localhost if running on the same box as your browser).
At time of writing this provides WordPress v3.6.1. WordPress v3.7.1 is available in Testing and Unstable. I haven't tested it but it should install fine on Wheezy.
Upgrading the installed WordPress version
Automated FTP upgrade
Untested.
Login to WordPress Admin
- Go to the Updates section
Click on the Re-install Now button
Fill in the required fields and click on the Proceed button
Manual upgrade
Login to WordPress admin
- Go to the Plugins page
- Select all your plugins
- Deactivate them all
Download the latest version of WordPress
# cd ~ # wget http://wordpress.org/latest.tar.gz
Back-up your current wp-includes directory
# mv /usr/share/wordpress/wp-includes{,-3.6.1}
Back-up your current wp-admin directory
# mv /usr/share/wordpress/wp-admin{,-3.6.1}
Extract the upgraded wp-admin directory (replaces existing)
# tar -zxvf latest.tar.gz -C /usr/share wordpress/wp-admin
Extract the upgraded wp-includes directory (replaces existing)
# tar -zxvf latest.tar.gz -C /usr/share wordpress/wp-includes
Extract the upgrade wp-content directory (overwrites existing)
# tar -zxvf latest.tar.gz -C /usr/share wordpress/wp-content
Extract the upgraded WordPress root files (overwrites existing)
# tar --wildcards -zxvf latest.tar.gz -C /usr/share/ 'wordpress/*.php'
Back in WordPress agree to reload/upgrade the database then reactivate plugins
See also
Sample configurations can be found in /usr/share/doc/wordpress/examples/
Debian specific instructions are /usr/share/doc/wordpress/README.Debian