-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add route private ips only option (#2)
* up to date softether * Add ROUTE_PRIVATE_IPS_ONLY to route only private IPs through the VPN, optimizing traffic and performance.
- Loading branch information
Showing
3 changed files
with
64 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,45 @@ | ||
# softether-bridge | ||
softether bridge container | ||
|
||
This repository contains the Docker configuration for setting up a SoftEther VPN bridge. The SoftEther VPN Bridge serves as a link between remote site LANs and a central SoftEther VPN Server, enabling the extension of private network services across dispersed geographic locations. It is ideal for securely connecting remote branches to a main office. | ||
The bridge setup allows for both cascade connections and Layer 2 bridging with physical network interfaces, streamlining network integration and resource sharing across multiple sites. | ||
|
||
|
||
## Setup and Configuration | ||
|
||
1. **Clone the repository**: | ||
Clone this repository to your local system using the following command: | ||
```bash | ||
git clone https://github.com/sammrai/softether-bridge.git | ||
cd softether-bridge | ||
``` | ||
|
||
2. **Configure the environment variables**: | ||
Before running the Docker container, configure the required environment variables in the `docker-compose.yml` file. Ensure that `USERNAME`, `PASSWORD`, `PSK`, and `VPN_SERVER` are set as these are mandatory for establishing a VPN connection. The `ROUTE_PRIVATE_IPS_ONLY` variable is optional and can be used to restrict the VPN routing to private IP addresses only: | ||
```yaml | ||
environment: | ||
USERNAME: your_username # Required. The username required to authenticate to the VPN server. | ||
PASSWORD: your_password # Required. The password for the VPN server authentication. | ||
PSK: your_pre_shared_key # Required. The pre-shared key (PSK) for the VPN connection. | ||
VPN_SERVER: vpn.example.com # Required. The address of the VPN server. | ||
ROUTE_PRIVATE_IPS_ONLY: true # Optional. When set to `true`, only routes private IPs through the VPN. | ||
``` | ||
|
||
## Running the Container | ||
|
||
Once you have configured the necessary environment variables, you can proceed to run the Docker container: | ||
|
||
```bash | ||
docker-compose up -d | ||
``` | ||
|
||
This command will start the SoftEther VPN Bridge in a detached mode, running in the background. You can check the logs to ensure that the VPN Bridge is functioning properly: | ||
|
||
```bash | ||
docker logs softether-bridge | ||
``` | ||
|
||
To stop the container, use the following command: | ||
|
||
```bash | ||
docker-compose down | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters