From bd64ead300bc99fccfe059c552f71eab9f084e80 Mon Sep 17 00:00:00 2001 From: Ryan Duryea Date: Tue, 4 May 2010 11:49:22 -0700 Subject: [PATCH] Pass rack the absolute path of server's pid file 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 --- railties/lib/rails/commands/server.rb | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/railties/lib/rails/commands/server.rb b/railties/lib/rails/commands/server.rb index 3f74cd4..861baa2 100644 --- a/railties/lib/rails/commands/server.rb +++ b/railties/lib/rails/commands/server.rb @@ -83,7 +83,7 @@ module Rails :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 -- 1.7.0.4