Add files via upload

This commit is contained in:
公明
2026-07-20 10:48:28 +08:00
committed by GitHub
parent b7f9fa6173
commit cb0d61a48d
4 changed files with 23 additions and 10 deletions
+7 -3
View File
@@ -348,7 +348,7 @@ need_rebuild() {
}
# Main flow
# Default: HTTPS (--https passed to binary); --http uses plain HTTP.
# Default: HTTPS (--https passed to binary); --http forces plain HTTP even if config.yaml enables TLS.
main() {
USE_HTTPS=1
FORWARD_ARGS=()
@@ -357,6 +357,10 @@ main() {
USE_HTTPS=0
continue
fi
if [ "$arg" = "--https" ]; then
USE_HTTPS=1
continue
fi
FORWARD_ARGS+=("$arg")
done
@@ -406,9 +410,9 @@ main() {
fi
else
if [ "${#FORWARD_ARGS[@]}" -gt 0 ]; then
exec "./$BINARY_NAME" -config "$CONFIG_FILE" "${FORWARD_ARGS[@]}"
exec "./$BINARY_NAME" -config "$CONFIG_FILE" --http "${FORWARD_ARGS[@]}"
else
exec "./$BINARY_NAME" -config "$CONFIG_FILE"
exec "./$BINARY_NAME" -config "$CONFIG_FILE" --http
fi
fi
}