🚀 Everything moved to https://github.com/deposist/s-ui-x 🚀
Advanced Web panel built on SagerNet/Sing-Box.
Note: the original alireza0/s-ui project was blocked and removed by GitHub. This repository is a complete backup based on the last original version, v1.4.1, with security and reliability hardening applied on top (current build: v1.5.3-beta).
This fork keeps the original project structure and updates the user-facing documentation and installation links for this repository. You can use the scripts from this repository directly, or fork and build the project yourself.
Disclaimer: this project is intended only for personal learning and knowledge sharing. Do not use it for illegal purposes.
The full per-release notes live in the language-specific changelog files:
- English:
CHANGELOG-EN.md - Русский:
CHANGELOG-RU.md - 简体中文:
CHANGELOG-ZH.md
Short summary of recent versions:
| Version | One-line summary |
|---|---|
1.5.3-beta |
Code review remediation aggregate (P0/P1/P2/P3 + P4/P5 architecture and logging cleanup) plus upstream parity bug fix for alireza0/s-ui#1114: TUIC subscription/share links and Clash export now include udp_relay_mode (default quic when absent). Logging fully migrated to slog, deprecated op/go-logging dependency removed, restart manager unified, listen-address fallback audited, and globals reduced via initial DI slice. |
1.5.2-beta-hotfix2 |
Drops the legacy idx_client_ips_client_ip unique index on (client_name, ip). The 3x-ui pre-import auto-backup no longer crashes with UNIQUE constraint failed: client_ips.client_name, client_ips.ip when a client owns multiple client_ips rows with empty legacy ip. to1_5 is idempotent and runs again on already-upgraded panels; ensureIndexes drops the obsolete index at every InitDB so the temporary backup DB stops carrying it too. |
1.5.2-beta-hotfix |
Backup chunking and SPA upgrade safety: database/bulk.go keeps every backup INSERT under SQLite's variable budget, fixing too many SQL variables on installs with large stats/client_ips/clients/changes tables and unblocking the 3x-ui pre-import auto-backup. web/web.go returns 404 for missing /<base>/assets/* instead of HTML, index.html is no-cache, and vite:preloadError triggers one guarded reload so the Clients tab stops breaking after upgrades. |
1.5.2-beta |
3x-ui migration suite: s-ui import-xui CLI, POST /api/import-xui HTTP API, "Migrate from 3x-ui" section in Backup & Restore, full wizard at /migrate-xui (plan/apply/rollback, WS progress, JSON/Markdown report), remote SSH and xuihttp sources, xuiSyncJob cron with encrypted xui_sync_profiles, /migrate-xui/schedule UI, best-effort historical traffic and Xray routing rules import, new xui_remote token scope. |
1.5.1-beta |
Remediation hardening: async Telegram queue, redacted payloads, hardened realtime WS handshake, scoped audit endpoint, hashed/retained client IPs, Telegram proxy egress with normalized error classes, bucketed observability, frontend completion. |
1.5.0 |
Security foundation and realtime platform: secretbox for sensitive settings, audit_events + /api/security/audit, CSRF for browser API, hashed/scoped API tokens, Bearer auth (legacy Token header deprecated), per-client subscription secrets, /api/realtime/ws*, IP monitor (monitor-only by default). |
1.4.3 |
sing-box runtime update from v1.13.4 to v1.13.11. No DB or UI changes. |
1.4.2-beta |
Security and reliability hardening: bcrypt password storage with lazy migration, login rate limiter, hardened cookies, SSRF-resistant subscription fetcher, parameterized SQL, race-free runtime, automatic legacy backup adaptation, bilingual installer. Module renamed to github.com/deposist/s-ui-rus-inst. |
For full changes, breaking notes, upgrade guide, and rollback steps, open the changelog in your preferred language.
Show details
This fork is binary-compatible with alireza0/s-ui — drop the new
binary on top of an existing 1.x install, the panel migrates the DB
automatically on first start. The intent is to harden security and
reliability without changing the protocol surface.
- Auth and session security. bcrypt with lazy migration, randomly generated first-run password (logged once), login rate limiter,
HttpOnly+SameSite=Lax+ HTTPS-awareSecurecookies. Sensitive settings (Telegram bot token, proxy credentials, install salt) are encrypted at rest via secretbox; API tokens are stored as salted SHA-256 hashes. CSRF protection is enforced on browser/api/*mutating requests. - API token scopes.
admin,read,write, andobservabilityscopes are documented indocs/scope-matrix.md, including audit, database, Telegram, subscription-secret rotation, observability, and realtime security-event behavior. X-Forwarded-Forhandling. Header is ignored unlessSUI_TRUSTED_PROXIESis configured; the chain is walked right-to-left so spoofed XFF cannot reach IP-based logic.- External subscription fetcher. URL allow-list, blocks private/loopback targets by default (opt-in via
SUI_ALLOW_PRIVATE_SUB_URLS=true), 4 MiB response cap, DNS-rebinding-safe dial-time IP re-validation.Authorization: Bearer <token>is the primary API token transport on/apiv2/*; the legacyTokenheader still works withDeprecationandSunsetheaders untilSat, 15 Aug 2026 00:00:00 GMT. - Realtime WebSocket.
/api/realtime/ws-token+/api/realtime/wsenforce Origin allow-listing, per-IP handshake rate limits, single-use tokens, ping/pong heartbeat, idle close, and close-all on session rotation. Frontend has a polling fallback for degraded states. - Per-client subscription secrets.
/sub/<secret>,/sub/json/<secret>,/sub/clash/<secret>,/json/<secret>,/clash/<secret>are supported; legacy/sub/<name>keeps working untilsubSecretRequired=true. Subscription endpoints sanitize response headers and apply a configurable per-IP rate limit. - Telegram notifications (off by default). Async bounded queue with retry/backoff and audited overflow/failure events. Egress can use validated HTTP/HTTPS/SOCKS5 proxy settings. Telegram payloads, audit details, change history, and backup captions are redacted.
- Audit and observability.
audit_eventstable with retention GC, scopedGET /api/security/auditendpoint with rate limiting and cursor pagination. Bounded observability buckets (2s,30s,1m,5m) sampled by cron. Bounded logs API and fail-soft 1h-cachedGET /api/version. - IP monitor (monitor-only by default). Salted hashes, opt-in raw display, retention GC, per-client
limitIpandipLimitMode. Enforce mode rejects only new over-limit connections and never closes active connections. - SQL safety. Parameterized queries throughout
service/config.goandservice/inbounds.go; static allow-list of inbound types in the user-fetch SQL builder. - Backup import / upgrade.
ImportDBenforces a 64 MiB cap, SQLite magic check, temporary staging, read-onlyPRAGMA integrity_check, and audit events. WAL/SHM sidecars are cleaned, schema migrations +AdaptToCurrentVersionrun automatically (rehashes legacy plaintext passwords, refreshes indexes, bumpssettings.version); the previous DB is restored on any failure. - Listen-address resilience. When the saved
webListen/subListenIP no longer exists on the host, the panel logs a warning and binds on every interface instead of failing withEADDRNOTAVAIL. - Race-free runtime. Core lifecycle, online stats, last-update bookkeeping, v2 token store, realtime hub all pass
go test -race ./...(requires CGO). - HTTP server hardening.
Read/Write/Header/Idletimeouts andtls.MinVersion = 1.2on both the panel and the subscription endpoint. Security-headers middleware (CSP, HSTS when TLS, no-store on subscription responses). - WARP registration. Talks to the current Cloudflare WARP API (
v0a4005) with proper first-party headers, falls back tov0a2158, retries transient TLS handshake failures. - Frontend hygiene.
v-htmlremoved from logs, rule import errors, IP lists, and the gauge tile. Axios on an exported instance,AbortControllerinstead of deprecatedCancelToken, dedupe limited to idempotent reads, Vite code splitting on. Realtime WS store with reconnect/degraded states. Secret-aware settings fields with••• stored •••placeholder. IP history modal with raw-IP masking by default. Telegram settings and Audit views. - Localization & defaults. Multilingual
install.shands-uimanagement menu (English / Russian / Chinese), language switchable at runtime. DefaulttimeLocationisEurope/Moscow. Default frontend locale is English (existing browsers keep theirlocalStoragechoice).
| Feature | Support |
|---|---|
| Multiple protocols | ✔️ |
| Multiple languages | ✔️ |
| Multiple clients/inbounds | ✔️ |
| Advanced traffic routing interface | ✔️ |
| Client, traffic, and system status | ✔️ |
| Subscription links (link/json/clash + info) | ✔️ |
| Dark/light theme | ✔️ |
| API | ✔️ |
| Platform | Architecture | Status |
|---|---|---|
| Linux | amd64, arm64, armv7, armv6, armv5, 386, s390x | Supported |
| Windows | amd64, 386, arm64 | Supported |
| macOS | amd64, arm64 | Experimental support |
- Panel port: 2095
- Panel path: /app/
- Subscription port: 2096
- Subscription path: /sub/
- Subscription per-IP rate-limit changes (
subRateLimitPerIP) take effect within 1 minute after saving. - Username: admin
- Password (fresh install only): a random 24-character string is generated on first start and written to the application log. Look for the line
created initial admin user. username=admin password=...injournalctl -u s-ui(Linux) or in the panel log on first run. After that, change it from the panel.
bash <(curl -Ls https://raw.githubusercontent.com/deposist/s-ui-rus-inst/beta/install.sh)- Download the latest Windows version from GitHub Releases.
- Extract the ZIP file.
- Run
install-windows.batas Administrator. - Follow the installation wizard.
bash <(curl -Ls https://raw.githubusercontent.com/deposist/s-ui-rus-inst/beta/install.sh) v1.5.3-betaOr from a local clone:
git clone -b beta https://github.com/deposist/s-ui-rus-inst.git
cd s-ui-rus-inst
sudo bash install.sh v1.5.3-betaOr from a local clone:
git clone -b beta .git
cd s-ui-rus-inst
sudo bash install.sh v1.5.1-betaThe installer is fully compatible with existing installations: settings, inbounds, outbounds, clients, TLS, services and tokens are kept; the DB schema is migrated automatically on first start; plaintext admin passwords are upgraded to bcrypt on the next successful login. Full upgrade procedure and rollback notes — in the per-language changelog (EN · RU · 中文).
Append the version tag with v to the installation command. For example, version v1.0.0:
bash <(curl -Ls https://raw.githubusercontent.com/deposist/s-ui-rus-inst/beta/install.sh) v1.0.0- Download the latest S-UI version for your system and architecture from GitHub: https://github.com/deposist/s-ui-rus-inst/releases/latest
- Optional: download the latest
s-ui.sh: https://raw.githubusercontent.com/deposist/s-ui-rus-inst/main/s-ui.sh - Optional: copy
s-ui.shto/usr/bin/and runchmod +x /usr/bin/s-ui. - Extract the s-ui tar.gz archive to your chosen directory and enter the extracted folder.
- Copy the
*.servicefiles to/etc/systemd/system/, then runsystemctl daemon-reload. - Run
systemctl enable s-ui --nowto enable autostart and start the S-UI service. - Run
systemctl enable sing-box --nowto start the sing-box service.
- Download the latest Windows version from GitHub: https://github.com/deposist/s-ui-rus-inst/releases/latest
- Download the appropriate Windows package, for example
s-ui-windows-amd64.zip. - Extract the ZIP file to your chosen directory.
- Run
install-windows.batas Administrator. - Follow the installation wizard.
- Open the panel: http://localhost:2095/app
sudo -i
systemctl disable s-ui --now
rm -f /etc/systemd/system/sing-box.service
systemctl daemon-reload
rm -fr /usr/local/s-ui
rm /usr/bin/s-uiShow details
Step 1: install Docker
curl -fsSL https://get.docker.com | shStep 2: install S-UI
Docker Compose option
services:
s-ui:
image: ghcr.io/deposist/s-ui-rus-inst
container_name: s-ui
hostname: "s-ui"
network_mode: host
volumes:
- "./db:/app/db"
- "./cert:/app/cert"
tty: true
restart: unless-stopped
entrypoint: "./entrypoint.sh"docker compose up -d
Direct Docker run
mkdir s-ui && cd s-ui
docker run -itd \
--network host \
-v $PWD/db/:/app/db/ \
-v $PWD/cert/:/root/cert/ \
--name s-ui \
--restart=unless-stopped \
ghcr.io/deposist/s-ui-rus-instBuild the image yourself
git clone https://github.com/deposist/s-ui-rus-inst
docker build -t s-ui .Show details
./runSUI.sh# Clone the repository
git clone https://github.com/deposist/s-ui-rus-instThe frontend code is in the frontend directory.
Build the frontend at least once before building the backend.
Build the backend:
# Remove old frontend build files
rm -fr web/html/*
# Copy new frontend build files
cp -R frontend/dist/ web/html/
# Build
go build -o sui main.goRun the backend from the repository root:
./sui- English
- Persian
- Vietnamese
- Simplified Chinese
- Traditional Chinese
- Russian
- Supported protocols:
- General protocols: Mixed, SOCKS, HTTP, HTTPS, Direct, Redirect, TProxy
- V2Ray-based protocols: VLESS, VMess, Trojan, Shadowsocks
- Other protocols: ShadowTLS, Hysteria, Hysteria2, Naive, TUIC
- XTLS protocol support.
- Advanced traffic routing interface with PROXY Protocol, External, transparent proxy, SSL certificates, and port configuration support.
- Advanced inbound and outbound configuration interface.
- Client traffic limit and expiration support.
- Online clients, inbound/outbound traffic statistics, and system status monitoring.
- Subscription service supports external links and subscriptions.
- Web panel and subscription service support secure HTTPS access (you must provide your own domain and SSL certificate).
- Dark/light theme.
Show details
| Variable | Type | Default |
|---|---|---|
| SUI_LOG_LEVEL | "debug" | "info" | "warn" | "error" |
"info" |
| SUI_DEBUG | boolean |
false |
| SUI_BIN_FOLDER | string |
"bin" |
| SUI_DB_FOLDER | string |
"db" |
| SINGBOX_API | string |
- |
| SUI_TRUSTED_PROXIES | comma-separated CIDRs / IPs | - (XFF ignored) |
| SUI_ALLOW_PRIVATE_SUB_URLS | boolean |
false |
| SUI_SECRETBOX_KEY | string |
- (falls back to settings.secret) |
Show details
snap install core; snap refresh core
snap install --classic certbot
ln -s /snap/bin/certbot /usr/bin/certbot
certbot certonly --standalone --register-unsafely-without-email --non-interactive --agree-tos -d <your domain>Продвинутая Web-панель, построенная на базе SagerNet/Sing-Box.
Примечание: оригинальный проект alireza0/s-ui был заблокирован и удалён GitHub. Этот репозиторий — полная резервная копия последней оригинальной версии v1.4.1 с применённым набором исправлений по безопасности и надёжности (текущая сборка: v1.5.3-beta).
Этот fork сохраняет структуру оригинального проекта и обновляет пользовательскую документацию и ссылки установки для этого репозитория. Вы можете напрямую использовать скрипты из этого репозитория или сделать fork и собрать проект самостоятельно.
Отказ от ответственности: этот проект предназначен только для личного обучения и обмена опытом. Не используйте его в незаконных целях.
Полные release notes лежат в отдельных файлах changelog по языкам:
- English:
CHANGELOG-EN.md - Русский:
CHANGELOG-RU.md - 简体中文:
CHANGELOG-ZH.md
Краткая сводка по последним версиям:
| Версия | Однострочное описание |
|---|---|
1.5.3-beta |
Агрегат исправлений code-review (P0/P1/P2/P3 + P4/P5 архитектурный долг и logging cleanup) и upstream-парити-фикс по alireza0/s-ui#1114: TUIC subscription/share links и Clash export теперь включают udp_relay_mode (по умолчанию quic, если режим не задан). Логирование полностью переведено на slog, зависимость op/go-logging удалена, restart-manager унифицирован, поведение listen-address fallback задокументировано, globals частично вынесены в initial DI slice. |
1.5.2-beta-hotfix2 |
Снятие legacy unique-индекса idx_client_ips_client_ip на (client_name, ip). Автобэкап перед миграцией с 3x-ui больше не падает с UNIQUE constraint failed: client_ips.client_name, client_ips.ip при наличии нескольких строк client_ips с пустым legacy ip. to1_5 идемпотентна и повторно прогоняется на уже обновлённых панелях; ensureIndexes дропает устаревший индекс на каждом InitDB, чтобы временная backup-БД его тоже не получала. |
1.5.2-beta-hotfix |
Чанки в бэкапе и безопасность SPA при апгрейде: database/bulk.go держит каждый INSERT бэкапа в пределах бюджета переменных SQLite, что чинит too many SQL variables на инсталлах с большими stats/client_ips/clients/changes и разблокирует автобэкап перед миграцией с 3x-ui. web/web.go возвращает 404 для отсутствующих /<base>/assets/* вместо HTML, index.html отдаётся с no-cache, а vite:preloadError делает одну защищённую перезагрузку — вкладка Clients больше не ломается после апгрейда. |
1.5.2-beta |
Пакет миграции из 3x-ui: CLI s-ui import-xui, HTTP-API POST /api/import-xui, секция «Migrate from 3x-ui» в Backup & Restore, полный мастер на /migrate-xui (plan/apply/rollback, прогресс по WS, отчёт JSON/Markdown), удалённые источники SSH и xuihttp, cron-job xuiSyncJob с зашифрованными xui_sync_profiles, страница /migrate-xui/schedule, best-effort импорт исторического трафика и Xray routing-правил, новый scope токена xui_remote. |
1.5.1-beta |
Закрытие техдолга и UI: асинхронная очередь Telegram, redaction payload'ов, hardened realtime WS handshake, scoped audit endpoint, hashed/retained client IPs, Telegram через прокси с нормализованными errorClass, бакетированная observability, готовый фронт. |
1.5.0 |
Фундамент безопасности и realtime: secretbox для секретов, audit_events + /api/security/audit, CSRF для browser API, hashed/scoped API tokens, Bearer auth (legacy Token deprecated), per-client subscription secrets, /api/realtime/ws*, IP monitor (monitor-only по умолчанию). |
1.4.3 |
Обновление sing-box runtime с v1.13.4 до v1.13.11. БД и UI без изменений. |
1.4.2-beta |
Хардеринг безопасности и надёжности: bcrypt с ленивой миграцией, login rate limiter, защищённые cookie, SSRF-защищённый загрузчик подписок, параметризованный SQL, race-free runtime, авто-адаптация легаси-бэкапов, двуязычный установщик. Модуль переименован в github.com/deposist/s-ui-rus-inst. |
Полный список изменений, breaking-заметки, гайд по обновлению и инструкции по откату — в выбранном вами changelog.
Показать подробности
Этот форк бинарно совместим с alireza0/s-ui — новый бинарник можно
ставить поверх работающей установки 1.x, схема БД автоматически
обновится при первом старте. Цель форка — усилить безопасность и
надёжность, не меняя протокол.
- Авторизация и сессия. bcrypt с ленивой миграцией, случайный пароль администратора при первой установке (выводится в журнал один раз), лимит на неуспешные логины, cookie сессии —
HttpOnly+SameSite=Lax+Secureпри HTTPS. Чувствительные настройки (Telegram bot token, креденшелы прокси, install salt) шифруются at-rest через secretbox; API-токены хранятся как salted SHA-256. CSRF-защита на browser/api/*-mutating-запросах. - Scopes API-токенов.
admin,read,writeиobservabilityописаны вdocs/scope-matrix.md, включая audit, database, Telegram, rotation subscription-secret, observability и realtime security-event. X-Forwarded-For. Заголовок игнорируется безSUI_TRUSTED_PROXIES; цепочка обходится справа налево, поддельный XFF не может обойти IP-логику.- Загрузчик внешних подписок. Allow-list URL, блок приватных/loopback по умолчанию (opt-in
SUI_ALLOW_PRIVATE_SUB_URLS=true), лимит ответа 4 МиБ, защита от DNS rebinding на dial.Authorization: Bearer <token>— основной способ передачи API-токена в/apiv2/*; legacyToken-header работает сDeprecationиSunsetдоSat, 15 Aug 2026 00:00:00 GMT. - Realtime WebSocket.
/api/realtime/ws-token+/api/realtime/wsс Origin allow-list, per-IP rate-limit handshake, одноразовыми токенами, ping/pong heartbeat, idle close и close-all при ротации сессии. На фронте есть polling-фолбэк для degraded-состояний. - Per-client subscription secrets. Поддерживаются
/sub/<secret>,/sub/json/<secret>,/sub/clash/<secret>,/json/<secret>,/clash/<secret>; legacy/sub/<name>работает покаsubSecretRequired=false. Subscription-эндпоинты санитизируют response-заголовки и применяют конфигурируемый per-IP rate-limit. - Telegram-уведомления (off by default). Асинхронная bounded-очередь с retry/backoff и audit-событиями overflow/failure. Egress может идти через валидированные HTTP/HTTPS/SOCKS5-прокси. Payload, audit-детали, changes и captions проходят redaction.
- Audit и observability. Таблица
audit_eventsс retention GC, scoped эндпоинтGET /api/security/auditс rate-limit и cursor pagination. Bounded observability buckets (2s,30s,1m,5m), сэмплятся cron'ом. Bounded logs API и fail-soft 1h-cachedGET /api/version. - IP monitor (monitor-only по умолчанию). Соль+SHA-256 hashing, opt-in raw-display, retention GC, per-client
limitIpиipLimitMode. Enforce отбрасывает только новые сверхлимитные подключения и не разрывает активные. - Безопасность SQL. Параметризованные запросы в
service/config.goиservice/inbounds.go; в выборке пользователей по inbound — статический whitelist допустимых типов. - Импорт бэкапа / обновление.
ImportDBимеет cap 64 МиБ, проверку SQLite magic, временную staging-копию, read-onlyPRAGMA integrity_checkи audit-события. WAL/SHM сайдкары очищаются, schema-миграции иAdaptToCurrentVersionзапускаются автоматически (перешивка plaintext-паролей в bcrypt, обновление индексов, поднятиеsettings.version); при ошибке БД восстанавливается из staging. - Листен-адрес, устойчивый к переезду. Если в
webListen/subListenсохранён IP, которого нет на текущем хосте, панель пишет warning и слушает на всех интерфейсах вместо крашаEADDRNOTAVAIL. - Race-free runtime. core lifecycle, online-stats, last-update, v2 token store и realtime hub проходят
go test -race ./...(требует CGO). - HTTP server hardening. Таймауты
Read/Write/Header/Idleиtls.MinVersion = 1.2для панели и для эндпоинта подписки. Middleware security-headers (CSP, HSTS при TLS, no-store на subscription-ответах). - WARP-регистрация. Поддержка актуального API Cloudflare (
v0a4005) с заголовками первого клиента, фоллбэк наv0a2158, ретраи переходящих TLS-ошибок. - Чистота фронтенда.
v-htmlудалён из логов, ошибок импорта правил, IP-листов и gauge-плитки. Axios через экспортируемый instance,AbortControllerвместо устаревшегоCancelToken, дедупликация только для идемпотентных запросов, code splitting Vite. Realtime WS-store с reconnect/degraded состояниями. Secret-aware-поля настроек с placeholder'ом••• stored •••. IP-history modal с маской raw-IP по умолчанию. Views Telegram-настроек и Audit. - Локализация и значения по умолчанию. Многоязычные
install.shи менюs-ui(английский / русский / китайский), язык переключается на лету. Часовой пояс по умолчанию —Europe/Moscow. Локаль фронтенда по умолчанию — английский (существующие браузеры сохраняют выбор изlocalStorage).
| Возможность | Поддержка |
|---|---|
| Несколько протоколов | ✔️ |
| Несколько языков | ✔️ |
| Несколько клиентов/входящих подключений | ✔️ |
| Продвинутый интерфейс маршрутизации трафика | ✔️ |
| Клиенты, трафик и состояние системы | ✔️ |
| Ссылки подписки (link/json/clash + info) | ✔️ |
| Темная/светлая тема | ✔️ |
| API | ✔️ |
| Платформа | Архитектура | Статус |
|---|---|---|
| Linux | amd64, arm64, armv7, armv6, armv5, 386, s390x | Поддерживается |
| Windows | amd64, 386, arm64 | Поддерживается |
| macOS | amd64, arm64 | Экспериментальная поддержка |
- Порт панели: 2095
- Путь панели: /app/
- Порт подписки: 2096
- Путь подписки: /sub/
- Изменения лимита подписок на IP (
subRateLimitPerIP) применяются в течение 1 минуты после сохранения. - Имя пользователя: admin
- Пароль (только для свежей установки): при первом запуске генерируется случайная строка из 24 символов, которая выводится в журнал приложения. Найдите строку
created initial admin user. username=admin password=...вjournalctl -u s-ui(Linux) или в журнале панели после первого запуска. После входа смените пароль в настройках.
bash <(curl -Ls https://raw.githubusercontent.com/deposist/s-ui-rus-inst/beta/install.sh)- Скачайте последнюю версию для Windows из GitHub Releases.
- Распакуйте ZIP-файл.
- Запустите
install-windows.batот имени администратора. - Следуйте инструкциям мастера установки.
bash <(curl -Ls https://raw.githubusercontent.com/deposist/s-ui-rus-inst/beta/install.sh) v1.5.3-betaИли из локального клона:
git clone -b beta https://github.com/deposist/s-ui-rus-inst.git
cd s-ui-rus-inst
sudo bash install.sh v1.5.3-betaЛибо из локального клона:
git clone -b beta https://github.com/deposist/s-ui-rus-inst.git
cd s-ui-rus-inst
sudo bash install.sh v1.5.1-betaУстановщик полностью совместим с уже работающими установками: настройки, inbounds, outbounds, клиенты, TLS, services и токены сохраняются; схема БД мигрируется автоматически при первом запуске; пароль администратора в открытом виде заменяется на bcrypt-хеш при следующем успешном входе. Полный гайд по обновлению и откату — в changelog'е на нужном языке (EN · RU · 中文).
Чтобы установить определённую старую версию, добавьте тег версии с v в конец команды установки. Например, версия v1.0.0:
bash <(curl -Ls https://raw.githubusercontent.com/deposist/s-ui-rus-inst/beta/install.sh) v1.0.0- Скачайте последнюю версию S-UI для вашей системы и архитектуры из GitHub: https://github.com/deposist/s-ui-rus-inst/releases/latest
- Необязательно: скачайте последнюю версию
s-ui.sh: https://raw.githubusercontent.com/deposist/s-ui-rus-inst/beta/s-ui.sh - Необязательно: скопируйте
s-ui.shв/usr/bin/и выполнитеchmod +x /usr/bin/s-ui. - Распакуйте tar.gz-архив s-ui в выбранный каталог и перейдите в распакованную папку.
- Скопируйте файлы
*.serviceв/etc/systemd/system/, затем выполнитеsystemctl daemon-reload. - Выполните
systemctl enable s-ui --now, чтобы включить автозапуск и запустить службу S-UI. - Выполните
systemctl enable sing-box --now, чтобы запустить службу sing-box.
- Скачайте последнюю версию для Windows из GitHub: https://github.com/deposist/s-ui-rus-inst/releases/latest
- Скачайте подходящий пакет для Windows, например
s-ui-windows-amd64.zip. - Распакуйте ZIP-файл в выбранный каталог.
- Запустите
install-windows.batот имени администратора. - Следуйте инструкциям мастера установки.
- Откройте панель: http://localhost:2095/app
sudo -i
systemctl disable s-ui --now
rm -f /etc/systemd/system/sing-box.service
systemctl daemon-reload
rm -fr /usr/local/s-ui
rm /usr/bin/s-uiПоказать подробности
Шаг 1: установите Docker
curl -fsSL https://get.docker.com | shШаг 2: установите S-UI
Вариант с Docker Compose
services:
s-ui:
image: ghcr.io/deposist/s-ui-rus-inst
container_name: s-ui
hostname: "s-ui"
network_mode: host
volumes:
- "./db:/app/db"
- "./cert:/app/cert"
tty: true
restart: unless-stopped
entrypoint: "./entrypoint.sh"docker compose up -d
Прямой запуск через Docker
mkdir s-ui && cd s-ui
docker run -itd \
--network host \
-v $PWD/db/:/app/db/ \
-v $PWD/cert/:/root/cert/ \
--name s-ui \
--restart=unless-stopped \
ghcr.io/deposist/s-ui-rus-instСамостоятельная сборка образа
git clone https://github.com/deposist/s-ui-rus-inst
docker build -t s-ui .Показать подробности
./runSUI.sh# Клонирование репозитория
git clone https://github.com/deposist/s-ui-rus-instКод фронтенда находится в каталоге frontend.
Перед сборкой бэкенда нужно хотя бы один раз собрать фронтенд.
Сборка бэкенда:
# Удаление старых собранных файлов фронтенда
rm -fr web/html/*
# Копирование новых собранных файлов фронтенда
cp -R frontend/dist/ web/html/
# Сборка
go build -o sui main.goЗапуск бэкенда из корня репозитория:
./sui- Английский
- Персидский
- Вьетнамский
- Упрощенный китайский
- Традиционный китайский
- Русский
- Поддерживаемые протоколы:
- Общие протоколы: Mixed, SOCKS, HTTP, HTTPS, Direct, Redirect, TProxy
- Протоколы на базе V2Ray: VLESS, VMess, Trojan, Shadowsocks
- Другие протоколы: ShadowTLS, Hysteria, Hysteria2, Naive, TUIC
- Поддержка протокола XTLS.
- Продвинутый интерфейс маршрутизации трафика с поддержкой PROXY Protocol, External, прозрачного прокси, SSL-сертификатов и настройки портов.
- Продвинутый интерфейс настройки входящих и исходящих подключений.
- Поддержка лимита трафика и срока действия для клиентов.
- Отображение онлайн-клиентов, статистики трафика входящих и исходящих подключений, а также мониторинг состояния системы.
- Служба подписок поддерживает добавление внешних ссылок и подписок.
- Web-панель и служба подписок поддерживают безопасный доступ по HTTPS (необходимо самостоятельно предоставить домен и SSL-сертификат).
- Темная/светлая тема.
Показать подробности
| Переменная | Тип | Значение по умолчанию |
|---|---|---|
| SUI_LOG_LEVEL | "debug" | "info" | "warn" | "error" |
"info" |
| SUI_DEBUG | boolean |
false |
| SUI_BIN_FOLDER | string |
"bin" |
| SUI_DB_FOLDER | string |
"db" |
| SINGBOX_API | string |
- |
| SUI_TRUSTED_PROXIES | список CIDR/IP через запятую | - (XFF игнорируется) |
| SUI_ALLOW_PRIVATE_SUB_URLS | boolean |
false |
| SUI_SECRETBOX_KEY | string |
- (fallback на settings.secret) |
Показать подробности
snap install core; snap refresh core
snap install --classic certbot
ln -s /snap/bin/certbot /usr/bin/certbot
certbot certonly --standalone --register-unsafely-without-email --non-interactive --agree-tos -d <ваш домен>