From: Dobrica Pavlinusic Date: Sun, 11 Dec 2016 18:03:58 +0000 (+0100) Subject: add SSH="ssh hostname " ./ifstat.pl to run remotly X-Git-Url: http://git.rot13.org/?p=influxdb-pipes;a=commitdiff_plain;h=15e9ba3c2f7f33d52fd7d2c7c672135794b3b069;hp=7876288ebb751c79227346514b667248c00f6017 add SSH="ssh hostname " ./ifstat.pl to run remotly --- diff --git a/ifstat.pl b/ifstat.pl index 8ea8534..3f322b7 100755 --- a/ifstat.pl +++ b/ifstat.pl @@ -22,7 +22,7 @@ sub update_time { # FIXME add -A to pull interfaces if they go up and down # -l loopback # -a all -my $cmd = qq{ifstat -s '$community@#$host' -a -l -b -n -t 1}; +my $cmd = qq{$ENV{SSH}ifstat -s '$community@#$host' -a -l -b -n -t 1}; warn "# $cmd\n"; open(my $ifstat, '-|', $cmd);