<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Racker Hacker &#187; ruby on rails</title>
	<atom:link href="http://rackerhacker.com/tag/ruby-on-rails/feed/" rel="self" type="application/rss+xml" />
	<link>http://rackerhacker.com</link>
	<description>Words of wisdom from a server administrator</description>
	<lastBuildDate>Wed, 16 May 2012 12:55:04 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.2</generator>
		<item>
		<title>Writing a Ruby on Rails application without using a database</title>
		<link>http://rackerhacker.com/2009/01/09/writing-a-ruby-on-rails-application-without-using-a-database/</link>
		<comments>http://rackerhacker.com/2009/01/09/writing-a-ruby-on-rails-application-without-using-a-database/#comments</comments>
		<pubDate>Fri, 09 Jan 2009 17:00:44 +0000</pubDate>
		<dc:creator>Major Hayden</dc:creator>
				<category><![CDATA[Blog Posts]]></category>
		<category><![CDATA[database]]></category>
		<category><![CDATA[ruby on rails]]></category>

		<guid isPermaLink="false">http://rackerhacker.com/?p=687</guid>
		<description><![CDATA[Some of you may be wondering "why would you want to use Rails without a database?" There are several situations why a database would not be needed, and I've run into quite a few of them. One of the specific cases was when I wanted to write a web interface for an application that only [...]<p><a href="http://rackerhacker.com/2009/01/09/writing-a-ruby-on-rails-application-without-using-a-database/">Writing a Ruby on Rails application without using a database</a> is a post from: Major Hayden's <a href="http://rackerhacker.com">Racker Hacker</a> blog. 
<p>Thanks for following the blog via the RSS feed. Please don't copy my posts or quote portions of them without attribution.</p></p>
]]></description>
			<content:encoded><![CDATA[<p>Some of you may be wondering "why would you want to use Rails without a database?"  There are several situations why a database would not be needed, and I've run into quite a few of them.  One of the specific cases was when I wanted to write a web interface for an application that only had a REST interface available to the public.</p>
<p>If you find yourself needing to write a Rails application without a database, just do the following:</p>
<p><strong>For Rails 1.0 and up:</strong><br />
<code>config/environment.rb</code>:</p>

<div class="wp_syntax"><div class="code"><pre class="rails" style="font-family:monospace;">config.<span style="color:#9900CC;">frameworks</span> <span style="color:#006600; font-weight:bold;">-</span>= <span style="color:#006600; font-weight:bold;">&#91;</span> <span style="color:#ff3333; font-weight:bold;">:active_record</span> <span style="color:#006600; font-weight:bold;">&#93;</span></pre></div></div>

<p><code>test/test_helper.rb</code></p>

<div class="wp_syntax"><div class="code"><pre class="rails" style="font-family:monospace;"><span style="color:#9966CC; font-weight:bold;">class</span> <span style="color:#CC00FF; font-weight:bold;"><span style="color:#6666ff; font-weight:bold;">Test::Unit::TestCase</span></span>
  <span style="color:#0000FF; font-weight:bold;">self</span>.<span style="color:#9900CC;">use_transactional_fixtures</span> = <span style="color:#0000FF; font-weight:bold;">false</span>
  <span style="color:#0000FF; font-weight:bold;">self</span>.<span style="color:#9900CC;">use_instantiated_fixtures</span>  = <span style="color:#0000FF; font-weight:bold;">false</span>
  <span style="color:#9966CC; font-weight:bold;">def</span> load_fixtures
  <span style="color:#9966CC; font-weight:bold;">end</span>
<span style="color:#9966CC; font-weight:bold;">end</span></pre></div></div>

<p><strong>For Rails 2.1 and up:</strong> Comment out both of the lines that begin with  <code>ActiveRecord::Base</code> in <code>config/initializers/new_rails_defaults.rb</code>:</p>

<div class="wp_syntax"><div class="code"><pre class="rails" style="font-family:monospace;"><span style="color:#9966CC; font-weight:bold;">if</span> <span style="color:#9966CC; font-weight:bold;">defined</span>?<span style="color:#006600; font-weight:bold;">&#40;</span>ActiveRecord<span style="color:#006600; font-weight:bold;">&#41;</span>
  <span style="color:#008000; font-style:italic;"># Include Active Record class name as root for JSON serialized output.</span>
  <span style="color:#008000; font-style:italic;"># ActiveRecord::Base.include_root_in_json = true</span>
&nbsp;
  <span style="color:#008000; font-style:italic;"># Store the full class name (including module namespace) in STI type column.</span>
  <span style="color:#008000; font-style:italic;"># ActiveRecord::Base.store_full_sti_class = true</span>
<span style="color:#9966CC; font-weight:bold;">end</span></pre></div></div>

<p>For more details, review the <a href="http://wiki.rubyonrails.org/rails/pages/HowToUseRailsWithoutADatabase">full article</a> on <a href="http://rubyonrails.org">rubyonrails.org</a>.</p>
<p><a href="http://rackerhacker.com/2009/01/09/writing-a-ruby-on-rails-application-without-using-a-database/">Writing a Ruby on Rails application without using a database</a> is a post from: Major Hayden's <a href="http://rackerhacker.com">Racker Hacker</a> blog. 
<p>Thanks for following the blog via the RSS feed. Please don't copy my posts or quote portions of them without attribution.</p></p>
]]></content:encoded>
			<wfw:commentRss>http://rackerhacker.com/2009/01/09/writing-a-ruby-on-rails-application-without-using-a-database/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Enabling Ruby on Rails support for a domain in Plesk</title>
		<link>http://rackerhacker.com/2008/08/11/enabling-ruby-on-rails-support-for-a-domain-in-plesk/</link>
		<comments>http://rackerhacker.com/2008/08/11/enabling-ruby-on-rails-support-for-a-domain-in-plesk/#comments</comments>
		<pubDate>Tue, 12 Aug 2008 01:16:18 +0000</pubDate>
		<dc:creator>Major Hayden</dc:creator>
				<category><![CDATA[Blog Posts]]></category>
		<category><![CDATA[mod_rewrite]]></category>
		<category><![CDATA[plesk]]></category>
		<category><![CDATA[ruby on rails]]></category>

		<guid isPermaLink="false">http://rackerhacker.com/?p=389</guid>
		<description><![CDATA[If you have Plesk 8.1 or later, you have support available for Ruby on Rails. Unfortunately, clicking the FastCGI checkbox in Plesk won't get you all of the support you need (and expect). The folks over at Parallels created a relatively simple process to get Ruby on Rails working properly on your site: Go to [...]<p><a href="http://rackerhacker.com/2008/08/11/enabling-ruby-on-rails-support-for-a-domain-in-plesk/">Enabling Ruby on Rails support for a domain in Plesk</a> is a post from: Major Hayden's <a href="http://rackerhacker.com">Racker Hacker</a> blog. 
<p>Thanks for following the blog via the RSS feed. Please don't copy my posts or quote portions of them without attribution.</p></p>
]]></description>
			<content:encoded><![CDATA[<p>If you have Plesk 8.1 or later, you have support available for Ruby on Rails.  Unfortunately, clicking the FastCGI checkbox in Plesk won't get you all of the support you need (and expect).  The folks over at Parallels created a <a href="http://kb.parallels.com/en/5489">relatively simple process</a> to get Ruby on Rails working properly on your site:</p>
<p>Go to your domain that you want to adjust, and click <b>Setup</b>.  Make sure the <b>CGI</b> and <b>FastCGI</b> options are enabled.  Pick a name for your application and make the directory for your application in the <b>httpdocs</b> directory.  Upload your files to that directory.</p>
<p>Once you've done that, create an <b>.htaccess</b> file in the <b>httpdocs</b> directory with the following text inside:</p>
<p><code>RewriteEngine On<br />
RewriteRule ^$ /public/index.html [L]<br />
RewriteCond % !^/railsapp/public<br />
RewriteRule ^(.*)$ /public/$1 [L]<br />
RewriteCond % !-f<br />
RewriteRule ^(.*)$ public/dispatch.fcgi/$1 [QSA,L]</code></p>
<p>Remove the <b>.htaccess</b> file within the <b>public</b> directory of your application and add a file called <b>dispatch.fcgi</b> to that directory which contains:</p>
<p><code>#!/usr/bin/ruby</code></p>
<p>You should be able to access your application at http://domain.com/railsapp/.</p>
<p><a href="http://rackerhacker.com/2008/08/11/enabling-ruby-on-rails-support-for-a-domain-in-plesk/">Enabling Ruby on Rails support for a domain in Plesk</a> is a post from: Major Hayden's <a href="http://rackerhacker.com">Racker Hacker</a> blog. 
<p>Thanks for following the blog via the RSS feed. Please don't copy my posts or quote portions of them without attribution.</p></p>
]]></content:encoded>
			<wfw:commentRss>http://rackerhacker.com/2008/08/11/enabling-ruby-on-rails-support-for-a-domain-in-plesk/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

