chore: point install/update/self-update at this fork instead of upstream

install.sh, update.sh, and x-ui.sh all hardcoded MHSanaei/3x-ui as the
release/raw-file source (release tarball downloads, the self-update
script fetch, service unit fallback downloads). Left as-is, merging
AmneziaWG into main and cutting a release here would still silently
install upstream's stock binary — none of our work would ever reach a
machine that runs the curl-from-GitHub one-liner.

Repointed all of it at Kuzz007/3x-ui, plus two more functional (not
just doc/attribution) spots the same grep turned up: the panel's own
in-app update checker (internal/web/service/panel/panel.go's
panelUpdaterURL and the GitHub releases API calls in
fetchPanelRelease) and deploy/cloud-init/cloud-init.yaml's
auto-provisioning curl line. Left README/docs/CONTRIBUTING/FUNDING
attribution to the upstream project untouched — this is still a fork
of MHSanaei's work, that credit stays.

Third-party dependency downloads in .github/workflows/release.yml
(Xray-core, geoip/geosite data, mtg-multi) intentionally still point
at their own respective upstream projects, not this fork.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
Kuzz007
2026-07-25 02:23:26 +03:00
parent d3db90c8f1
commit 12b002b090
5 changed files with 24 additions and 24 deletions
+1 -1
View File
@@ -44,7 +44,7 @@ write_files:
# export XUI_DB_DSN="postgres://user:pass@host:5432/db?sslmode=disable"
# ------------------------------------------------------------------------
curl -fsSL https://raw.githubusercontent.com/MHSanaei/3x-ui/main/install.sh | bash
curl -fsSL https://raw.githubusercontent.com/Kuzz007/3x-ui/main/install.sh | bash
# Surface the generated credentials. Full creds (incl. password + API token)
# go ONLY to the serial console (/dev/console, owner-only). /etc/motd is
+8 -8
View File
@@ -1418,13 +1418,13 @@ install_x-ui() {
# Download resources
if [ $# == 0 ]; then
tag_version=$(curl -Ls --retry 5 --retry-delay 3 --connect-timeout 15 --max-time 60 "https://api.github.com/repos/MHSanaei/3x-ui/releases/latest" | grep '"tag_name":' | sed -E 's/.*"([^"]+)".*/\1/')
tag_version=$(curl -Ls --retry 5 --retry-delay 3 --connect-timeout 15 --max-time 60 "https://api.github.com/repos/Kuzz007/3x-ui/releases/latest" | grep '"tag_name":' | sed -E 's/.*"([^"]+)".*/\1/')
if [[ ! -n "$tag_version" ]]; then
echo -e "${red}Failed to fetch x-ui version, it may be due to GitHub API restrictions, please try it later${plain}"
exit 1
fi
echo -e "Got x-ui latest version: ${tag_version}, beginning the installation..."
curl -fLR --retry 5 --retry-delay 3 --connect-timeout 15 --speed-limit 1 --speed-time 300 -o ${xui_folder}-linux-$(arch).tar.gz https://github.com/MHSanaei/3x-ui/releases/download/${tag_version}/x-ui-linux-$(arch).tar.gz
curl -fLR --retry 5 --retry-delay 3 --connect-timeout 15 --speed-limit 1 --speed-time 300 -o ${xui_folder}-linux-$(arch).tar.gz https://github.com/Kuzz007/3x-ui/releases/download/${tag_version}/x-ui-linux-$(arch).tar.gz
if [[ $? -ne 0 ]]; then
echo -e "${red}Downloading x-ui failed, please be sure that your server can access GitHub ${plain}"
exit 1
@@ -1452,7 +1452,7 @@ install_x-ui() {
fi
fi
url="https://github.com/MHSanaei/3x-ui/releases/download/${tag_version}/x-ui-linux-$(arch).tar.gz"
url="https://github.com/Kuzz007/3x-ui/releases/download/${tag_version}/x-ui-linux-$(arch).tar.gz"
echo -e "Beginning to install x-ui ${tag_version}"
curl -fLR --retry 5 --retry-delay 3 --connect-timeout 15 --speed-limit 1 --speed-time 300 -o ${xui_folder}-linux-$(arch).tar.gz ${url}
if [[ $? -ne 0 ]]; then
@@ -1467,7 +1467,7 @@ install_x-ui() {
fi
local xui_script_temp="/usr/bin/x-ui-temp.$$"
rm -f "${xui_script_temp}"
curl -fLRo "${xui_script_temp}" https://raw.githubusercontent.com/MHSanaei/3x-ui/main/x-ui.sh
curl -fLRo "${xui_script_temp}" https://raw.githubusercontent.com/Kuzz007/3x-ui/main/x-ui.sh
if [[ $? -ne 0 ]]; then
rm -f "${xui_script_temp}"
echo -e "${red}Failed to download x-ui.sh${plain}"
@@ -1559,7 +1559,7 @@ install_x-ui() {
if [[ $release == "alpine" ]]; then
xui_rc_temp="/etc/init.d/x-ui.tmp.$$"
rm -f "${xui_rc_temp}"
curl -fLRo "${xui_rc_temp}" https://raw.githubusercontent.com/MHSanaei/3x-ui/main/x-ui.rc
curl -fLRo "${xui_rc_temp}" https://raw.githubusercontent.com/Kuzz007/3x-ui/main/x-ui.rc
if [[ $? -ne 0 ]]; then
rm -f "${xui_rc_temp}"
echo -e "${red}Failed to download x-ui.rc${plain}"
@@ -1624,13 +1624,13 @@ install_x-ui() {
echo -e "${yellow}Service files not found in tar.gz, downloading from GitHub...${plain}"
case "${release}" in
ubuntu | debian | armbian)
service_unit_url="https://raw.githubusercontent.com/MHSanaei/3x-ui/main/x-ui.service.debian"
service_unit_url="https://raw.githubusercontent.com/Kuzz007/3x-ui/main/x-ui.service.debian"
;;
arch | manjaro | parch)
service_unit_url="https://raw.githubusercontent.com/MHSanaei/3x-ui/main/x-ui.service.arch"
service_unit_url="https://raw.githubusercontent.com/Kuzz007/3x-ui/main/x-ui.service.arch"
;;
*)
service_unit_url="https://raw.githubusercontent.com/MHSanaei/3x-ui/main/x-ui.service.rhel"
service_unit_url="https://raw.githubusercontent.com/Kuzz007/3x-ui/main/x-ui.service.rhel"
;;
esac
+3 -3
View File
@@ -40,7 +40,7 @@ type PanelUpdateInfo struct {
}
const (
panelUpdaterURL = "https://raw.githubusercontent.com/MHSanaei/3x-ui/main/update.sh"
panelUpdaterURL = "https://raw.githubusercontent.com/Kuzz007/3x-ui/main/update.sh"
maxPanelUpdaterBytes = 2 << 20
// devReleaseTag is the fixed-tag rolling pre-release the CI force-moves to the
// newest main commit; the dev update channel installs from it.
@@ -413,9 +413,9 @@ func fetchLatestPanelVersion() (string, error) {
// fetchPanelRelease fetches a release from GitHub. An empty tag resolves the
// latest stable release; a non-empty tag (e.g. dev-latest) resolves that tag.
func fetchPanelRelease(tag string) (*service.Release, error) {
url := "https://api.github.com/repos/MHSanaei/3x-ui/releases/latest"
url := "https://api.github.com/repos/Kuzz007/3x-ui/releases/latest"
if tag != "" {
url = "https://api.github.com/repos/MHSanaei/3x-ui/releases/tags/" + tag
url = "https://api.github.com/repos/Kuzz007/3x-ui/releases/tags/" + tag
}
client := (&service.SettingService{}).NewProxiedHTTPClient(10 * time.Second)
req, reqErr := http.NewRequestWithContext(context.Background(), http.MethodGet, url, nil)
+7 -7
View File
@@ -987,13 +987,13 @@ update_x-ui() {
tag_version="${XUI_UPDATE_TAG}"
echo -e "${green}Using update tag: ${tag_version}${plain}"
else
tag_version=$(${curl_bin} -Ls "https://api.github.com/repos/MHSanaei/3x-ui/releases/latest" 2> /dev/null | grep '"tag_name":' | sed -E 's/.*"([^"]+)".*/\1/')
tag_version=$(${curl_bin} -Ls "https://api.github.com/repos/Kuzz007/3x-ui/releases/latest" 2> /dev/null | grep '"tag_name":' | sed -E 's/.*"([^"]+)".*/\1/')
if [[ ! -n "$tag_version" ]]; then
_fail "ERROR: Failed to fetch x-ui version, it may be due to GitHub API restrictions, please try it later"
fi
fi
echo -e "Got x-ui latest version: ${tag_version}, beginning the installation..."
${curl_bin} -fLRo ${xui_folder}-linux-$(arch).tar.gz https://github.com/MHSanaei/3x-ui/releases/download/${tag_version}/x-ui-linux-$(arch).tar.gz 2> /dev/null
${curl_bin} -fLRo ${xui_folder}-linux-$(arch).tar.gz https://github.com/Kuzz007/3x-ui/releases/download/${tag_version}/x-ui-linux-$(arch).tar.gz 2> /dev/null
if [[ $? -ne 0 ]]; then
_fail "ERROR: Failed to download x-ui, please be sure that your server can access GitHub"
fi
@@ -1086,7 +1086,7 @@ update_x-ui() {
echo -e "${green}Downloading and installing x-ui.sh script...${plain}"
local xui_script_temp="/usr/bin/x-ui-temp.$$"
rm -f "${xui_script_temp}"
${curl_bin} -fLRo "${xui_script_temp}" https://raw.githubusercontent.com/MHSanaei/3x-ui/main/x-ui.sh > /dev/null 2>&1
${curl_bin} -fLRo "${xui_script_temp}" https://raw.githubusercontent.com/Kuzz007/3x-ui/main/x-ui.sh > /dev/null 2>&1
if [[ $? -ne 0 ]]; then
rm -f "${xui_script_temp}"
_fail "ERROR: Failed to download x-ui.sh script, please be sure that your server can access GitHub"
@@ -1117,7 +1117,7 @@ update_x-ui() {
echo -e "${green}Downloading and installing startup unit x-ui.rc...${plain}"
xui_rc_temp="/etc/init.d/x-ui.tmp.$$"
rm -f "${xui_rc_temp}"
${curl_bin} -fLRo "${xui_rc_temp}" https://raw.githubusercontent.com/MHSanaei/3x-ui/main/x-ui.rc > /dev/null 2>&1
${curl_bin} -fLRo "${xui_rc_temp}" https://raw.githubusercontent.com/Kuzz007/3x-ui/main/x-ui.rc > /dev/null 2>&1
if [[ $? -ne 0 ]]; then
rm -f "${xui_rc_temp}"
_fail "ERROR: Failed to download startup unit x-ui.rc, please be sure that your server can access GitHub"
@@ -1176,13 +1176,13 @@ update_x-ui() {
echo -e "${yellow}Service files not found in tar.gz, downloading from GitHub...${plain}"
case "${release}" in
ubuntu | debian | armbian)
service_unit_url="https://raw.githubusercontent.com/MHSanaei/3x-ui/main/x-ui.service.debian"
service_unit_url="https://raw.githubusercontent.com/Kuzz007/3x-ui/main/x-ui.service.debian"
;;
arch | manjaro | parch)
service_unit_url="https://raw.githubusercontent.com/MHSanaei/3x-ui/main/x-ui.service.arch"
service_unit_url="https://raw.githubusercontent.com/Kuzz007/3x-ui/main/x-ui.service.arch"
;;
*)
service_unit_url="https://raw.githubusercontent.com/MHSanaei/3x-ui/main/x-ui.service.rhel"
service_unit_url="https://raw.githubusercontent.com/Kuzz007/3x-ui/main/x-ui.service.rhel"
;;
esac
+5 -5
View File
@@ -129,7 +129,7 @@ before_show_menu() {
}
install() {
bash <(curl -Ls https://raw.githubusercontent.com/MHSanaei/3x-ui/main/install.sh)
bash <(curl -Ls https://raw.githubusercontent.com/Kuzz007/3x-ui/main/install.sh)
if [[ $? == 0 ]]; then
if [[ $# == 0 ]]; then
start
@@ -148,7 +148,7 @@ update() {
fi
return 0
fi
bash <(curl -Ls https://raw.githubusercontent.com/MHSanaei/3x-ui/main/update.sh)
bash <(curl -Ls https://raw.githubusercontent.com/Kuzz007/3x-ui/main/update.sh)
if [[ $? == 0 ]]; then
LOGI "Update is complete, Panel has automatically restarted "
before_show_menu
@@ -166,7 +166,7 @@ update_dev() {
fi
# XUI_UPDATE_TAG tells update.sh to install the dev-latest pre-release
# instead of the latest stable tag.
XUI_UPDATE_TAG="dev-latest" bash <(curl -Ls https://raw.githubusercontent.com/MHSanaei/3x-ui/main/update.sh)
XUI_UPDATE_TAG="dev-latest" bash <(curl -Ls https://raw.githubusercontent.com/Kuzz007/3x-ui/main/update.sh)
if [[ $? == 0 ]]; then
LOGI "Dev update is complete, Panel has automatically restarted "
before_show_menu
@@ -219,7 +219,7 @@ update_menu() {
return 0
fi
if replace_xui_script "https://raw.githubusercontent.com/MHSanaei/3x-ui/main/x-ui.sh" "false"; then
if replace_xui_script "https://raw.githubusercontent.com/Kuzz007/3x-ui/main/x-ui.sh" "false"; then
chmod +x ${xui_folder}/x-ui.sh
echo -e "${green}Update successful. The panel has automatically restarted.${plain}"
exit 0
@@ -836,7 +836,7 @@ enable_bbr() {
}
update_shell() {
if replace_xui_script "https://github.com/MHSanaei/3x-ui/raw/main/x-ui.sh" "true"; then
if replace_xui_script "https://github.com/Kuzz007/3x-ui/raw/main/x-ui.sh" "true"; then
LOGI "Upgrade script succeeded, Please rerun the script"
before_show_menu
else