douyinWEB/scripts/_check_neko502.py
eric d409e416da Ship physical dual-edge stack, Studio CDP live metrics, and ops tooling.
Capture Neko/WG/network hubs, Studio viewer charts, physical deploy docs, and one-shot scripts so VPS vs physical can be toggled later without losing WIP.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-04 22:42:40 -05:00

15 lines
782 B
Python

#!/usr/bin/env python3
import paramiko, sys
sys.stdout.reconfigure(encoding='utf-8', errors='replace')
c=paramiko.SSHClient(); c.set_missing_host_key_policy(paramiko.AutoAddPolicy())
c.connect('107.173.30.245',22,'root','Xiao4669805',timeout=45,allow_agent=False,look_for_keys=False)
cmd = r"""
grep -A3 'handle_path /neko/1' /etc/caddy/sites/dy.nomadro.com.caddy
curl -sS -m 15 -o /dev/null -w 'caddy_neko=%{http_code} t=%{time_total}s\n' -k https://127.0.0.1/neko/1/ -H 'Host: dy.nomadro.com'
curl -sS -m 10 -o /dev/null -w 'direct_cn=%{http_code} t=%{time_total}s\n' http://10.9.0.2:9200/
curl -sS -m 10 -o /dev/null -w 'public=%{http_code} t=%{time_total}s\n' https://dy.nomadro.com/neko/1/
"""
_,o,e=c.exec_command(cmd,timeout=60)
print((o.read()+e.read()).decode())
c.close()