Replies: 2 comments
-
看下日志,看看是不是这个环境变量的问题 是的话,看下这个#1514 |
Beta Was this translation helpful? Give feedback.
0 replies
-
删除"alterId": 64 |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
服务器端:{
"inbounds": [
{
"port": 10086,
"listen":"127.0.0.1",
"protocol": "VMESS",
"settings": {
"clients": [
{
"id": "手动上码",
"alterId": 64
}
]
},
"streamSettings": {
"network": "ws",
"wsSettings": {
"path": "/ws"
}
}
}
],
"outbounds": [
{
"protocol": "freedom",
"settings": {}
}
]
}
客户端:{
"outbound": {
"protocol": "vmess",
"settings": {
"vnext": [
{
"address": "服务器地址",
"port": 443,
"users": [
{
"id": "手动打码",
"alterId": 64,
"security": "auto"
}
]
}
]
},
"streamSettings": {
"network": "ws",
"security": "tls",
"tlsSettings": {
"allowInsecure": true,
"serverName": ""
},
"tcpSettings": null,
"kcpSettings": null,
"wsSettings": {
"connectionReuse": true,
"path": "/ws",
"headers": { "Host": ""
}
},
"httpSettings": null
},
"mux": { "enabled": true
}
}
}
Nginx配置文件如下:
server {
listen 80;
server_name 服务器IP;
return 301 https://$server_name$request_uri;
}
server {
listen 443 ssl;
listen [::]:443 ssl;
ssl_certificate .crt文件目录地址;
ssl_certificate_key key文件目录地址;
ssl_session_timeout 1d;
ssl_session_cache shared:MozSSL:10m;
ssl_session_tickets off;
root /usr/share/nginx/html;
ssl_protocols TLSv1.2 TLSv1.3;
ssl_ciphers ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:DHE-RSA-AES128-GCM-SHA256:DHE-RSA-AES256-GCM-SHA384;
ssl_prefer_server_ciphers off;
server_name 服务器IP;
location /ws {
if ($http_upgrade != "websocket") {
return 404;
}
proxy_redirect off;
proxy_pass http://127.0.0.1:10086;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
}
}
Beta Was this translation helpful? Give feedback.
All reactions