XAMPP

Overview
XAMPP is an open source AMPP (Apache, MySQL, PHP, and Perl) stack from Apache Friends. XAMPP provides a simple and easy way for developers to create and test web applications based on PHP, Perl, Python etc. XAMPP is only for development activity and not intended for hosting web apps for production use. XAMPP provides the ability to backup development activity to easily migrate to a production stack. Documented here is how to install, secure, and backup XAMPP.

Install
The XAMPP version installed in the following steps will be the beta version. beta version of XAMPP has more recent versions of the core packages (Apache, MySQL, PHP, phpMyAdmin).

NOTE: Early on, it will save a lot of grief, by checking which version is required for each of the PHP/Perl/Python applications to be developed and then choose an XAMPP stable/beta version accordingly for your development. For eg., see this note on the incompatibility with stable version of XAMPP for mediawiki development.

Mac OS X
$ sudo /Applications/XAMPP/xamppfiles/xampp start For more command line options, look up $ sudo /Applications/XAMPP/xamppfiles/xampp --help
 * 1) Download xampp beta for mac os x.
 * 2) Install by
 * 3) Opening the DMG-Image.
 * 4) Drag'n'Drop the XAMPP folder into your Applications folder.
 * 5) Open up XAMPP Control to start Apache, MySQL services or can even start from command line with

Configure
XAMPP requires its services to be started as root. So, make sure you have root privileges to start xampp (should likely change the config of xampp to run as non-root user, later...).
 * Since a developer's main activity/files is usually the user's $HOME, the default xampp's Apache config should be changed to resolve web server access permissions and paths.
 * The default xampp's httpd configuration runs as root initially and then switches to a user nobody and group nogroup. Replace nobody and nogroup to the current user/group details. For eg.,

Mac OS X
cd /Applications/XAMPP/etc open httpd.conf as root and add the following changes (replace with your actual user/group settings) User pnm Group staff
 * 1) User nobody
 * 2) Group nogroup

Secure
The default xampp install is not secured for its services ie., mysql, apache etc. Secure xampp by setting passwords for various services. The user names for the different services (which are not easily apparent) are listed here:

To secure xampp

Mac OS X
$ sudo /Applications/XAMPP/xamppfiles/xampp security

Backup
Backup your xampp config, log and data files with the backup option. This creates a backup file ie., a shell script. To restore your backup, just run the shell script created as a result of running the backup command.

Mac OS X
$ sudo /Applications/XAMPP/xamppfiles/xampp backup