In this post, I’m going to sanity-check that PHP 5 still works, get and install MySQL and SQL Buddy, and then set up a PHPList instance on the localhost. I might also set up DNS to eliminate the need to hack the /etc/hosts file, but honestly, that’s a frill.

So, PHP.

  1. Edit /etc/apache2/httpd.conf and uncomment the LoadModule php5_module libexec/apache2/libphp5.so
  2. sudo apachectl restart
  3. Create a file index.php in the foo.local’s root: php <?php phpinfo(); ?>
  • Hit http://foo.local/index.php (not just root, because index.shtml would be hit first because of the precedence order of the DirectoryIndex directive…) and you should see php information for your local server.

MySQL. Humming along to this tune

  • Get the MySQL binaries for Mac - at the time, here.
  • Run the installer; I didn’t have to do anything other than accept the defaults.
  • Run the start-up item installer (if you want it to start at system-start - I do).
  • Start the server with sudo/Library/StartupItems/MySQLCOM/MySQLCOM start
  • Check it - run mysqladmin version and you should get the server’s version back.
  • Probably add /usr/local/mysql/bin to your PATH environment variable
  • Follow these steps to secure your initial users’ accounts (especially root!).

Now let’s have something to manage MySQL DBs with. A quick Google yields phpMyAdmin (a web-based front-end) and Sequel Pro. There was also SQL Buddy, but I haven’t got that to work yet; waiting on a reply. Both are straightforward, I’ll be going with Sequel Pro for the time being (I don’t know any better, frankly, and it seems to get me connected…):

  • Get and install Sequel Pro
  • Connect to your localhost as root

That ought to just about do it for tonight, I think.