Digital Sanctum

software development, technology and other square topics

Archive for January, 2007

Installing Rails and Mongrel on Ubuntu

with 3 comments

So you have ruby installed and now you want to start putting together some web applications. There are several options when it comes to what web server you actually run your app on. More on that in a bit. First let’s install Rails on Ubuntu:

Read the rest of this entry »

Written by Shane

January 27th, 2007 at 10:21 pm

Posted in Ruby, Tutorials

How to Make an ISO Image Using DD

without comments

The basic syntax for dd is:
dd if=INPUT-FILE-NAME of=OUTPUT-FILE-NAME
To make an ISO from your CD/DVD, place the media in your drive but do not mount it. If it automounts, unmount it.

dd if=/dev/dvd of=dvd.iso # for dvd
dd if=/dev/cdrom of=cd.iso # for cdrom
dd if=/dev/scd0 of=cd.iso # if cdrom is scsi

To make an ISO from files on your hard drive, create a directory which holds the files you want. Then use the mkisofs command.

mkisofs -o /tmp/cd.iso /tmp/directory/

This results in a file called cd.iso in folder /tmp which contains all the files and directories in /tmp/directory/.

Written by Shane

January 26th, 2007 at 12:52 am

Posted in Linux, Tutorials

Compiling Ruby on Ubuntu 6.10 (Edgy) How-to

without comments

Here’s a quick and dirty guide for compiling the latest recommended version of Ruby from source on Ubuntu 6.10:

  1. Download ruby-1.8.5-p12.tar.gz and unzip the contents to a temporary directory I’ll call INSTALL_DIR.
  2. Make sure you have what you need to compile: sudo apt-get install build-essential
  3. cd to INSTALL_DIR.
  4. ./configure (Update: you can optionally add –prefix=ALTERNATE_INSTALL_DIR)
    (see update below)
  5. ./make
  6. ./make test (hopefully you will get “test succeeded” as a response).
  7. sudo make install
  8. now test the install: ruby -v should respond with…

    ruby 1.8.5 (2006-12-25 patchlevel 12) [i686-linux]

That’s it!

Next I will document installing Rails on Ubuntu.

Update (2007-01-29): I referred to this post to fix an issue I had with the irb console not working. I had to compile the readline library and recompile ruby. After that, everything worked as expected. I also tried installing to my home directory using the prefix option and never got it to work correctly. In the end, installing using the default paths (/usr/local) worked best.

Written by Shane

January 23rd, 2007 at 10:08 am

From Java to Ruby Journal Part 1: Introduction and the Decision

with one comment

Introduction

This is the first post of many to come documenting my progress of porting an existing e-commerce web application from Java to Ruby on Rails.

Background on the Java Application

The Java application, after three years of nearly no changes to the code (other than routine maintenance and bug fixes) or the look and feel is in desperate need of some enhancements. After seeing Endless.com, the newest production from the folks at Amazon, I knew I wanted the opportunity to do something similar with my client’s slightly outdated and unoriginal website.

Read the rest of this entry »

Written by Shane

January 21st, 2007 at 6:55 pm

The Uber Java Web Application Directory Structure

without comments

As an exercise using a great new open source (free as in beer) tool I discovered called FreeMind, I put together this quick outline of my standard directory structure for Java web applications. It’s mostly based on the Sun guidelines. As far as I can tell the tool is a great alternative to the commercial MindMapper software. View the image below or download a PDF version.

webprojectroot

Written by shane

January 16th, 2007 at 1:25 am