Giter Club home page Giter Club logo

x-ui-yg's Introduction

x-ui精简修改版一键脚本,面板中的相关设置近可能与原作者vaxilu保持一致

支持纯IPV4、纯IPV6、AMD64、ARM64的VPS直接安装

支持alpine系统,推荐使用最新的Ubuntu系统

相关说明及注意点请查看博客说明

视频教程:

x-ui搭建xray协议脚本大更新(一):reality协议三模式,数据重置、备份、恢复详细操作

x-ui搭建xray协议脚本大更新(二):集成Argo固定隧道、临时隧道

x-ui搭建xray协议脚本大更新(三):支持多协议聚合订阅,自动生成Clash-meta、Sing-box配置文件

x-ui搭建xray协议脚本大更新(四):支持Alpine系统;ChatGPT客户端可以随便登录了,多IP分流设置详细说明


一键脚本:

bash <(curl -Ls https://raw.githubusercontent.com/yonggekkk/x-ui-yg/main/install.sh)

bash <(wget -qO- https://raw.githubusercontent.com/yonggekkk/x-ui-yg/main/install.sh)

x-ui-yg脚本界面预览图(注:相关参数随意填写,仅供围观)

179ce8b1d5f7b0327dbc8de45f9bdcc



感谢你右上角的star🌟

Stargazers over time

参考项目vaxiluMHSanaeiqist


声明:

所有代码来源于Github参考项目与ChatGPT的整合,二进制文件未开源,介意者请勿安装使用。

x-ui-yg's People

Contributors

yonggekkk avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

x-ui-yg's Issues

关于x-ui分流

请问xray的配置文件应该怎么书写,想根据入站节点分流而不是域名分流
例如vless1,所以流量都会走warp-sock
vless2,入站后所有流量都会走vps原本的ipv4网卡

issues

没什么问题,就是来感谢一些 yg

[求助]Warp代理协议Socks出站不能走IPv6访问站点

你好,冒昧请教你下面的问题,我找了很多地方,试了很多种方法都解决不来,看了你的视频然后过来询问的:

先说明下,我用的不是你的xui是原版的,其他都是手工配置的,理论上应该没区别

我是双栈机器,原本vps就可以访问ChatGTP,浏览器打开 https://chat.openai.com/cdn-cgi/trace 里可以看到IP使用了VPS自己的IPv6地址。

我的目的也很简单就是:再套一层warp(用Warp-cli set-mode proxy的socks代理模式,只想用这个模式), 最终让浏览器以warp的IPv6访问ChatGTP

配置下来后:

1,在VPS上用curl https://chat.openai.com/cdn-cgi/trace --proxy socks5://127.0.0.1:40000 确认VPS默认优先使用了warp的IPv6访问了chatgpt,没问题

2,但我电脑用浏览器访问,但是却显示用了Warp的IPv4地址(还是通过上面的地址查看)。

我想了下,我浏览器应该没问题,因为原本就可以IPv6访问,VPS也没问题,因为上述命令行也是通过代理转发,所以也不是代理模式的问题。那就只能是Xray的问题了?实在搞不懂哪里出了问题,我的配置是这样的,改动的很少:

路由规则如下,增加了分流路由:

   {
        "type": "field",
        "outboundTag": "warp",
        "domain": [
			"openai.com",
			"ai.com",
			"chat.openai.com.cdn.cloudflare.net",
			"openaiapi-site.azureedge.net",
			"ip.sb"
        ]
      },

出站代理和你一样设置转发到socks协议的40000端口,发现只能走warp的IPv4后,我试了下面两种指定"UseIPv6"的设置都不行,无效!!

设置1:增加"streamSettings",在底层sockopt设置策略

    {
      "tag": "warp",
      "protocol": "socks",
      "streamSettings": {
	  "sockopt": {"domainStrategy": "UseIPv6"}
	  },
      "settings": {
        "servers": [
          {
            "address": "127.0.0.1",
            "port": 40000
          }
        ]
      }
    },

设置2:直接在settings里增加策略,这个和你的那个配置文件做法一样

	{
      "tag": "warp",
      "protocol": "socks",

      "settings": {
	   "domainStrategy": "UseIPv6"
        "servers": [
          {
            "address": "127.0.0.1",
            "port": 40000
          }
        ]
      }
    },

恳请您能帮忙分析下哪里有问题,该如何实现我的需求(在用proxy模式的前提下)?

盼望回复,谢谢!

---补充一个情况,上面我还指定了ip.sb,我开启warp后,访问ip.sb页面显示我ipv4是not support,但ipv6显示的是我warp的ipv6的地址(不是我vps自身的那个ipv6地址),所以我就更晕了。。。

切换Xray v.1.8.12版本报错

Xray 1.8.12 (Xray, Penetrates Everything.) 416f2df (go1.22.3 linux/arm64)

A unified platform for anti-censorship.

2024/05/22 18:58:57 [Info] infra/conf/serial: Reading config: bin/config.json

2024/05/22 18:58:57 [Debug] infra/conf: kernel mode is enabled as it's supported and permission is sufficient

2024/05/22 18:58:57 [Warning] core: Xray 1.8.12 started

panic: runtime error: index out of range [-1]

goroutine 98 [running]:

github.com/xtls/xray-core/app/proxyman/outbound.(*Handler).Dial(0x4000124b80, {0x108dea0, 0x1a52f00}, {{0x108e450, 0x40006f28c8}, 0x1051, 0x3})

github.com/xtls/xray-core/app/proxyman/outbound/handler.go:288 +0xac8

github.com/xtls/xray-core/proxy/wireguard.(*netBindClient).connectTo(0x400003d400, 0x40001e9b30)

github.com/xtls/xray-core/proxy/wireguard/bind.go:131 +0x54

github.com/xtls/xray-core/proxy/wireguard.(*netBindClient).Send(0x400003d400, {0x4000dfc060, 0x1, 0xff051cd3e108?}, {0x1092e98?, 0x40001e9b30})

github.com/xtls/xray-core/proxy/wireguard/bind.go:174 +0x54

golang.zx2c4.com/wireguard/device.(*Peer).SendBuffers(0x40004f9508, {0x4000dfc060, 0x1, 0x1})

golang.zx2c4.com/[email protected]/device/peer.go:136 +0x218

golang.zx2c4.com/wireguard/device.(*Peer).SendHandshakeInitiation(0x40004f9508, 0x8?)

golang.zx2c4.com/[email protected]/device/send.go:136 +0x43c

golang.zx2c4.com/wireguard/device.(*Peer).SendStagedPackets(0x40004f9508)

golang.zx2c4.com/[email protected]/device/send.go:350 +0xd4

golang.zx2c4.com/wireguard/device.(*Device).RoutineReadFromTUN(0x400029c788)

golang.zx2c4.com/[email protected]/device/send.go:293 +0x694

created by golang.zx2c4.com/wireguard/device.NewDevice in goroutine 71

golang.zx2c4.com/[email protected]/device/device.go:322 +0x3e8

x-ui restart命令无法重启x-ui及xray内核(无论x-ui后面跟什么参数都会被忽略而直接进菜单)

在安装完x-ui-yg版的x-ui以后,输入x-ui可以正常进入脚本的菜单页面,但是x-ui后面加上的参数被无法识别,比如,本来输入命令x-ui restart就可以让x-ui重启,但是现在输入x-ui restart之后的效果是直接进入脚本菜单而忽略了后面的restart参数,这样导致的结果就是无法使用该命令重启脚本。
还有,这个脚本在crontab中添加了一个每天定时重启脚本的任务,但是现在的结果导致了无法通过x-ui restart命令进行重启,只有输入systemctl restart x-ui.service命令才能重启。这个问题也同样存在于/usr/local/x-ui/goxui.sh中,即使它检测到了xui或xray没有正常运行也无法重启xui。
建议在下一个版本的程序中修正这个问题,只要将x-ui restart换成systemctl restart x-ui.service就行了。
另外,goxui.sh这个保活脚本其实只需要写两行代码即可完成原有功能,它们的功能就是判断x-ui和xray是否在正常运行,如果没有运行则重新启动x-ui。
以下代码供参考:
#!/bin/bash
ps -aux | grep -v grep | grep -q x-ui || systemctl restart x-ui.service
ps -aux | grep -v grep | grep -q xray || systemctl restart x-ui.service

谢谢!

谢谢分享1.8.1

x-ui命令报错

(base) ➜ ~ x-ui
/usr/bin/x-ui: 12: eval: [[: not found
/usr/bin/x-ui: 13: eval: [[: not found
/usr/bin/x-ui: 302: eval: Syntax error: "(" unexpected

已测试多台服务器。系统是ubuntu 18.04和20.04。

另外请问能否加入手动重选一次warp ip的功能 \doge

acme.sh增加CF的自定义令牌

你在视频中有提到可以配置自定义令牌,一键部署acme.sh时如果可以增加一个选择项:通过"Authorization: Bearer "申请会更加加方便一点。谢谢大佬的付出。

请求添加自定义出站节点功能

我有大陆的服务器,需要搭建中转跳板机,但我小白一个,改写的xui配置文件总不通,希望勇哥能在一键脚本中添加此项功能。

请问能不能制作docker版本

如题,请问能不能制作docker版本,部署更加方便,本来想帮忙制作docker版本,但由于闭源,所以在这里问一下能不能帮忙制作一下docker版本

甬哥求解

我买了台上海的服务器,安装之后为什么可以正常连接,但是却不能正常访问网络

甬哥求解

求助:Debian10安装不了socat导致证书签发失败

根据涌哥油管上那个使用Debian10的vps搭建vless节点的教程一步一步进行,发现socat安装不成功
报错1

然后在x-ui里申请证书失败了。先报了一个红色的警告,然后显示证书申请失败,脚本退出。
报错2

报错3

麻烦大佬帮忙看看怎么解决?谢谢🙏

实现多路inbound和outbound,出入协议不相同 是配置问题还是Xray不支持

请教问题如图
目的:实现多路inbound和outbound,in使用vmess与out使用socks5,出入协议不相同,现在配置并不生效;想知道是配置文件写错了还是代理不能转协议?
还不太会看log,如果能分享如何查看分析log日志也可以

{
  "log": null,
  "routing": {
    "domainStrategy": "AsIs",
    "rules": [
      {
        "inboundTag": [
          "api"
        ],
        "outboundTag": "api",
        "type": "field"
      },
      {
        "type": "field",
        "port": "443",
        "network": "udp",
        "outboundTag": "blocked"
      },
      {
        "type": "field",
        "domain": [
          "domain:gstatic.com"
        ],
        "outboundTag": "direct"
      },
      {
        "ip": [
          "geoip:private"
        ],
        "outboundTag": "blocked",
        "type": "field"
      },
      {
        "outboundTag": "blocked",
        "protocol": [
          "bittorrent"
        ],
        "type": "field"
      },
      {
        "type": "field",
        "outboundTag": "xray-wg-warp-v4",
        "domain": [
          "yg kkk"
        ]
      },
      {
        "type": "field",
        "outboundTag": "xray-wg-warp-v6",
        "domain": [
          "geosite:openai"
        ]
      },
      {
        "type": "field",
        "outboundTag": "socks5-warp-v4",
        "domain": [
          "yg kkk"
        ]
      },
      {
        "type": "field",
        "outboundTag": "socks5-warp-v6",
        "domain": [
          "yg kkk"
        ]
      },
      {
        "type": "field",
        "outboundTag": "vps-outbound-v4",
        "domain": [
          "yg kkk"
        ]
      },
      {
        "type": "field",
        "outboundTag": "vps-outbound-v6",
        "domain": [
          "yg kkk"
        ]
      },
      {
        "type": "field",
        "outboundTag": "direct",
        "network": "udp,tcp"
      },
      {
        "type": "field",
        "inboundTag": "inbound-42110",
        "outboundTag": "zhuzai01"
      },
      {
        "type": "field",
        "inboundTag": "inbound-31991",
        "outboundTag": "zhuzai02"
      }
    ]
  },
  "dns": {
    "hosts": {
      "geo site:netflix": "205.189.160.212"
    },
    "servers": [
      "8.8.8.8",
      "1.1.1.1"
    ]
  },
  "inbounds": [
    {
      "listen": "127.0.0.1",
      "port": 62789,
      "protocol": "dokodemo-door",
      "settings": {
        "address": "127.0.0.1"
      },
      "streamSettings": null,
      "tag": "api",
      "sniffing": null
    },
    {
      "listen": null,
      "port": 42110,
      "protocol": "vmess",
      "settings": {
        "clients": [
          {
            "id": "56f8a76a-beed-4dd3-daf2-3f70482f863d",
            "alterId": 0
          }
        ],
        "disableInsecureEncryption": false
      },
      "streamSettings": {
        "network": "tcp",
        "security": "none",
        "tcpSettings": {
          "acceptProxyProtocol": false,
          "header": {
            "type": "none"
          }
        }
      },
      "tag": "inbound-42110",
      "sniffing": {
        "enabled": true,
        "destOverride": [
          "http",
          "tls",
          "quic"
        ]
      }
    },
    {
      "listen": null,
      "port": 31991,
      "protocol": "vmess",
      "settings": {
        "clients": [
          {
            "id": "0ef3d4e6-fdb1-4d62-d2da-c3d28427cc6e",
            "alterId": 0
          }
        ],
        "disableInsecureEncryption": false
      },
      "streamSettings": {
        "network": "tcp",
        "security": "none",
        "tcpSettings": {
          "acceptProxyProtocol": false,
          "header": {
            "type": "none"
          }
        }
      },
      "tag": "inbound-31991",
      "sniffing": {
        "enabled": true,
        "destOverride": [
          "http",
          "tls",
          "quic"
        ]
      }
    },
    {
      "listen": null,
      "port": 20058,
      "protocol": "socks",
      "settings": {
        "auth": "password",
        "accounts": [
          {
            "user": "xZilZvqjI5",
            "pass": "QUxupJasL4"
          }
        ],
        "udp": false,
        "ip": "127.0.0.1"
      },
      "streamSettings": {
        "network": "tcp",
        "security": "none",
        "tcpSettings": {
          "acceptProxyProtocol": false,
          "header": {
            "type": "none"
          }
        }
      },
      "tag": "inbound-20058",
      "sniffing": {}
    }
  ],
  "outbounds": [
    {
      "protocol": "blackhole",
      "tag": "blocked"
    },
    {
      "tag": "direct",
      "protocol": "freedom",
      "settings": {}
    },
    {
      "tag": "vps-outbound-v4",
      "protocol": "freedom",
      "settings": {
        "domainStrategy": "UseIPv4"
      }
    },
    {
      "tag": "vps-outbound-v6",
      "protocol": "freedom",
      "settings": {
        "domainStrategy": "UseIPv6"
      }
    },
    {
      "tag": "socks5-warp",
      "protocol": "socks",
      "settings": {
        "servers": [
          {
            "address": "127.0.0.1",
            "port": 40000
          }
        ]
      }
    },
    {
      "tag": "socks5-warp-v4",
      "protocol": "freedom",
      "settings": {
        "domainStrategy": "UseIPv4"
      },
      "proxySettings": {
        "tag": "socks5-warp"
      }
    },
    {
      "tag": "socks5-warp-v6",
      "protocol": "freedom",
      "settings": {
        "domainStrategy": "UseIPv6"
      },
      "proxySettings": {
        "tag": "socks5-warp"
      }
    },
    {
      "tag": "xray-wg-warp",
      "protocol": "wireguard",
      "settings": {
        "secretKey": "aJkrp4MMgL/Oi2bO4Fww9J8aqAW1ojeOZ22RK0nXYWY=",
        "address": [
          "172.16.0.2/32",
          "2606:4700:110:891c:6ee2:7df4:5e99:b7cf/128"
        ],
        "peers": [
          {
            "publicKey": "bmXOC+F1FxEMF9dyiK2H5/1SUtzH0JuVo51h2wPfgyo=",
            "allowedIPs": [
              "0.0.0.0/0",
              "::/0"
            ],
            "endpoint": "162.159.193.10:1701"
          }
        ],
        "reserved": [
          230,
          25,
          169
        ]
      }
    },
    {
      "tag": "xray-wg-warp-v4",
      "protocol": "freedom",
      "settings": {
        "domainStrategy": "UseIPv4"
      },
      "proxySettings": {
        "tag": "xray-wg-warp"
      }
    },
    {
      "tag": "xray-wg-warp-v6",
      "protocol": "freedom",
      "settings": {
        "domainStrategy": "UseIPv6"
      },
      "proxySettings": {
        "tag": "xray-wg-warp"
      }
    },
    {
      "tag": "zhuzai01",
      "protocol": "socks",
      "sendThrough": "8.8.8.8", // example
      "settings": {
        "domainStrategy": "UseIP",
        "servers": [
          {
            "address": "8.8.8.8", // example
            "port": 21,
            "users": [
              {
                "user": "user",
                "pass": "pass"
              }
            ]
          }
        ]
      }
    },
    {
      "tag": "zhuzai02",
      "protocol": "socks",
      "sendThrough": "8.8.8.8", // example
      "settings": {
        "domainStrategy": "UseIPv4",
        "servers": [
          {
            "address": "8.8.8.8", // example
            "port": 21,
            "users": [
              {
                "user": "user",
                "pass": "pass"
              }
            ]
          }
        ]
      }
    }
  ],
  "transport": null,
  "policy": {
    "system": {
      "statsInboundDownlink": true,
      "statsInboundUplink": true
    },
    "levels": {
      "0": {
        "handshake": 10,
        "connIdle": 100,
        "uplinkOnly": 2,
        "downlinkOnly": 3,
        "bufferSize": 10240
      }
    }
  },
  "api": {
    "services": [
      "HandlerService",
      "LoggerService",
      "StatsService"
    ],
    "tag": "api"
  },
  "stats": {},
  "reverse": null,
  "fakeDns": null

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.