From 9c4d79519ced3d0ccf6917e24b32b747e1672c62 Mon Sep 17 00:00:00 2001 From: Leo Soares Date: Wed, 6 Oct 2021 14:03:42 +0100 Subject: [PATCH] autossh: fix procd env issue This commit fixes an issue where the `AUTOSSH_GATETIME` is not available in the `procd` environment which gets overwritten by the second `procd_set_param env` call. It now calls the `procd_set_param env` once with the two variables, instead of twice. Signed-off-by: Leo Soares --- net/autossh/files/autossh.init | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/net/autossh/files/autossh.init b/net/autossh/files/autossh.init index f73e41573..9f6225bb0 100644 --- a/net/autossh/files/autossh.init +++ b/net/autossh/files/autossh.init @@ -18,8 +18,7 @@ start_instance() { procd_open_instance procd_set_param command /usr/sbin/autossh -M ${monitorport:-20000} ${ssh} procd_set_param respawn ${respawn_threshold:-3600} ${respawn_timeout:-5} ${respawn_retry:-5} - procd_set_param env AUTOSSH_GATETIME="${gatetime:-30}" - procd_set_param env AUTOSSH_POLL="${poll:-600}" + procd_set_param env AUTOSSH_GATETIME="${gatetime:-30}" AUTOSSH_POLL="${poll:-600}" procd_close_instance }