Mighty Interactive Homepage

Rails on Windows

Deploying to IIS with lighttpd and Mongrel

by Joseph Jaramillo

Step 5 - Install ImageMagick

  1. Download the RMagick + ImageMagick installer for Windows and extract the archive.
  2. Double-click the ImageMagick installer (ImageMagick-6.4.0-2-Q8-windows-dll.exe) to open it.
  3. Click "Next."
  4. Click the radio button next to "I accept the agreement" and click "Next."
  5. Click "Next" to proceed past the "Information" screen.
  6. Click "Next" to proceed past the "Select Destination Location" screen. Use the default destination.
  7. The ImageMagick installer will create a Start Menu folder. You can customize the name of this folder if desired. Click "Next."
  8. On the "Select Additional Tasks" screen, ensure the following options are checked:

    • → Update executable search path
    • → Install development headers and libraries for C and C++

    Leave all other options unchecked. Click "Next."

  9. Click "Install."

  10. When installation is complete you will be presented with an "Information" screen. Click "Next."
  11. Uncheck "View index.html" and click "Finish."
  12. Open the Command Prompt. (This should be a new Command Prompt).
  13. Navigate to your Desktop in the Command Prompt.
  14. To verify successful completion of this step, type the following and press ENTER:

    convert logo: logo.miff

    This command will appear to have no response, and will return you to the Command Prompt immediately.

  15. Type the following and press ENTER:

    imdisplay logo.miff
  16. Verify that the "IMDisplay" application opened and displayed the logo.miff file. This file shows a wizard with the text "ImageMagick."

  17. Close the "IMDisplay" application and delete the logo.miff file from the Desktop.

ImageMagick installation is complete.

Step 6 - Install RMagick

  1. In the Command Prompt opened in Step 5, navigate to the RMagick directory (RMagick-2.3.0-ImageMagick-6.4.0-2-Q8) inside the installation files directory.
  2. Type the following and press ENTER:

    gem install rmagick --local
  3. Upon completion of this step you will see "1 gem installed."

  4. Close the Command Prompt.

RMagick installation is complete.

Step 7 - Install the ISAPIRewrite Plugin for IIS

The ISAPIRewrite Plugin provides IIS the facilities provided by Apache’s mod_rewrite module, as well as proxy functionality. It will enable IIS to proxy requests to the Rails application server.

  1. Download the ISAPI Rewrite 3 trial. Open it.
  2. Click the radio button next to "I accept the license agreement" and click "Next."
  3. If a "Warning" screen is displayed read the notifications and click "Next."
  4. On the "User Information" screen you can customize the "Full Name" and "Organization" to whom the plugin will be registered during installation, as well as choose whether to make the plugin available to anyone who uses the server, or for the specific user running the installation. It is suggested that the plugin be installed for "Anyone who uses this computer," although you may change this option if you are certain it will not cause any conflicts. These instructions assume installation for all users. When you have made any necessary adjustments, click "Next."
  5. Click "Next" to accept the default "Destination Folder."
  6. Click "Next" to start the installation process.
  7. Click "Finish" to exit the installer.

ISAPIRewrite installation is complete.

Step 9 - Install lighttpd

  1. Download the lighttpd installer. Open it.
  2. Click "Next."
  3. Click "Accept."
  4. Click "Install."

lighttpd installation is complete.

Step 10 - Install the Windows Server 2003 Resource Kit

You may skip this step if you have already installed the Resource Kit.

  1. Open a web browser and navigate to the Microsoft Windows Server 2003 Resource Kit Tools download page.
  2. Click the "Download" button to download the installer. When the installer has finished downloading, open it.
  3. Click "Next."
  4. Click the radio button next to "I Agree" and click "Next."
  5. Customize the names as desired and click "Next."
  6. Click "Install Now" to install to the default directory.
  7. Click "Finish."

The Resource Kit is now installed.

Step 11 - Creating a test Rails application

  1. Open a Command Prompt.
  2. Navigate to the root of your system drive and create a directory called "test" (c:\test)
  3. Navigate to the test directory you just created, and type the following:

    rails testapp

    You will see a list of files being created.

  4. Navigate to the testapp directory (C:\test\testapp)

  5. Type the following and press ENTER:

    ruby script\server -p 4001

    This will launch the Ruby server locally. If you receive a "Windows Security Alert" dialog with the name "Ruby interpreter (CUI) …" click "Unblock."

  6. Leave the Command Prompt open. Open a web browser and point it to the following URL:

    http://localhost:4001
  7. Verify that the Ruby on Rails "Welcome aboard" page is displayed.

  8. Click the "About your application’s environment" link. This will display information about the Ruby on Rails application environment.
  9. Close the web browser, switch back to the Command Prompt, and press CTRL-C (CTRL-BREAK) to kill the Mongrel process.
  10. Close the Command Prompt.

Congratulations! You have successfully configured your environment to support Ruby on Rails applications.

Previous Page | Next Page | 1 | 2 | 3

E-mail Newsletter

Sign up to receive the bi-weekly New York Minute marketing newsletter. You will also receive periodic agency announcements and invitations. View latest issue.


Ruby on Rails – A Mighty Tool

Check out our new section on Ruby on Rails, the Web development platform everyone's talking about. Developers – download our plugins.


You Make Money, We Make Money

Ask us about our results-based pricing model, where we're true business partners with our clients. View a case study about how this approach increased ROI 500% in one year for Esscentual Brands.


Getting results

  • Talking Rock

    A new residential community in Prescott, Arizona Talking Rock needed an effective Internet initiative to generate leads from people interested in purchasing a custom homesite.

    View this case study »


PPC Calculator

Options

change to dark background change to light background