mirror of
https://github.com/samuelhbne/server-xray.git
synced 2025-12-16 20:07:06 +03:00
Initial REALITY support
This commit is contained in:
@@ -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'
|
||||
|
||||
|
||||
@@ -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
2
run.sh
@@ -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"
|
||||
|
||||
@@ -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
|
||||
|
||||
|
||||
@@ -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
|
||||
|
||||
|
||||
Reference in New Issue
Block a user