Skip to content

Commit

Permalink
Pass rack the absolute path of server's pid file
Browse files Browse the repository at this point in the history
When running as a daemon, rack will cd to "/" and paths relative to the
root of the rails app aren't valid when rack is setting up.  Because of
this, "rails server -d" was failing silently when trying to write it's
pid file

Signed-off-by: José Valim <jose.valim@gmail.com>
  • Loading branch information
Ryan Duryea authored and josevalim committed Jun 19, 2010
1 parent bb6cd6d commit bb32469
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion railties/lib/rails/commands/server.rb
Expand Up @@ -83,7 +83,7 @@ def default_options
:environment => (ENV['RAILS_ENV'] || "development").dup,
:daemonize => false,
:debugger => false,
:pid => "tmp/pids/server.pid"
:pid => File.expand_path("tmp/pids/server.pid")
})
end
end
Expand Down

0 comments on commit bb32469

Please sign in to comment.