そろそろ自分用に使いながら改良していくつもりなので、サービスとして上がっていないと使いづらい。
ローカルにApacheは入っているんだけど、fastCGIの設定はめんどくさそうだ。
と思っていたら、mongrelがすごく楽だと言うことがわかった。
これを見ながらインストールしてサービスに設定。
H:\Rails\hondana>gem install mongrel Updating metadata for 278 gems from http://gems.rubyforge.org ................................................................................ ................................................................................ ................................................................................ ...................................... complete Successfully installed gem_plugin-0.2.3 Successfully installed cgi_multipart_eof_fix-2.5.0 Successfully installed mongrel-1.1.5-x86-mswin32-60 3 gems installed Installing ri documentation for gem_plugin-0.2.3... Installing ri documentation for cgi_multipart_eof_fix-2.5.0... Installing ri documentation for mongrel-1.1.5-x86-mswin32-60... Installing RDoc documentation for gem_plugin-0.2.3... Installing RDoc documentation for cgi_multipart_eof_fix-2.5.0... Installing RDoc documentation for mongrel-1.1.5-x86-mswin32-60... H:\Rails\hondana>ruby script\server => Booting Mongrel (use 'script/server webrick' to force WEBrick) => Rails application starting on http://0.0.0.0:3000 => Call with -d to detach => Ctrl-C to shutdown server ** Starting Mongrel listening at 0.0.0.0:3000 ** Starting Rails with development environment... ** Rails loaded. ** Loading any Rails specific GemPlugins ** Signals ready. INT => stop (no restart). ** Mongrel 1.1.5 available at 0.0.0.0:3000 ** Use CTRL-C to stop. ** INT signal received. Exiting H:\Rails\hondana>gem install mongrel_service Updating metadata for 16 gems from http://gems.rubyforge.org ................ complete Successfully installed win32-service-0.5.2-x86-mswin32 Successfully installed mongrel_service-0.3.4-x86-mswin32 2 gems installed Installing ri documentation for win32-service-0.5.2-x86-mswin32... Installing ri documentation for mongrel_service-0.3.4-x86-mswin32... Installing RDoc documentation for win32-service-0.5.2-x86-mswin32... Installing RDoc documentation for mongrel_service-0.3.4-x86-mswin32... H:\Rails\hondana>mongrel_rails service::install -N "Hondana.orz" -c h:\rails\hondana -e development ** Copying native mongrel_service executable... Mongrel service 'Hondana.orz' installed as 'Hondana.orz'.
よし、ばっちりだぁ・・・と思ったら文字化けしてた。むぅ、サービスで動かす場合の環境変数ってどこで変えればいいんだ?