java配置irport,一个production模式下的Ror环境搭建-airport -JavaEye技术社区
比較了一些ROR的生產(chǎn)環(huán)境,經(jīng)過(guò)測(cè)試,還是選用了mongrel+apache的方式。
1.download安裝包:
httpd-2.2.3.tar.gz ,apache服務(wù)器
ruby-1.8.5.tar.gz
rubygems-0.9.0.tgz
mongrel-0.3.13.4.gem
2.安裝ruby
tar zxvf ruby-1.8.5.tar.gz
./configure
make
make install
3.安裝rubygems
tar zxfv rubygems-0.9.0.tgz
cd rubygems-0.9.0
ruby setup.rb
# gem update - system
4.安裝rails
gem install rails --include-dependencies
5.安裝mongrel
#gem install daemons
#gem install gem_plugin 如果提示需要?jiǎng)t安裝
gem install mongrel
6.安裝apache
tar zxvf httpd-2.2.3.tar.gz
./configure --prefix=/usr/local/apache
make
make install
7.啟動(dòng)mongrel
cd myrailsapp
#啟動(dòng)
mongrel_rails start -d -p 8000 -e production -P ./log/mongrel-1.pid
#停止
mongrel_rails stop -P ./log/mongrel-1.pid
8.編輯httpd.conf
代碼
ServerName?myapp.com
ServerAlias?www.myapp.com
ProxyPass?/?http://www.myapp.com:8000/
ProxyPassReverse?/?http://www.myapp.com:8000
ProxyPreserveHost?on
ProxyPass?/images?!
ProxyPass?/stylesheets?!
Alias?/images?/path/to/public/images
Alias?/stylesheets?/path/to/public/stylesheets
#continue?with?aliases?for?static?content
改天把測(cè)試數(shù)據(jù)整理出來(lái),包括cluster應(yīng)用!
總結(jié)
以上是生活随笔為你收集整理的java配置irport,一个production模式下的Ror环境搭建-airport -JavaEye技术社区的全部?jī)?nèi)容,希望文章能夠幫你解決所遇到的問(wèn)題。
- 上一篇: 医疗:OA(6)
- 下一篇: Java实现简易文本编辑器