Archive for September, 2006
Buffalo buffalo buffalo
Rails on Dapper
I have been using Rails longer than I have been using Ubuntu, and only one of them has been longer than a year, so this is a de facto Newbie’s guide, but hopefully you’ll find it useful.
After you’re done (and it should take you no more than about 10 minutes), you’ll be able to get a Rails app using MySQL created and running on your local machine using Mongrel. PostgreSQL fans, feel free to use the common parts to form your own guide.
The Prerequisites
Repository Selection
If you have already enabled the security and universe repositories, you can skip this step. I am a big copy-and-paste guy, but this step works better with point-and-click.
Under System on your Gnome panel, under the Administration menu, select Synaptic Package Manager.
In Synaptic, select the Repositories item under the Settings menu. Enable the ‘universe’ repositories for both Dapper LTS and Dapper LTS Updates. (I have enabled multiverse as well, I believe that’s optional.)
Also, you’ll need to enable the Security Updates repository, as it’s not enabled by default. I enable all the security update repositories, but again, enabling the multiverse should be optional.
Quit the application, since we can do the rest using the terminal.
If you use KDE, you’re going to have to figure this out on your own. If you favor the command line for this part as well, you’ll be editing your /etc/apt/sources.list file as described at the Ubuntu guide
Update Your Package Database
Ensure that your system is up-to-date by issuing the following commands. Enabling the security repository should mean that you have quite a lot to upgrade on top of a base installation.
sudo apt-get update
sudo apt-get upgrade
The Main Course
Preparation for Gem Installation
Ruby and C have some close ties, as languages go. Some Ruby gems that we’ll be installing need to do some compilation and installation, so we’ll prepare ourselves with the basics.
Issue the following command in your terminal.
sudo apt-get install gcc build-essential automake subversion
Installing Apache 2, MySQL 5, and PHP 4
If you need PHP5, this isn’t the guide for you. The only reason that I’m installing PHP at all is so I have access to phpMyAdmin.
sudo apt-get install apache2 php4 mysql-client mysql-server phpmyadmin libapache2-mod-php4 libapache2-mod-auth-mysql php4-mysql libmysqlclient15-dev
sudo a2enmod proxy
Why mod_proxy?
I have a Confluence installation on my home machine that I use in conjunction with my DynDNS account. Getting that traffic to flow through your router is outside the scope of this guide, but I need to proxy my incoming HTTP traffic. Hence, mod_proxy is in the guide!
Installing Ruby
The gems that you’ll install later require the Ruby development package.
sudo apt-get install ruby irb ri rdoc ruby1.8-dev
Installing Ruby Gems
You’ll appreciate not having to depend on Ubuntu and upstream supplying you with the latest version of RubyGems, especially when it plays so nicely with the system you’ve set up so far.
wget http://rubyforge.org/frs/download.php/11289/rubygems-0.9.0.tgz
tar zxvf rubygems-0.9.0.tgz
cd rubygems-0.9.0
sudo ruby setup.rb
Installing the Gems
sudo gem install rails mysql mongrel --include-dependencies
Rails and Mongrel have dependencies. mysql and mongrel have different versions you’ll have to choose from. If this is a development box, why not choose the newest of each? If it’s a production box, I make no claims that any particular version of a any gem is production ready. Make sure to pick the “ruby” versions, since you’re on Dapper.
Done!
Check out something like Mephisto, Typo, or issue your standard rails command along with a
mongrel_rails start
and that should do the trick.
Author’s Note on Lighttpd and Mongrel
Many users have used lighttpd as a replacement for Apache because of the latter’s support of FastCGI, uh… leaves something to be desired. I’ve had to learn how to use it as part of the long-time recommended stack over a TextDrive, where they know their Rails. I still use it there, but, to me, Mongrel is far superior, especially for a development environment. It’s like Webrick, only it appears to be more than suitable for production use. Add the ease of installation factor, and it’s a no-brainer for me to endorse. As always, YMMV.
If You’re Reading This…
For those who don’t speak geek, just stop reading.
Moving my typo blog away from TextDrive has been successful. It was just too much trouble trying to survive my encounters with the TextSamurai while running lighttpd there. Typo and lighttpd don’t exactly give me the warm fuzzies any longer.
CVREG
The Central Virginia Ruby Enthusiasts’ Group is up and running!
I’ve certainly been part of many non-profit groups, but I have never really started one. I couldn’t be more excited to see how this all turns out. We’ve got a great group of people already coming to the meeting, and we just recently got our website up with more details.
If you’re reading my blog for that sort of thing, go check it out! There may be some interesting content there for you eventually.
Megan’s New Car!
It was almost two months ago now, but Megan got a new car. A Toyota Matrix which is doing pretty well.
Here it is in our driveway!

Stranger In A Familiar Land
This post is contuining in my now-current tradition of posting about events several months later.
The annual family vacation to Wilmington, NC this year was a lot of fun. Not only did I get engaged, but we played tennis, got to the beach, watched some movies, ate some great food and played some cards. I also got to visit Brady down in South Carolina. We really enjoyed our trip down to South Carolina for her wedding a couple of weeks ago as well.
The only troubling thought was the realization that even after living in Wilmington for about two years, when I come back in another two, the only thing I may know about the town is where most of the roads go. Established restaurants, cornerstones of the town, are opening up sister restaurants, moving, or closing down. Movie theaters are closing down. They’re building new roads that circle the town, making everything more convenient, but I felt like a tool when I took us on a 45 minute drive that could have taken 15.
I have never really cared if any town has changed, as long as I like the changes. (Most of the changes in Wilmington are for the better.) But in this case, I still wish those changes had never happened. At some point, I’ll look back and any trace of the life Erin and I led will be gone. Memory only helps so much. It’s a process—I’m still getting used to it.
Quickies
- Megan’s blogging a lot more than I am now. How embarrassing! But I couldn’t be happier at the prospect, since we’re already talking about how differently we value and treat our memories.
- We’ve decided on a couple of wedding details. We’re getting married at the Dominion Club here in Richmond. Megan has already bought her dress, and my sister has already bought one of the bridesmaid dresses, since one of the colors has also been selected. We’re working on getting the budget for the food put together, then a lot of other pieces will fall into place.
- I’ve fiddled around with the blog software that powers this blog, and, as much as I’d like to say otherwise, I’m likely to be on this software for the near future.
- I am very happy having moved my Tracks installation to my friend Ryan’s GTDTracks service. It’s very affordable, considering I was spending much more than its monthly cost trying to keep it running on my own machine at home.
- My favorite Wiki is available for free to non-profits. I’ve chosen Rose Hosting since they offered Debian Sarge at a reasonable monthly rate. Hopefully, CISV will finally have a wiki that won’t scare people and that can keep out the thugs.
- I’m hopeful that the CISV USA website redesign project will begin relatively soon. We’re waiting on a design from International.
- I don’t think that I’ve announced that I’m in the most fun fantasy league I’ve ever been in. I’m also doing quite alright. My goal was to score 55 points (in a 10-team league, that’s moderately above average) and to finish “in the pack”. I’m a little behind that, currently, but at one point I was in third place. I’ve got a better team for the future than I thought I would have. My off-season will now be visited by monsters.
- I had a great time during a visit with Jeremy last week. I have been a bit concerned at various times during our past discussions that attempting to merge our outlooks would result in more heat than light, but now I’m more hopeful that we’ll both learn a lot from the process.
- I am, of course, salivating at the prospect of another football season. Especially one where I’ll get to see my first UVA Cavaliers game. I’ll be at the Thursday night game, Oct. 19, against the North Carolina Tar Heels.
- Last night’s UT-Florida game is just another example of why I love college football. Dramatic, huge momentum changes, great football played by young men on both sides, lots of mental toughness, and a bunch of great stories. I loved it, even if UT did take the loss.
Plants
While we were on vacation, our yard was magically transformed from one with builder’s grade holly bushes and juniper stumps to one with two full beds around the two main edges of the house, a new tree, and new beds under the existing tree and by our mailbox.
It’s been exciting for many reasons.
First, I finally feel like the neighborhood has evidence that we care about how our house looks. Those stumps have been out in the yard for about a year, and no matter if Megan prefers that to the alternative, it’s still tacky.
Second, the plants themselves are very nice. I felt like Kathy really listened to us and knew what we wanted. That really showed up in the final results.
Third, I’ve never really had such visible evidence of “Wow, I watered it and now it’s really growing!” It’s a bonding experience, espcecially for such a techie like myself. We have some really excellent rose bushes! They are a new kind of rose, apparently, and they’ve already taken off.
Finally, the watering and weeding (at this point) is very centering for me. Spending a few minutes thinking of nothing besides covering some beds with water is very Zen like. I’ve even done some weeding over the past couple of days—it’s so frustrating to see some stupid onion shoots in the middle of all those beautiful plants!
A Story Without Love
Unfortunately for all of us Virginia residents, our Department of Motor Vehicles is bereft of love.
The Setup
Today’s goal was to transfer the title of the car I’ve been driving for many years into my name. My parents were the previous owners, and they own the car outright.
They signed the title over to me quite some time ago. The task of transferring the title, getting new tags, and getting new insurance fell to me.
Upon my visit today, I was told that I needed to add the number of miles on the odometer to the title before the transfer. I went out to the car and did that, but wrote down the number incorrectly. Thinking that an accurate number was most important, I changed the “2” to a “1”.
I was then denyed the ability to transfer the title based on this act. Even though the owners of the car had expressed their intent to sell the car to me, and I had indicated my intention to buy the car, the state would not allow the transaction to take place.
After pointing out that his insistence upon a correct number would only carry what one might call societal weight based on the purchaser’s (read: my) right to a fair bill of goods, and that I would be happy to waive that right and stipulate that the higher mileage figure was accurate. I was told the central office in the city of Richmond audits the odometer section for cross-outs, erasures, etc. and in case of an error of this nature is processed, the particular branch where I was making the request is penalized.
After pointing out that the number is not in error, and that my “service” representative could verify the mileage on the car easily right now, he said that fact was immaterial, as the car will not be available when the audit is being performed.
As a result, I will be unable to transfer the title until I send the title back to my parents for reverification. The title will have to go through the mail twice, and I will have to wait at the DMV again.
I am already one week past my registration deadline, although that, of course, is no fault of the Virginia Department of Motor Vehicles but rather, tragically, my own ignorance.
The Sting
As this post’s namesake indicates, a story without love is not worth telling. So even though the aggravation is not yet over, you will see that there is reason and benevolence yet still.
I was stopped by a policeman while driving to work after this DMV debacle because my registration and plates had expired. Obviously, my next step was to give him a very abbreviated version of the story I have just shared with you here.
He gave me a warning for everything I still needed to do with the car. If I am stopped again, I will receive those tickets, which come to about $1,000 if I were to actually end up paying them. By listening to reason and giving me a chance, he ensured that the State of Virginia will get taxes on at least one additional week’s rental of an automobile.