内网穿透
Frp内网穿透的相关指引
OpenWrt单网口进行端口转发
XUI面板安装及节点IP设置
nps服务端配置信息详解
华硕固件路由器安装nps服务提示目录read-only
首页
-
+
XUI面板安装及节点IP设置
## 一、Docker安装 在root目录下新建2个目录`x-ui`和`cert`,在SSH工具运行下列命令: ```c docker run -itd --network=host \ -v $PWD/db/:/root/x-ui/ \ -v $PWD/cert/:/root/cert/ \ --name x-ui --restart=unless-stopped \ enwaiax/x-ui:latest ``` 然后输入ip:54321,即可打开x-ui面板, ## 二、脚本安装 ### 1.安装脚本 ```c bash <(curl -Ls https://gitlab.com/rwkgyg/x-ui-yg/raw/main/install.sh) ``` 单独安装无法访问,可试试安装宝塔面板后,再重新安装 ```c yum install -y wget && wget -O install.sh https://download.bt.cn/install/install_6.0.sh && sh install.sh ed8484bec ``` ### 2.查看主网卡绑定IP ```c ifconfig ```  主网卡是`enp2s0f0`,进入网卡配置目录修改配置信息,绑定IP ```c cd /etc/sysconfig/network-scripts ``` ```c vi enp2s0f0 ``` ```c TYPE=Ethernet PROXY_METHOD=none BROWSER_ONLY=no BOOTPROTO=none DEFROUTE=yes IPV4_FAILURE_FATAL=no IPV6INIT=yes IPV6_AUTOCONF=yes IPV6_DEFROUTE=yes IPV6_FAILURE_FATAL=no IPV6_ADDR_GEN_MODE=stable-privacy NAME=enp2s0f0 UUID=1d03e98a-f40c-4ecc-961f-1aef9f335361 DEVICE=enp2s0f0 ONBOOT=yes IPADDR=202.58.107.226 PREFIX=29 IPADDR1=202.58.107.227 PREFIX1=29 IPADDR2=202.58.107.228 PREFIX2=29 GATEWAY=202.58.107.225 DNS1=8.8.8.8 IPV6_PRIVACY=no ``` ### 3.将ip地址按下面的代码格式添加 ```c PREFIX2=29 GATEWAY=202.58.107.225 ``` ### 4.修改xui面板中的节点配置 ```c { "dns": { "hosts": { "geo site:netflix": "205.189.160.212" }, "servers": [ "8.8.8.8", "1.1.1.1" ] }, "api": { "services": [ "HandlerService", "LoggerService", "StatsService" ], "tag": "api" }, "inbounds": [ { "listen": "127.0.0.1", "port": 62789, "protocol": "dokodemo-door", "settings": { "address": "127.0.0.1" }, "tag": "api" } ], "policy": { "system": { "statsInboundDownlink": true, "statsInboundUplink": true }, "levels": { "0": { "handshake": 10, "connIdle": 100, "uplinkOnly": 2, "downlinkOnly": 3, "bufferSize": 10240 } } }, "outbounds": [ { "tag": "US1", "sendThrough": "202.58.107.226", "protocol": "freedom", "settings": {} }, { "tag": "US2", "sendThrough": "202.58.107.227", "protocol": "freedom", "settings": {} }, { "protocol": "freedom", "settings": {} }, { "protocol": "blackhole", "settings": {}, "tag": "blocked" } ], "policy": { "system": { "statsInboundDownlink": true, "statsInboundUplink": true } }, "routing": { "rules": [ { "inboundTag": [ "inbound-8001","inbound-8001" ], "outboundTag": "US1", "type": "field" }, { "inboundTag": [ "inbound-8002","inbound-8002" ], "outboundTag": "US2", "type": "field" }, { "inboundTag": [ "api" ], "outboundTag": "api", "type": "field" }, { "ip": [ "geoip:private" ], "outboundTag": "blocked", "type": "field" }, { "outboundTag": "blocked", "protocol": [ "bittorrent" ], "type": "field" } ] }, "stats": {} } ``` - 其中节点名字绑定IP ```c { "tag": "US1", "sendThrough": "202.58.107.226", "protocol": "freedom", "settings": {} }, ``` - 端口与节点名字绑定 ```c { "inboundTag": [ "inbound-8001","inbound-8001" ], "outboundTag": "US1", "type": "field" }, ``` 重启面板即可
laoding
2024年4月12日 18:41
转发文档
收藏文档
上一篇
下一篇
手机扫码
复制链接
手机扫一扫转发分享
复制链接
Markdown文件
分享
链接
类型
密码
更新密码