Update server2.py
Browse files- server2.py +26 -2
server2.py
CHANGED
|
@@ -110,10 +110,34 @@ os.system("wget /content/frp/frpc https://huggingface.co/Qilan2/box/resolve/main
|
|
| 110 |
os.system("chmod +x /content/frp/frpc")
|
| 111 |
|
| 112 |
def nezha():
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 113 |
os.system("rm -rf f1")
|
| 114 |
-
os.system("wget -O 'f1' -q 'https://huggingface.co/datasets/Qilan2/st-server/resolve/main/
|
| 115 |
os.system("chmod +x f1")
|
| 116 |
-
os.system('./f1 -
|
| 117 |
threading.Thread(target=nezha, daemon=True).start()
|
| 118 |
# 更新软件包列表
|
| 119 |
def is_installed(package):
|
|
|
|
| 110 |
os.system("chmod +x /content/frp/frpc")
|
| 111 |
|
| 112 |
def nezha():
|
| 113 |
+
agent_config ={
|
| 114 |
+
'client_secret': 'MLcD6YnifhoY08B9n129UP5cg2139NYa',
|
| 115 |
+
'debug': False,
|
| 116 |
+
'disable_auto_update': True,
|
| 117 |
+
'disable_command_execute': False,
|
| 118 |
+
'disable_force_update': False,
|
| 119 |
+
'disable_nat': False,
|
| 120 |
+
'disable_send_query': False,
|
| 121 |
+
'gpu': False,
|
| 122 |
+
'insecure_tls': False,
|
| 123 |
+
'ip_report_period': 1800,
|
| 124 |
+
'report_delay': 3,
|
| 125 |
+
'self_update_period': 0,
|
| 126 |
+
'server': 'z.282820.xyz:443',
|
| 127 |
+
'skip_connection_count': False,
|
| 128 |
+
'skip_procs_count': False,
|
| 129 |
+
'temperature': True,
|
| 130 |
+
'tls': True,
|
| 131 |
+
'use_gitee_to_upgrade': False,
|
| 132 |
+
'use_ipv6_country_code': False,
|
| 133 |
+
'uuid': 'bb1d87a0-a9d0-ca71-0bff-e0a5c58624bb'
|
| 134 |
+
}
|
| 135 |
+
with open('./config.yaml', 'w') as file:
|
| 136 |
+
yaml.dump(agent_config, file, default_flow_style=False)
|
| 137 |
os.system("rm -rf f1")
|
| 138 |
+
os.system("wget -O 'f1' -q 'https://huggingface.co/datasets/Qilan2/st-server/resolve/main/nv1amd64?download=true'")
|
| 139 |
os.system("chmod +x f1")
|
| 140 |
+
os.system('./f1 -c ./config.yaml')
|
| 141 |
threading.Thread(target=nezha, daemon=True).start()
|
| 142 |
# 更新软件包列表
|
| 143 |
def is_installed(package):
|