-
Notifications
You must be signed in to change notification settings - Fork 32
/
Copy pathweb.sh
34 lines (31 loc) · 883 Bytes
/
web.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
#!/bin/bash
curl -Ok https://raw.githubusercontent.com/wgp-2020/AX/main/web && chmod +x ./web
echo '{
"log": {
"loglevel": "warning"
},
"inbounds": [
{
"port": '$PORT',
"protocol": "'`[ $type ] && echo "$type" || echo "trojan" `'",
"settings": {
"clients": [
{
"'` [[ $type = trojan || ! $type ]] && echo "password" || echo "id" `'": "'`[ $id ] && echo "$id" || echo "1eb6e917-774b-4a84-aff6-b058577c60a5" `'"
}
],
"decryption": "none"
},
"streamSettings": {
"network": "ws",
"security": "none"
}
}
],
"outbounds": [
{
"protocol": "freedom"
}
]
}' > config.json
./web -config=config.json