新手问题 [以解决] 千辛万苦在 ubuntu 上部署好 rails+apache+Passenger,为什么启动不了。。

lin_style · 2012年06月12日 · 最后由 lyfi2003 回复于 2012年06月13日 · 4572 次阅读

我的 apache2 配置 ServerAdmin webmaster@localhost

DocumentRoot /home/xxx/program/rails/yyy AllowOverride all Options -MultiViews

ErrorLog /home/lindp/log/apache2error.log

# Possible values include: debug, info, notice, warn, error, crit, # alert, emerg. LogLevel warn

CustomLog /home/lindp/log/apache2/access.log combined

一开进去,就显示 树形的浏览目录。查了下,我并没有配置 index 这个选项啊; 2)通过 rails s 可以正常启动和访问

Directory 和 DocumentRoot 应该指向项目的 public 文件夹吧

Started GET "/" for 218.5.2.219 at 2012-06-12 10:38:27 -0400 Processing by UsersController#index as HTML Rendered users/_header.html.erb (2.8ms) Rendered users/_footer.html.erb (0.4ms) Rendered users/index.html.erb within layouts/application (42.9ms) Completed 500 Internal Server Error in 117ms

ActionView::Template::Error (application.css isn't precompiled): 2: 3:

4: ZhongFans 5: <%= stylesheet_link_tag "application", :media => "all" %> 6: <%= javascript_include_tag "application" %> 7: <%= csrf_meta_tags %> 8: app/views/layouts/application.html.erb:5:in `app_views_layouts_application_html_erb_1169807708371911004_34816280'

这是我的部署 log https://github.com/ery/deploy-rails/tree/master/2012.1.12 你可以参考一下,希望有用

楼主可以查一下进程列表看看 Passenger 是否启动啦,也许是 Passenger 没加载上。

OK 了。结贴。。基本上就是网络上说的,装 NODEJS 等

rake assets:precomplie 发布模式加上这个。

需要 登录 后方可回复, 如果你还没有账号请 注册新账号