<?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>42 &#187; apache</title>
	<atom:link href="http://www.42.mach7x.com/tag/apache/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.42.mach7x.com</link>
	<description>Thoughts and tips about programming with Ruby on Rails</description>
	<lastBuildDate>Wed, 01 Feb 2012 14:38:36 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Rails Passenger Staging environment problem in Dreamhost</title>
		<link>http://www.42.mach7x.com/2010/09/09/rails-passenger-staging-environment-problem-in-dreamhost/</link>
		<comments>http://www.42.mach7x.com/2010/09/09/rails-passenger-staging-environment-problem-in-dreamhost/#comments</comments>
		<pubDate>Thu, 09 Sep 2010 09:28:07 +0000</pubDate>
		<dc:creator>kosmas</dc:creator>
				<category><![CDATA[Apache]]></category>
		<category><![CDATA[Dreamhost]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[Phusion Passenger]]></category>
		<category><![CDATA[ruby on rails]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[Passenger]]></category>
		<category><![CDATA[phusion passenger]]></category>
		<category><![CDATA[Staging]]></category>

		<guid isPermaLink="false">http://www.42.mach7x.com/?p=226</guid>
		<description><![CDATA[Problem You want to deploy your rails application using Passenger in Dreamhost, but on a staging environment. It doesn&#8217;t work just changing your Capistrano recipe or your environment files, as the default environment for passenger is &#8216;production&#8217;. Solution Looking at the Passenger documentation here, there are four different ways of achieving that by changing the [...]]]></description>
			<content:encoded><![CDATA[<p><strong>Problem</strong><br />
You want to deploy your rails application using Passenger in Dreamhost, but on a staging environment. It doesn&#8217;t work just changing your Capistrano recipe or your environment files, as the default environment for passenger is &#8216;production&#8217;.</p>
<p><strong>Solution</strong><br />
Looking at the Passenger documentation <a href="http://www.modrails.com/documentation/Users%20guide%20Apache.html#rails_env">here</a>, there are four different ways of achieving that by changing the RailsEnv option. If you don&#8217;t want to change the Apache configuration files, and as long as the option AllowOverride is on (which should be on Dreamhost), then you would need to create an .htaccess file in your application&#8217;s public folder with the following:</p>
<p><span class="code">RailsEnv staging</span> </p>
]]></content:encoded>
			<wfw:commentRss>http://www.42.mach7x.com/2010/09/09/rails-passenger-staging-environment-problem-in-dreamhost/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Phusion Passenger installation in Mandriva 2009</title>
		<link>http://www.42.mach7x.com/2009/01/08/phusion-passenger-installation-in-mandriva-2009/</link>
		<comments>http://www.42.mach7x.com/2009/01/08/phusion-passenger-installation-in-mandriva-2009/#comments</comments>
		<pubDate>Thu, 08 Jan 2009 11:30:53 +0000</pubDate>
		<dc:creator>kosmas</dc:creator>
				<category><![CDATA[Mandriva]]></category>
		<category><![CDATA[ruby on rails]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[Passenger]]></category>
		<category><![CDATA[phusion passenger]]></category>
		<category><![CDATA[Rails]]></category>

		<guid isPermaLink="false">http://www.42.mach7x.com/?p=71</guid>
		<description><![CDATA[Problem You have recently installed Mandriva 2009 and you want to install phusion passenger. Solution First make sure that apache is installed. If it is not installed (default), do: urpmi apache On the selection question about the dependencies select option 1 (apache-prefork) Use the details from the phusion passenger website. ie: Install passenger: gem install [...]]]></description>
			<content:encoded><![CDATA[<p><strong>Problem</strong><br />
You have recently installed Mandriva 2009 and you want to install phusion passenger.</p>
<p><strong>Solution</strong></p>
<ol>
<li>First make sure that apache is installed. If it is not installed (default), do:
<pre class="code">urpmi apache</pre>
<p>On the selection question about the dependencies select option 1 (apache-prefork)</li>
<li>Use the details from the phusion passenger website. ie:<br />
Install passenger:</p>
<pre class="code">gem install passenger</pre>
</li>
<li>Run the passenger installation:
<pre class="code">passenger-install-apache2-module</pre>
</li>
<li>If at the second stage of the installation the installer complains that <em>GNU C++ compiler &#8230; not found</em>, install the gnu c++ compiler, with:
<pre class="code">urpmi gcc_c++</pre>
</li>
<li>Run the passenger installation (step 3) again. If at this stage the installer complains that <em>Apache 2 development headers &#8230; not found</em>, use:
<pre class="code">urpmi apache-devel</pre>
</li>
<li>Run passenger installer (step 3), once more. Now everything should be ok and the apache 2 module will be installed when the installer finishes.</li>
<li>Restart the Apache webserver, and you should be able to add your Rails application. Use the following to deploy your application in /somewhere/public:
<pre class="code">&lt;VirtualHost *:80&gt;
  ServerName www.yourhost.com
  DocumentRoot /somewhere/public
&lt;/VirtualHost&gt;</pre>
</li>
</ol>
]]></content:encoded>
			<wfw:commentRss>http://www.42.mach7x.com/2009/01/08/phusion-passenger-installation-in-mandriva-2009/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Disabling rails web site when using mongrel,Apache,capistrano 1.4.1</title>
		<link>http://www.42.mach7x.com/2008/05/07/disabling-rails-web-site-when-using-mongrelapachecapistrano-141/</link>
		<comments>http://www.42.mach7x.com/2008/05/07/disabling-rails-web-site-when-using-mongrelapachecapistrano-141/#comments</comments>
		<pubDate>Wed, 07 May 2008 14:01:46 +0000</pubDate>
		<dc:creator>kosmas</dc:creator>
				<category><![CDATA[ruby on rails]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[capistrano]]></category>
		<category><![CDATA[maintenance]]></category>
		<category><![CDATA[mongrel]]></category>

		<guid isPermaLink="false">http://www.42.mach7x.com/?p=31</guid>
		<description><![CDATA[Problem You want to disable your rails web site for maintenance, but your application uses an older capistrano version than the one currently installed. Solution According to the RubyOnRails Cookbook recipe 13.12, it should only be a case of running cap disable_web (enable_web). But in the meantime you have upgraded your capistrano version to version [...]]]></description>
			<content:encoded><![CDATA[<p><strong>Problem</strong><br />
You want to disable your rails web site for maintenance, but your application uses an older capistrano version than the one currently installed.</p>
<p><strong>Solution</strong><br />
According to the RubyOnRails Cookbook recipe 13.12, it should only be a case of running cap disable_web (enable_web).<br />
But in the meantime you have upgraded your capistrano version to version 2, and started using mongrel server as well.<br />
So if you are using virtual severs and proxy with mongrel, the first thing to do is add the following in your Apache configuration file:</p>
<pre class="code">RewriteEngine On
RewriteCond %{DOCUMENT_ROOT}/system/maintenance.html -f
RewriteCond %{SCRIPT_FILENAME} !maintenance.html
RewriteRule ^.*$ /system/maintenance.html [R]</pre>
<p>If you needed to make the above change then you will have to restart apache in your server.</p>
<p>Then in your local pc you can run the following:</p>
<pre class="code">export REASON="Maintenance for MySQL upgrade"
export UNTIL="Sat May 10 15:30:00 2008"
cap _1.4.1_ disable_web (to put it in maintenance)
cap _1.4.1_ enable_web (to restart it again)</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.42.mach7x.com/2008/05/07/disabling-rails-web-site-when-using-mongrelapachecapistrano-141/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

