2

For dev purposes, is it better to install XAMPP or Apache MySQL & PHP from the repository?

chrism2671
  • 2,549
  • 9
  • 34
  • 45

2 Answers2

1

It depends on what your productive platform looks like. If your productive system runs for example PHP 5.2 and you develop your app with some feature that requires running 5.3 you'll run into problems when you deploy your stuff.

My developers tell me that they want their development environment as close as they can get to production so if the stuff the write runs on their machine, it sure as hell does runs when it goes live.

If on your live server you run LAMP from the distro than you'll have the least problems if you do too (also, try to use the same php.ini / httpd.conf / my.cnf settings if possible). Mixing stuff in dev and production almost always leeds to trouble.

besn
  • 21
  • 2
0

A couple of advantages of using XAMPP for development over a true LAMP install:

  1. You can start and stop the whole webserver+database stack with one command.
  2. XAMPP is portable so you can carry it around on a thumb drive.
  3. The security settings are strict by default, nobody but you will be able to access the web server.
  4. Php error reporting is enabled by default, which helps when debugging scripts.

You didn't specify what kind of production server you are deploying your work on. If it is also Ubuntu, it could be interesting to mimic the production server by installing the Apache, MySQL and PHP packages from the repositories for development.

Should you go that route, I would recommend turning on the php error reporting for debugging purposes on your development server. Which, again, is something XAMPP does by default.

Kenny Rasschaert
  • 8,925
  • 3
  • 41
  • 58