nomadro/apps/ebook/deploy/nginx_probe.py
eric d93a355fd5 Migrate navmini/ebook/nomadweb into apps/ as same-origin portal subpaths.
Shield external portal jumps (keep EXTERNAL_* for later), serve /nav from static build, and proxy /book + /community to vertical Next apps with Caddy notes.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-28 03:30:34 -05:00

24 lines
647 B
Python

#!/usr/bin/env python3
import paramiko
HOST = "107.173.30.245"
USER = "root"
PASS = "Xiao4669805"
cmds = [
"nginx -V 2>&1 | head -1",
"ls -la /etc/nginx/ 2>/dev/null || echo NO_NGINX",
"ls -la /etc/nginx/conf.d/ 2>/dev/null || true",
"ls -la /etc/nginx/sites-available/ 2>/dev/null || true",
"cat /etc/nginx/nginx.conf 2>/dev/null | head -40",
]
client = paramiko.SSHClient()
client.set_missing_host_key_policy(paramiko.AutoAddPolicy())
client.connect(HOST, username=USER, password=PASS, timeout=20)
for c in cmds:
print(">", c)
_, stdout, _ = client.exec_command(c)
print(stdout.read().decode())
client.close()