mirror of
https://github.com/mperham/sidekiq.git
synced 2022-11-09 13:52:34 -05:00
Seeing pidfile weirdness with relative paths, maybe this is necessary
This commit is contained in:
parent
3e388d1da1
commit
0e71f97e7c
1 changed files with 3 additions and 2 deletions
|
@ -319,11 +319,12 @@ module Sidekiq
|
|||
|
||||
def write_pid
|
||||
if path = options[:pidfile]
|
||||
File.open(path, 'w') do |f|
|
||||
pidfile = File.expand_path(path)
|
||||
File.open(pidfile, 'w') do |f|
|
||||
f.puts Process.pid
|
||||
end
|
||||
at_exit do
|
||||
FileUtils.rm_f path
|
||||
FileUtils.rm_f pidfile
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue