Tutorials for Magento and Joomla! - Yireo

Using MageBridge in TurnKey appliances

TurnKey offers virtual appliances - based on Ubuntu Linux - allowing you to run popular applications quickly under virtualization platforms like VMware and VirtualBox. Because TurnKey images exist for both Joomla! as Magento, the question comes up whether these images can be used for MageBridge. This tutorial guides you through the steps.

Using TurnKey in production environments

One word of advise comes from the makers of TurnKey themselves: Do not use TurnKey to build a live environment. Besides Joomla! or Magento, the appliance will contain a lot of other applications which should not be offered to the outside world. Also, basic things for a public webserver like a firewall are missing or not fully configured.

You can use TurnKey to build testing environments. But once you go live, you need to copy the Joomla! and Magento sources to a properly-built webenvironment, which pays attention to security, stability and performance.

Setting up the TurnKey images

You should follow the instructions on the TurnKey website to download and setup the virtual appliances for Magento and Joomla!. Within VMware and VirtualBox, you will create a virtual machine. Make sure to include enough memory for the machines: For Joomla!, about 256Mb of virtual memory might be enough. But for Magento, you definetely want to use 768Mb or even 1Gb.

Configuring the TurnKey Joomla! image

With Joomla!, you get the choice of running either Joomla! 1.5 or Joomla! 1.6. Latest versions of MageBridge support both. Once you have started the virtual machine, the Joomla! site should be up and running, and accessible through a webbrowser.

turnkey_joomla

Various settings are not right yet for the usage of MageBridge. One missing requirement is CURL - which needs to be installed on top of this existing stack. To do this, login through SSH as user root and execute the following command:

apt-get install php5-curl

After this, also open up the PHP-configuration file /etc/php5/apache2/php.ini and modify the following settings:

max_execution_time = 300
memory_limit = 64M

Afterwards, save the file and restart the webserver:

apache2ctl graceful

The Joomla! image is now ready for MageBridge to be installed on top of it. Follow the MageBridge Installation Guide to accomplish this.

Configuring the TurnKey Magento image

Just like there is an image for Joomla!, there is also an image for Magento. The same applies here: Configure the virtual machine and start it up. Once started up, the Magento site should be available through a webbrowser.

turnkey_magento

The Magento image also needs some changes. Fortunately all PHP-modules required by MageBridge are also required by Magento, so no extra software needs to be installed. However, we do recommend changing the following PHP-settings. Open up the file /etc/php5/apache2/php.ini and change the following:

realpath_cache_size = 128k
max_execution_time = 300
memory_limit = 256M

After this, save the changes to the file and restart the webserver from the command-line:

apache2ctl graceful

Also,  make sure that all permissions are properly set. In our case, the caching directory and the media directory were not writable. To fix this, the simplest solution (and very adequate for testing environments) is to change everything to be writable:

cd /var/www/magento
chown -R www-data:www-data .

This should get you going. Again, follow the instructions in the MageBridge Installation Guide for further instructions. 

Created on Saturday, 05 February 2011
Modified on Monday, 07 February 2011

About Yireo

Yireo tries to help webdevelopers build successful Joomla! and Magento sites.

More about Yireo