This repository contains a Docker Compose file designed to run V2Ray as a bridge (relay) server for the Outline (a shadowsocks proxy by Google Jigsaw). The primary goal is to enhance the functionality of the Outline in highly restricted networks where direct connection from users to Outline servers is not possible.
Outline is a set of proxy tools developed by Google Jigsaw based on the shadowsocks protocol. It includes:
- Outline Manager: A desktop app for setting up servers, managing users, and tracking used traffic.
- Outline Server: A shadowsocks server that will be installed on the servers by the Outline Manager app.
- Outline Client: A user-friendly and cross-platform app for users.
The original Outline proxy flow:
Outline Client <-> Outline Server <-> (Internet)
(User Network) <-> (Upstream Server) <-> (Internet)
Read the Outline official documentation to set up an Outline server.
V2Ray is a proxy tool that supports multiple protocols, including the dokodemo-door
protocol.
This specific protocol forwards incoming traffic (TCP and UDP) from a specified port to a designated destination port.
A bridge (relay) server connects clients to Outline servers by forwarding their traffic.
It changes the Outline flow as below.
Outline Client <-> V2Ray Proxy <-> Outline Server <-> (Internet)
(User Network) <-> (Bridge Server) <-> (Upstream Server) <-> (Internet)
To set up a bridge (relay) server using V2Ray, follow these steps:
- Install Docker and Docker-compose on the bridge (relay) server.
- Clone this repository into the bridge server.
- Run
./setup.py
. It prompts the following items:-
Number of Outline servers
: Please provide the number of servers, typically just1
-
Outline server i host
: Find it in$\color{green}{\textsf{Outline Manager}}$ >Settings
>Hostname
-
Outline server i port
: Find it in$\color{green}{\textsf{Outline Manager}}$ >Settings
>Port for new access keys
- If you are using a firewall such as
ufw
, add the port to the whitelist.
-
- Run
docker-compose up -d
ordocker compose up -d
. - Change
$\color{green}{\textsf{Outline Manager}}$ >Settings
>Hostname
field to the bridge server IP address. - Delete old access keys in the
$\color{green}{\textsf{Outline Manager}}$ and generate new ones. - Download Outline Client and import a generated access key.
- Press
$\color{green}{\textsf{CONNECT}}$ and enjoy the freedom!