doc: update README.md

This commit is contained in:
tux
2025-06-25 01:41:45 +05:30
parent 5d4e2db710
commit ce0671c15d

View File

@ -21,9 +21,9 @@
## Features ## Features
- [x] TCP Tunneling - [x] TCP Tunneling
- [ ] UDP Tunneling - [ ] UDP Tunneling (planned)
- [x] HTTP Tunneling - [x] HTTP Tunneling
- [ ] HTTPS Tunneling - [ ] HTTPS Tunneling (planned)
## Installation ## Installation
@ -52,18 +52,25 @@ environment.systemPackages = [ inputs.trok.packages.${system}.default ];
``` ```
## Usage ## Usage
Start a TCP tunnel: Start a TCP tunnel:
```sh ```sh
trok tcp PORT_NUMBER trok tcp PORT_NUMBER
``` ```
Example: Example:
```sh ```sh
trok tcp 3000 trok tcp 3000
``` ```
This will expose your local service running on port `3000` to a public endpoint via the `trok` server. This will expose your local service running on port `3000` to a public endpoint via the `trok` server.
## Selfhost ## Selfhost
You can host your own `trok` server with NixOS: You can host your own `trok` server with NixOS:
```nix ```nix
# Add to your flake inputs # Add to your flake inputs
trok = { trok = {
@ -87,4 +94,5 @@ trok = {
}; };
} }
``` ```
Once deployed, your `trok` server will be ready to handle tunneling requests from clients. Once deployed, your `trok` server will be ready to handle tunneling requests from clients.