From f71018f665f97b4c876a1548f1ffd43a042fb928 Mon Sep 17 00:00:00 2001 From: Yoann Lecuyer Date: Sat, 23 May 2020 19:27:51 +0200 Subject: [PATCH] Minor: Add running_from to state_file --- lib/puma/launcher.rb | 1 + lib/puma/state_file.rb | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/puma/launcher.rb b/lib/puma/launcher.rb index b506ec701f..90646b7a73 100644 --- a/lib/puma/launcher.rb +++ b/lib/puma/launcher.rb @@ -111,6 +111,7 @@ def write_state sf.pid = Process.pid sf.control_url = @options[:control_url] sf.control_auth_token = @options[:control_auth_token] + sf.running_from = File.expand_path('.') sf.save path, permission end diff --git a/lib/puma/state_file.rb b/lib/puma/state_file.rb index 6aa8fad4d6..9ea74a8ca8 100644 --- a/lib/puma/state_file.rb +++ b/lib/puma/state_file.rb @@ -19,7 +19,7 @@ def load(path) @options = YAML.load File.read(path) end - FIELDS = %w!control_url control_auth_token pid! + FIELDS = %w!control_url control_auth_token pid running_from! FIELDS.each do |f| define_method f do