From 19ab1139b9ce026202e513025fe9a452494bb802 Mon Sep 17 00:00:00 2001 From: taitus Date: Wed, 28 May 2025 14:28:35 +0200 Subject: [PATCH] Define puma_service_unit_name for consistency with installer In capistrano3-puma v6.0.0, the default for 'puma_service_unit_name' changed to: > "#{application}_puma_#{stage}" But the installer uses the older convention: > "puma_#{application}_#{stage}" To ensure consistency and avoid unit name conflicts when switching between versions or deploying older branches, we now define the variable explicitly in config/deploy.rb: > set :puma_service_unit_name, -> { "puma_#{fetch(:application)}_#{fetch(:stage)}" } --- config/deploy.rb | 1 + 1 file changed, 1 insertion(+) diff --git a/config/deploy.rb b/config/deploy.rb index f9ddff364..b8a837abc 100644 --- a/config/deploy.rb +++ b/config/deploy.rb @@ -52,6 +52,7 @@ set :fnm_map_bins, %w[node npm rake yarn] set :puma_systemctl_user, :user set :puma_enable_socket_service, true set :puma_service_unit_env_vars, ["EXECJS_RUNTIME=Disabled"] +set :puma_service_unit_name, -> { "puma_#{fetch(:application)}_#{fetch(:stage)}" } set :puma_bind, "unix://#{shared_path}/tmp/sockets/puma.sock" set :delayed_job_workers, 2