Family Personal


A quick post with some pics of Molly from just after midnight Sunday evening.  Yes, we have a Spider-Man bedspread on our bed.  It is as awesome as it sounds!


Backyard Panorama

Saturday before dinner I went outside and played around some with the new Panorama mode on the new iPhone 5.  I’d heard that there were apps that could do this before, but I have never used those so thought I’d finally give it a shot.  The first try was interesting but I went to a different part of the pond and the second attempt was more visually stunning due to the more consistent lighting.  Enjoy!

health Personal

Purdue Half Marathon and 5K

Yesterday was the first annual Purdue Half Marathon and 5K.  It was a pretty cold day ( 43º according to the Nike Running app), but the race itself was pretty fun.

As it took me days to fully recover from the half marathons that I have run, I have decided that they definitely aren’t for me.  I congratulate those that did run it, but I’m perfectly happy to run the 5k alone.

I’m also happy with my overall time although it definitely is lower than the first 5k I’ve ever ran back in 2010.

OVERALL RESULTS:            (Number finished = 763)

Place    Age
Overall  Grp  Name                     Pace     FINISH
     74   11  KEITH MCDERMOTT          07:57    24:42.5

The hardest part of the entire race was definitely the climb back up the back of the stadium. That is quite a steep incline!  (You can tell where this was on the track by looking at the darkest part of the heat-map for my run of the 5k to the right.  I actually just walked part of the way up!)

Despite the one slow-part I encountered, I did enjoy the race and would definitely run it again and recommend it to others.  It was the inaugural race so of course there will be kinks to work out, but it can only get better over time!

Enjoy a small gallery below of pics of runners from the half marathon and others in the 5k portion as well.


AMP Stack on Mountain Lion

Last night I started getting back into coding but have since switched how I develop.  All my code is now (finally) in a local Git repository which is fantastic, but the next step was to get a local server running so I could actually see the results of my work.

In the past, I’ve used Dropbox to sync the code between my workstations and to a Linux virtual machine which ran a web server.  The problem with this setup is that when it failed, it failed miserably.  The issue here was with Dropbox.  The Linux client is quite crappy and is prone to failure very easily – at least the command line version.  The version which integrates into Nautilus seemed a lot more stable.

So, I decided to go back to my old buddy, Mac OS X and use the server capabilities built-in.  I’d check-in code and test using a local server.  However, in Mountain Lion, Apple removed “Web Sharing” from the Sharing pane of Preferences.  After a bit of searching though, it was obvious that although the GUI was removed, the services weren’t.  Follow the directions below to enable an Apache + MySQL + PHP Stack on Mountain Lion that allows .htaccess file directives and has a few tweaks to php.ini.

1.  Configure Apache

sudo vi /etc/apache2/httpd.conf

Find the php5_module and uncomment the line.

#LoadModule perl_module libexec/apache2/
LoadModule php5_module libexec/apache2/
#LoadModule hfs_apple_module libexec/apache2/

Next, I changed the default virtual domain to point to my local document root and set the User/Group as myself.  I also enabled directives to allow .htaccess to work.

#User _www
#Group _www
User keith
Group staff
#DocumentRoot "/Library/WebServer/Documents"
DocumentRoot "/Users/keith/code"
#<Directory "/Library/WebServer/Documents">
<Directory "/Users/keith/code">
   Options Indexes FollowSymLinks MultiViews
   #AllowOverride None
   AllowOverride All
   Order allow,deny
   Allow from all

2.  Configure PHP

Next up, we need to configure PHP to have a proper date timezone set.  This reduces errors/warnings which could show up. We will also enable short_open_tags. Not necessary for most setups, but can be useful.

sudo cp /etc/php.ini.default /etc/php.ini
sudo vi /etc/php.ini
; Defines the default timezone used by the date functions
; date.timezone
date.timezone = "America/New_York"
;short_open_tag = Off
short_open_tag = On

3.  Install & Configure MySQL

The MySQL libraries are actually built-in to the PHP that ships with Mountain Lion.  If you do not need any of the command line tools and will only connect to a remote server, you can skip to the next step.

4.  Set Apache to run on boot

Run the following command to have Apache start at boot

sudo defaults write /System/Library/LaunchDaemons/org.apache.httpd Disabled -bool false

Congratulations! You’ve now configured Apache2, MySQL and PHP to play nicely together on OS X Mountain Lion in a more standardized way than the default Apple configs would normally allow.
Leave a comment if you have any questions or suggestions!