Jerusalem Tunnel is a cross-platform ngrok
alternative written in Go. It allows clients to reserve a port and complete
a handshake using a secret key shared between the server and the client, identified uniquely by a clientID.
- Cross-Platform: Works on Windows, macOS, and Linux.
- Port Reservation: Reserve a port for the client.
- Secure Handshake: Client and server complete a handshake using a secret key and unique clientID.
-
Ensure you have Go 1.22 or later installed.
-
Clone the repository:
git clone https://github.com/yourusername/jerusalem-tunnel.git cd jerusalem-tunnel
-
Build the project:
go build -o jerusalem-tunnel -v ./...
Start the server:
./jerusalem-tunnel --config config.yaml
Start the server using Docker:
docker build -t jerusalem-tunnel .
docker run -d -p 8901:8901 --name jerusalem-tunnel -v $(pwd)/config.yaml:/app/config.yaml jerusalem-tunnel
Or using docker compose:
docker compose up -d
The server requires a configuration file in YAML format to run. Example server.yaml
:
PORT_RANGE: "2000...8999"
SECRET_KEY: "2y6sUp8cBSfNDk7Jq5uLm0xHAIOb9ZGqE4hR1WVXtCwKjP3dYzvTn2QiFXe8rMb6"
SERVER_PORT: 8901
Contributions are welcome! Please fork the repository and submit a pull request.
This project is licensed under the Mozilla Public License Version 2.0. See the LICENSE file for details.