Skip to content

Commit

Permalink
subbing out @name in stop function with an ambiguous name.
Browse files Browse the repository at this point in the history
  • Loading branch information
strings48066 committed Apr 17, 2019
1 parent b26f4e0 commit ef90228
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions templates/daemon.sysv.erb
Original file line number Diff line number Diff line change
Expand Up @@ -66,15 +66,15 @@ stop() {
echo -n "Shutting down prometheus <%= @name %>: "
mkpidfile

<%= @name %>_pid=$(cat $PID_FILE)
prometheus_pid=$(cat $PID_FILE)
killproc $KILLPROC_OPT $DAEMON -INT
retcode=$?

# We'll wait if necessary to make sure the leave works, and return
# early if we can. If not, escalate to harsher signals.
try=0
while [ $try -lt $DELAY ]; do
if ! checkpid $<%= @name %>_pid ; then
if ! checkpid $prometheus_pid ; then
rm -f /var/lock/subsys/<%= @name %>
return $retcode
fi
Expand Down

0 comments on commit ef90228

Please sign in to comment.