#122 Passenger in Development

Tired of juggling multiple Rails apps around with script/server? See how to set up Passenger in development so each one has its own local domain name.
Sorry to make this platform specific. It looks like Passenger isn’t available on Windows.
sudo gem install passenger
sudo passenger-install-apache2-module
mate /etc/apache2/httpd.conf
sudo apachectl graceful
mate /etc/hosts
tail -f log/development
touch tmp/restart.txt


# /etc/apache2/httpd.conf

LoadModule passenger_module /Library/Ruby/Gems/1.8/gems/passenger-2.0.2/ext/apache2/mod_passenger.so
PassengerRoot /Library/Ruby/Gems/1.8/gems/passenger-2.0.2
PassengerRuby /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby

NameVirtualHost *:80

<VirtualHost *:80>
ServerName railscasts.local
DocumentRoot "/Users/rbates/code/railscasts/public"
RailsEnv development
RailsAllowModRewrite off
<directory "/Users/rbates/code/railscasts/public">
Order allow,deny
Allow from all
</directory>
</VirtualHost>


# /etc/hosts

127.0.0.1 railscasts.local
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值