试图部署我的第一个rails应用程序

时间:2012-07-03 17:18:38

标签: ruby-on-rails ruby-on-rails-3 vps mediatemple

我正在尝试将我的第一个rails应用程序部署到我的mediatemple(dv)VPS服务器上。我正在使用乘客,我已安装,在我的服务器上创建了一个项目,将文件从我的本地项目复制到我的服务器,创建了db并运行了rake db:migrate和rake db:seed。

当我ping我的网址时,我收到内部服务器错误。

这是我日志文件中的一个片段。在部署第一个rails应用程序时,我们非常感谢您的帮助。

*** Exception PhusionPassenger::InvalidPath in spawn manager (No such file or directory - /var/www/vhost) (process 13560, thread #<Thread:0x000000103890e0>):
    from /usr/local/rvm/gems/ruby-1.9.3-p125/gems/passenger-3.0.11/lib/phusion_passenger/utils.rb:60:in `rescue in canonicalize_path'
    from /usr/local/rvm/gems/ruby-1.9.3-p125/gems/passenger-3.0.11/lib/phusion_passenger/utils.rb:57:in `canonicalize_path'
    from /usr/local/rvm/gems/ruby-1.9.3-p125/gems/passenger-3.0.11/lib/phusion_passenger/classic_rails/application_spawner.rb:120:in `initialize'
    from /usr/local/rvm/gems/ruby-1.9.3-p125/gems/passenger-3.0.11/lib/phusion_passenger/spawn_manager.rb:201:in `new'
    from /usr/local/rvm/gems/ruby-1.9.3-p125/gems/passenger-3.0.11/lib/phusion_passenger/spawn_manager.rb:201:in `block in spawn_rails_application'
    from /usr/local/rvm/gems/ruby-1.9.3-p125/gems/passenger-3.0.11/lib/phusion_passenger/spawn_manager.rb:215:in `call'
    from /usr/local/rvm/gems/ruby-1.9.3-p125/gems/passenger-3.0.11/lib/phusion_passenger/spawn_manager.rb:215:in `block (2 levels) in spawn_rails_application'
    from /usr/local/rvm/gems/ruby-1.9.3-p125/gems/passenger-3.0.11/lib/phusion_passenger/abstract_server_collection.rb:132:in `lookup_or_add'
    from /usr/local/rvm/gems/ruby-1.9.3-p125/gems/passenger-3.0.11/lib/phusion_passenger/spawn_manager.rb:214:in `block in spawn_rails_application'
    from /usr/local/rvm/gems/ruby-1.9.3-p125/gems/passenger-3.0.11/lib/phusion_passenger/abstract_server_collection.rb:82:in `block in synchronize'
    from <internal:prelude>:10:in `synchronize'
    from /usr/local/rvm/gems/ruby-1.9.3-p125/gems/passenger-3.0.11/lib/phusion_passenger/abstract_server_collection.rb:79:in `synchronize'
    from /usr/local/rvm/gems/ruby-1.9.3-p125/gems/passenger-3.0.11/lib/phusion_passenger/spawn_manager.rb:213:in `spawn_rails_application'
    from /usr/local/rvm/gems/ruby-1.9.3-p125/gems/passenger-3.0.11/lib/phusion_passenger/spawn_manager.rb:132:in `spawn_application'
    from /usr/local/rvm/gems/ruby-1.9.3-p125/gems/passenger-3.0.11/lib/phusion_passenger/spawn_manager.rb:275:in `handle_spawn_application'
    from /usr/local/rvm/gems/ruby-1.9.3-p125/gems/passenger-3.0.11/lib/phusion_passenger/abstract_server.rb:357:in `server_main_loop'
    from /usr/local/rvm/gems/ruby-1.9.3-p125/gems/passenger-3.0.11/lib/phusion_passenger/abstract_server.rb:206:in `start_synchronously'
    from /usr/local/rvm/gems/ruby-1.9.3-p125/gems/passenger-3.0.11/helper-scripts/passenger-spawn-server:99:in `<main>'
[ pid=13495 thr=47652788213792 file=ext/apache2/Hooks.cpp:860 time=2012-07-03 10:11:46.536 ]: Unexpected error in mod_passenger: Cannot spawn application '/var/www/vhost/tomstestsite.us/PersonalTrainingKT': The spawn server has exited unexpectedly.
  Backtrace:
     in 'virtual Passenger::SessionPtr Passenger::ApplicationPool::Client::get(const Passenger::PoolOptions&)' (Client.h:742)
     in 'Passenger::SessionPtr Hooks::getSession(const Passenger::PoolOptions&)' (Hooks.cpp:292)
     in 'int Hooks::handleRequest(request_rec*)' (Hooks.cpp:561)

1 个答案:

答案 0 :(得分:2)

(No such file or directory - /var/www/vhost) (process 13560, thread #<Thread:0x000000103890e0>):

表示您配置错误。