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