Pay-then-profile join desk with live card, S3 upload fallback, hydration-safe drafts; document on test9 README. Co-authored-by: Cursor <cursoragent@cursor.com>
39 lines
1.1 KiB
Python
39 lines
1.1 KiB
Python
#!/usr/bin/env python3
|
|
# -*- coding: utf-8 -*-
|
|
import sys
|
|
import paramiko
|
|
|
|
sys.stdout.reconfigure(encoding="utf-8", errors="replace", line_buffering=True)
|
|
|
|
CMD = r"""
|
|
set +e
|
|
echo '=== local next proxy ==='
|
|
curl -sS -m 10 http://127.0.0.1:4003/api/work/v1/boards | head -c 400; echo
|
|
curl -sS -m 10 http://127.0.0.1:4003/api/work/v1/health | head -c 200; echo
|
|
echo '=== node fetch ==='
|
|
cd /var/www/nomadro.cn
|
|
node <<'NODE'
|
|
fetch('http://127.0.0.1:8021/api/work/v1/boards')
|
|
.then(async (r) => {
|
|
console.log('status', r.status);
|
|
console.log((await r.text()).slice(0, 200));
|
|
})
|
|
.catch((e) => console.error('ERR', e));
|
|
NODE
|
|
echo '=== disk routes ==='
|
|
ls -la src/app/api/work/v1/ || true
|
|
find src/app/api/work -type f | head -40
|
|
echo '--- .next ---'
|
|
find .next/server/app/api/work -type f 2>/dev/null | head -50
|
|
"""
|
|
|
|
c = paramiko.SSHClient()
|
|
c.set_missing_host_key_policy(paramiko.AutoAddPolicy())
|
|
c.connect("108.174.50.68", 22, "root", "Xiao4669805", timeout=40, allow_agent=False, look_for_keys=False)
|
|
_, o, e = c.exec_command(CMD, timeout=60)
|
|
print(o.read().decode())
|
|
err = e.read().decode()
|
|
if err.strip():
|
|
print("STDERR", err[-2000:])
|
|
c.close()
|