Set WatchdogSec=0 in Puma systemd unit template

The original template sets WatchdogSec=10, which causes systemd to kill
Puma if it remains silent for more than 10 seconds.

This commit changes WatchdogSec to 0 in our custom puma.service.erb,
disabling the watchdog feature. This prevents unwanted restarts and
avoids errors like:
> consul_puma_staging.service: Failed with result 'watchdog'
This commit is contained in:
taitus
2025-05-13 18:53:56 +02:00
parent 034ecfeacd
commit 7712e7a3cf

View File

@@ -16,7 +16,7 @@ After=syslog.target network.target
[Service]
Type=<%= service_unit_type %>
WatchdogSec=10
WatchdogSec=0
<%="User=#{puma_user(@role)}" if fetch(:puma_systemctl_user) == :system %>
WorkingDirectory=<%= current_path %>
ExecStart=<%= expanded_bundle_command %> exec puma -e <%= fetch(:puma_env) %>