Roj1 (pronounced as Roji, Japanese for "alleyway") is a lightweight tool that carves a private, 1-to-1 path between any two points on the internet. Share Minecraft servers, AI APIs, or local databases directly and securely—without port forwarding, static IPs, or middleman fees.
While the public internet becomes increasingly crowded and monetized, Roj1 offers a quiet, hidden passage.
- Zero Tolls: No subscriptions, no bandwidth caps, and no infrastructure costs.
- Pure P2P: Your data stays between you and your peer. No traffic ever touches a central relay server.
- Single Binary: A single Go binary. No drivers, no complex networking, just a direct link.
- NAT-Proof: Effortlessly traverses home routers and mobile hotspots using STUN/WebRTC.
- Lightweight: The core is built using only the
gorilla/websocketandpion/webrtclibraries.
| Service | The Host (Source) | The Peer (Destination) | The Experience |
|---|---|---|---|
| Gaming | Run Minecraft dedicated server on port 25565. |
Set port 25565 in Roj1 and establish the connection. |
Join the server via 127.0.0.1. Low latency, no Hamachi bloat, even for heavy modpacks. |
| AI / LLM | Host your AI service (e.g., Ollama (11434)) on your GPU rig. |
Map to any available local port in Roj1 and connect. | Use remote GPU power as if the AI were running natively on your laptop. |
| Self-Hosted Tools | Run collaboration platforms like Mattermost, Wiki.js, or Penpot locally. | Same as above | Teams can collaborate on self-hosted instances without VPS or cloud deployment. |
The Host needs Visual Studio Code installed to handle the initial handshake via its native Port Forwarding feature (requires a GitHub login).
- Download: Get the latest binary for your OS from the Releases page.
- Launch: Run the executable in your terminal.
- Launch
roj1and select Host. - Enter your local service port (e.g.,
25565). - In VS Code's Ports panel, forward the port provided by the CLI and set visibility to Public.
- Share the generated Forwarded URL with your peer.
- Once connected, you can stop the VS Code forward; the P2P tunnel is now independent.
- Launch
roj1and select Client. - Paste the URL provided by the Host.
- Choose a local port to map the service to.
- Access the service at
127.0.0.1:<your_port>.
For automation or LAN setups, Roj1 can be launched entirely from the command line, bypassing the interactive prompts. If -role is omitted, the tool falls back to the default interactive mode.
| Flag | Description | Applies To |
|---|---|---|
-role |
host or client |
Both |
-port |
Target port (Host) or virtual service port (Client) | Both |
-wsPort |
WebSocket signaling server port (default: random) | Host |
-wsUrl |
WebSocket URL to connect to | Client |
-wsListen |
Listen on all network interfaces (LAN-accessible) | Host |
-debug |
Enable debug logging | Both |
Host example:
roj1 -role host -port 25565 -wsPort 9000 -wsListenClient example:
roj1 -role client -port 25565 -wsUrl ws://192.168.1.10:9000/wsTIP: When both machines are on the same local network, use
-wsListenon the Host to make the WebSocket signaling server directly reachable via LAN IP. This eliminates the need for VS Code Port Forwarding entirely — the Client simply connects usingws://<host-lan-ip>:<wsPort>/ws.
- Optimal: Fiber, Home Wi-Fi, 4G/5G mobile hotspots.
- Limited: Strict corporate firewalls (Symmetric NAT) or public Wi-Fi with P2P blocking.
Report bugs or suggest features via GitHub Issues. Please include your OS version and any error logs.