This website uses cookies to improve your experience and deliver relevant information.

We build solid foundations

Our holistic, strategic approach to design, development and marketing means we help you build a strong, sustainable digital presence

 

on Monday, 18 January 2016

How to set up a local Apache, MySQL and PHP (AMP) stack

We are often asked by clients if they can set up a local test environment on their computers for various reasons, and in fact if you want to get involved with testing bug fixes for Joomla!® or if you come on any of our Joomla! training courses you'll need to have a local test environment to do that.  Here are some walk-through tutorials from around the web of how to set up a test environment on Windows, Mac and Linux (we've given examples for the main Linux systems but others are generally well documented online).

Important note: If you are using Skype, it tries to use the same port at Apache and hence you may experience problems starting Apache.  To resolve this, open your Skype settings, open the 'Connection' tab, and untick the box which says "Use port 80 and 443 as alternatives for incoming connections".  Restart Apache, and the port should then be clear and available for use.

Windows

The most popular way to run an AMP stack on Windows is to use WAMP Server

WAMP Server

You can find out more by downloading the installer, and following these instructions.  You can also run XAMPP, which is platform independent.

XAMPP installation

Download XAMPP from https://www.apachefriends.org - you will need to ensure you download the version appropriate to your distribution and architecture.  There are some pretty detailed FAQs here which explain how to install, start, stop and configure XAMPP.

Mac

Similar to Linux, you can either decide to build and install each element of the AMP stack independently (or use pre-installed software) or you can opt to use XAMPP.

Building from repositories

Yosemite

There's a great tutorial here.

XAMPP installation

Download XAMPP from https://www.apachefriends.org - you will need to ensure you download the version appropriate to your distribution and architecture.  There are some pretty detailed FAQs here which explain how to install, start, stop and configure XAMPP on OSx.

Linux

To set up a development environment on a Linux machine you have two options - you can either use a packaged product such as XAMPP, or you can install each part of the stack directly from the repositories for your distribution.

We generally prefer to build from the repositories, as this gives you more flexibility and ease of updating, however tools such as XAMPP can be easier for someone newer to Linux to manage.

Building from distribution repositories

Ubuntu

There is a great tutorial here for 14.04.  You may need to install phpMyAdmin.

Debian

There is a great tutorial here.  You might need to install phpMyAdmin.

Fedora

There is a great tutorial here.  You might need to install phpMyAdmin.

Arch Linux

There is a great tutorial here.  For instructions on installing and configuring phpMyAdmin see this wiki article.

Centos 6

There is a great tutorial here.  Ensure you check the PHP version, as the version in the repositories is often quite out of date and may result in some software (e.g. Joomla 3) not running properly.  There are workarounds here.  You might need to install phpMyAdmin.

Centos 7

There is a great tutorial here.  Note that this uses MariaDB to provide a MySQL database.  You might also need to install phpMyAdmin.

XAMPP installation

Download XAMPP from https://www.apachefriends.org - you will need to ensure you download the version appropriate to your distribution and architecture.  There are some pretty detailed FAQs here which explain how to install, start, stop and configure XAMPP.

 

 

Discover our diverse tech-focused training courses The best investment you'll make today!

Virya Group provides a range of solutions to your technology needs