diff options
-rw-r--r-- | bin/mongrel_rails | 5 | ||||
-rw-r--r-- | lib/mongrel/configurator.rb | 2 |
2 files changed, 3 insertions, 4 deletions
diff --git a/bin/mongrel_rails b/bin/mongrel_rails index d2c7b2b..310ee6e 100644 --- a/bin/mongrel_rails +++ b/bin/mongrel_rails @@ -167,7 +167,7 @@ class Stop < GemPlugin::Plugin "/commands" options [ ['-c', '--chdir PATH', "Change to dir before starting (will be expanded)", :@cwd, nil], ['-f', '--force', "Force the shutdown.", :@force, false], - ['-P', '--pid FILE', "Where to write the PID", :@pid_file, "log/mongrel.pid"] + ['-P', '--pid FILE', "Where the PID file is located", :@pid_file, "log/mongrel.pid"] ] end @@ -175,7 +175,6 @@ class Stop < GemPlugin::Plugin "/commands" if @cwd @cwd = File.expand_path(@cwd) valid_dir? @cwd, "Invalid path to change to during daemon mode: #@cwd" - @pid_file = File.join(@cwd,@pid_file) end valid_exists? @pid_file, "PID file #@pid_file does not exist. Not running?" @@ -202,7 +201,7 @@ class Restart < GemPlugin::Plugin "/commands" options [ ['-c', '--chdir PATH', "Change to dir before starting (will be expanded)", :@cwd, nil], ['-s', '--soft', "Do a soft restart rather than a process exit restart", :@soft, false], - ['-P', '--pid FILE', "Where to write the PID", :@pid_file, "log/mongrel.pid"] + ['-P', '--pid FILE', "Where the PID file is located", :@pid_file, "log/mongrel.pid"] ] end diff --git a/lib/mongrel/configurator.rb b/lib/mongrel/configurator.rb index e7af9a9..cd4ca9a 100644 --- a/lib/mongrel/configurator.rb +++ b/lib/mongrel/configurator.rb @@ -172,7 +172,7 @@ module Mongrel if RUBY_PLATFORM !~ /mswin/ require 'daemons/daemonize' - Daemonize.daemonize(log_file=File.join(ops[:cwd], ops[:log_file])) + Daemonize.daemonize(log_file=ops[:log_file]) # change back to the original starting directory Dir.chdir(ops[:cwd]) |