"""Read-only US runtime audit; never print environment values or credentials.""" import runpy from pathlib import Path ROOT = Path(__file__).resolve().parents[1] client = runpy.run_path(str(ROOT / 'apps/admin/deploy/_upload_next_us.py'))['connect']() try: command = r'''systemctl list-unit-files 'nomadro*' --no-pager systemctl show nomadro-notify nomadro-coffee -p LoadState -p FragmentPath -p WorkingDirectory -p ExecStart --no-pager ss -lntp | head -25 ls /var/www/nomadro.cn/apps/api/notify_main.py /var/www/nomadro.cn/apps/api/coffee_main.py /var/www/nomadro.cn/apps/api/.venv-social/bin/uvicorn find /etc/systemd/system -maxdepth 1 \( -iname '*coffee*' -o -iname '*notify*' \) ''' _, output, error = client.exec_command(command, timeout=30) print(output.read().decode('utf-8', 'replace')) print(error.read().decode('utf-8', 'replace')) finally: client.close()