10 lines
336 B
Python
10 lines
336 B
Python
import paramiko
|
|
|
|
c = paramiko.SSHClient()
|
|
c.set_missing_host_key_policy(paramiko.AutoAddPolicy())
|
|
c.connect('140.44.4.71', username='snarf', key_filename=r'C:\Users\Snarf\.ssh\id_ed25519_snarfnet', timeout=10)
|
|
_, o, _ = c.exec_command("ps aux | grep -iE 'exporter|zabbix|telegraf|cadvisor'")
|
|
print(o.read().decode().strip())
|
|
c.close()
|
|
|