Analysis updated 2026-05-18
Automatically configure a cascaded outbound connection on an Xray-core server from one VLESS link.
Route traffic to local-zone domains directly while tunneling everything else through the outbound server.
Schedule a cron job that keeps the geo-database routing files refreshed automatically.
| servertechnologies/cascade-for-x-ray | alhajashafffy/shellsafe | brettkinny/tower-dashboard | |
|---|---|---|---|
| Stars | 14 | 14 | 14 |
| Language | Shell | Shell | Shell |
| Setup difficulty | hard | easy | moderate |
| Complexity | 4/5 | 2/5 | 2/5 |
| Audience | ops devops | ops devops | ops devops |
Figures from each repo's GitHub metadata at analysis time.
Requires an existing Xray-core install plus jq, wget, python3, and systemd on the server.
Cascade-for-x-ray is a Bash script that automates the setup of a cascaded outbound connection on a server running Xray-core, a proxy tool commonly used to route internet traffic around network restrictions. It is designed to pair with the author's separate Xray installation script, and it works by taking a single VLESS connection link as input and doing the rest automatically. When you run the script and paste a VLESS link, it parses the link to extract the server address, port, user ID, transport type, and REALITY encryption parameters. It then rewrites the Xray config.json file with updated routing rules and outbound connection settings. A backup of the previous config is saved before any changes are made, so you can restore it manually if something goes wrong. The routing rules it sets up send traffic differently depending on the destination. Requests to Russian-zone domains and IP addresses (loaded from geo-database files) go directly through the server without proxying. Requests to known advertising domains are blocked. Everything else is tunneled through the outbound server specified in your VLESS link. The geo-database files themselves are downloaded fresh from a third-party repository during setup, replacing any older files. Two transport modes are supported, depending on what the VLESS link specifies: VLESS over XHTTP with REALITY encryption and multiplexing, or VLESS over TCP with REALITY and the xtls-rprx-vision flow. The script detects which to use from the type parameter in the link. The script also creates a helper script at a fixed path on the server that can be scheduled with cron to refresh the geo-database files periodically, so routing stays current without a full reconfiguration. After writing the new config, it restarts the Xray service via systemd. Dependencies are Xray-core, jq, wget, python3, and systemd, all of which are standard on Ubuntu.
Cascade-for-x-ray is a Bash script that automates configuring a cascaded outbound proxy connection for a self-hosted Xray-core server from a single VLESS link.
Mainly Shell. The stack also includes Bash, Xray-core, jq.
Use freely for any purpose, including commercial use, as long as you keep the copyright notice.
Setup difficulty is rated hard, with roughly 1h+ to a first successful run.
Mainly ops devops.
This repo across BitVibe Labs
Verify against the repo before relying on details.