Joomla! is an award-winning Content Management System (CMS) that will help you build websites and other powerful online applications. Modern CMSes like Joomla allow you to organize and update web-sites without using any local editor; all editing is done online.
Install the LAMP stack
Use any method to install the Apache2, Mysql and Php stack. You will need the following packages:
apache2 php5-mysql libapache2-mod-php5 mysql-server
Set a mysql-root password (not the same as a root password, but a password for mysql)
mysql -u root
mysql> SET PASSWORD FOR 'root'@'localhost' = PASSWORD('yourpassword');
mysql> SET PASSWORD FOR 'root'@'yourhostname' = PASSWORD('yourpassword');
Where you should change 'yourhostname' in last line. Each successful mysql command will show:
Query OK, 0 rows affected (0.00 sec)
Quit the mysql prompt:
mysql> \q
You should now have a functional LAMP stack and a password for the mysql root user.
Visit Apache PHP MySQL for more information on LAMP.
You should download the latest stable version from the official Joomla Download page. Unpack it and then copy it to your webserver directory.
NOTE - the default root directory for Apache2 is /var/www. If you intend to use Joomla exclusively you don't need to create a 'joomla' sub-folder as instructed in their official documentation.
# Change for new version
SOURCEPKG=Joomla_1.5.14-Stable-Full_Package.tar.bz2
SOURCEWWW=http://joomlacode.org/gf/download/frsrelease/10785/42653/Joomla_1.5.14-Stable-Full_Package.tar.bz2
# Get it
mkdir joomla
cd joomla
wget $SOURCEWWW
# Unpack it
tar xvjf $SOURCEPKG
# Cleanup
rm -f $SOURCEPKG
# Move
cd ..
sudo mv joomla /var/www/
The default folder rights will block various Joomla functions so you need to change the rights. There is the quick/easy way, and the more sophisticated way; choose one:
# A. Quick but less secure. Allow writing in whole joomla subtree
sudo chown -R www-data:www-data /var/www/joomla
# or B. More secure (recommended). Allow writting only in places Joomla! needs to write to (more secure)
sudo chown -R root:root /var/www/joomla
cd /var/www/joomla
PLACES='
administrator/backups
administrator/components
administrator/modules
administrator/templates
cache
components
images
images/banners
images/stories
language
mambots
mambots/content
mambots/editors
mambots/editors-xtd
mambots/search
media
modules
templates
'
for i in $PLACES; do
sudo chown -R www-data:www-data $i
done
Handle file and directory permissions:
cd /var/www/joomla
sudo find . -type f -exec chmod 644 {} \;
sudo find . -type d -exec chmod 755 {} \;
You need to create a new database dedicated to Joomla. You can do this with PhpMyAdmin or via the command line:
I believe the Joomla 1.5 install does it automatically, and prompts you for a name
mysqladmin -u root -p create joomla
Where joomla is the name you picked for the mysql database that joomla will use. You can call it anything you want.
mysql -u root -p
mysql> GRANT SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, INDEX, ALTER, CREATE TEMPORARY TABLES, LOCK TABLES ON joomla.* TO 'yourusername'@'localhost' IDENTIFIED BY 'yourpassword';
You do not want to have Joomla use the mysql root user to access the database. The above command creates a mysql user (other than the mysql root user) with some priviledges to use the joomla database. You will need to chose the yourusername and yourpassword. If the command was successful, activate the new permissions:
mysql> FLUSH PRIVILEGES;
Quit the mysql prompt:
mysql> \q
Open history file for MySQL commands and delete the above SQL, since the password is in readable format!
gedit ~/.mysql_history
You may need to force-reload apache2 so that it knows to use the php module if you haven't done so since you installed the LAMP stack.
sudo /etc/init.d/apache2 restart
Reset GNOME Keyring Password on Ubuntu
rm ~/.gnome2/keyrings/default.keyring