Initial REALITY support

This commit is contained in:
Samuel Huang
2024-09-10 21:42:36 +10:00
parent 4d53046fca
commit 89cce5715f
5 changed files with 5 additions and 5 deletions

View File

@@ -1,4 +1,4 @@
FROM golang:1.22-alpine3.20 AS builder
FROM golang:1.23-alpine3.20 AS builder
ARG XRAYVER='v1.8.24'

View File

@@ -52,7 +52,7 @@ psw="${uopt[0]}"
level="${uopt[1]}"
email="${uopt[2]}"
if [ -z "${uid}" ]; then
if [ -z "${psw}" ]; then
echo "Error: Undefined UID \"$user\"" >&2
echo "Correct user format: user=<password>[:level:email]" >&2
echo "Like: user=mypw:0:me@g.cn" >&2

2
run.sh
View File

@@ -181,7 +181,7 @@ if [ -n "${SVCMD}" ]; then
fi
if [ -n "${NGOPT}" ]; then
ngcmd="${DIR}server-nginx.sh"
ngcmd="${DIR}/server-nginx.sh"
for ngopt in "${NGOPT[@]}"
do
ngcmd="${ngcmd} --ng-opt ${ngopt},$xopt"

View File

@@ -68,7 +68,7 @@ do
done
# Network settings
cat $XCONF |jq --arg port "${port}" \
cat $XCONF |jq --arg port "${port}" --arg webpath "${webpath}" \
'( .inbounds[] | select(.port == ($port|tonumber)) | .streamSettings ) += {"network":"splithttp","splithttpSettings":{"path":$webpath}} ' \
|sponge $XCONF

View File

@@ -116,7 +116,7 @@ do
done
# Network settings
cat $XCONF |jq --arg port "${port}" \
cat $XCONF |jq --arg port "${port}" --arg webpath "${webpath}" \
'( .inbounds[] | select(.port == ($port|tonumber)) | .streamSettings ) += {"network":"splithttp","splithttpSettings":{"path":$webpath}} ' \
|sponge $XCONF