Подготовить HY2XS к production-сборке

This commit is contained in:
2026-04-25 23:13:12 +05:00
commit 84a4e94567
277 changed files with 26513 additions and 0 deletions
+38
View File
@@ -0,0 +1,38 @@
# HY2XS post-install reference file.
# Файл создаётся оркестратором после первичной установки и не является runtime-конфигом.
DEPLOY_TARGET_OS=debian12
DEPLOY_TIMESTAMP={{INSTALL_DATE}}
PACKAGE_NAME=hy2xs-install-package
PACKAGE_BUILD_ID={{PACKAGE_BUILD_ID}}
PACKAGE_VERSION={{PACKAGE_VERSION}}
ORCH_SOURCE_STACK=bun-typescript
ORCH_BUILD_MODE=bun-compile
ORCH_BUILD_ID={{PACKAGE_BUILD_ID}}
ORCH_ENTRYPOINT=/usr/local/lib/hy2xs/hy2xs-orchestrator
DEPLOY_DOMAIN={{DOMAIN}}
SSH_PORT={{SSH_PORT}}
HY2_SOURCE=official-upstream
HY2_VERSION={{HYSTERIA_VERSION}}
HY2_LISTEN_HOST=0.0.0.0
HY2_PORT={{HYSTERIA_PORT}}
HY2_AUTH_MODE=http
HY2_AUTH_URL=http://127.0.0.1:{{UI_PORT}}/hui/hysteria2/auth
HY2_TRAFFIC_STATS_LISTEN=127.0.0.1:{{HYSTERIA_API_PORT}}
HY2_OBFS_TYPE=salamander
HY2_OBFS_PASSWORD={{HYSTERIA_OBFS_PASSWORD}}
HY2_BANDWIDTH_UP_Mbps=50
HY2_BANDWIDTH_DOWN_Mbps=50
HY2_IGNORE_CLIENT_BANDWIDTH=false
HY2_CONFIG_PATH=/etc/hysteria/config.yaml
HUI_ENABLED=true
HUI_FORK_REF=packaged
HUI_BUILD_ID={{PACKAGE_BUILD_ID}}
HUI_BIND_HOST={{UI_BIND_HOST}}
HUI_PORT={{UI_PORT}}
HUI_INSTALL_DIR=/opt/hy2xs-admin
HUI_DATA_DIR=/var/lib/hy2xs-admin
@@ -0,0 +1,30 @@
listen: :{{HYSTERIA_PORT}}
tls:
cert: /etc/hysteria/server.crt
key: /etc/hysteria/server.key
auth:
type: http
http:
url: http://127.0.0.1:{{UI_PORT}}/hui/hysteria2/auth
insecure: true
obfs:
type: salamander
salamander:
password: "{{HYSTERIA_OBFS_PASSWORD}}"
bandwidth:
up: "{{BANDWIDTH_UP}}"
down: "{{BANDWIDTH_DOWN}}"
trafficStats:
listen: 127.0.0.1:{{HYSTERIA_API_PORT}}
secret: "{{HYSTERIA_API_SECRET}}"
quic:
initStreamReceiveWindow: 8388608
maxStreamReceiveWindow: 8388608
initConnReceiveWindow: 20971520
maxConnReceiveWindow: 20971520
+14
View File
@@ -0,0 +1,14 @@
table inet hy2xs {
chain input {
type filter hook input priority 0; policy drop;
iif lo accept
ct state established,related accept
tcp dport {{SSH_PORT}} accept
udp dport {{HYSTERIA_PORT}} accept
tcp dport {{UI_PORT}} ip saddr 127.0.0.1 accept
icmp type echo-request accept
ip6 nexthdr ipv6-icmp accept
ip protocol icmp accept
}
}