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