feat: add cluster auditing, management, and upgrade scripts
This commit is contained in:
18
scripts/fix_uptime_kuma.py
Normal file
18
scripts/fix_uptime_kuma.py
Normal file
@@ -0,0 +1,18 @@
|
||||
import paramiko
|
||||
|
||||
ssh = paramiko.SSHClient()
|
||||
ssh.set_missing_host_key_policy(paramiko.AutoAddPolicy())
|
||||
ssh.connect('140.44.4.11', username='root', key_filename=r'C:\Users\Snarf\.ssh\id_ed25519_snarfnet', timeout=10)
|
||||
|
||||
def run(cmd):
|
||||
print(f"=== {cmd} ===")
|
||||
_, out, err = ssh.exec_command(cmd)
|
||||
print(out.read().decode().strip())
|
||||
e = err.read().decode().strip()
|
||||
if e:
|
||||
print("ERR:", e)
|
||||
|
||||
run("kubectl get deployment uptime-kuma-2-1756668961 -n monitoring -o yaml | grep -A 4 strategy:")
|
||||
run("kubectl get pods -n monitoring -l app.kubernetes.io/name=uptime-kuma")
|
||||
ssh.close()
|
||||
|
||||
Reference in New Issue
Block a user