Server Setup
Interactive Setup
Run the setup wizard:
bash
unns setupYou'll be prompted for:
- Domain — e.g.,
tunnel.example.com - Control Port — client connections (default:
8222) - HTTP Port — public HTTP proxy (default:
8223) - Database Path — SQLite database location (default:
/etc/unne/unne.db) - Log Path — log file (default:
/var/log/unne/server.log) - Admin Panel — enable/disable, port
- Admin Credentials — username and password
The wizard will:
- Create the config file (
config.yml) - Initialize the SQLite database
- Create the admin user
- Generate the first auth token
Save your token!
The generated token is shown only once. Copy it immediately.
Manual Setup
If you prefer to set up manually:
1. Create config.yml
yaml
server:
domain: "tunnel.example.com"
control_port: 8222
http_port: 8223
storage:
database: "/etc/unne/unne.db"
logging:
file_path: "/var/log/unne/server.log"
admin:
enabled: true
port: 4041
session_ttl: "24h"2. Create admin user
bash
unns user create admin yourpassword admin3. Generate a token
bash
unns token gen 1 my-laptop