@@ -355,19 +355,36 @@ cd ../..
|
||||
# Server starts on :10087
|
||||
```
|
||||
|
||||
### Option 4: Systemd Service
|
||||
### Option 4: Native CLI / Systemd Service
|
||||
|
||||
The WGRplane binary includes a built-in CLI to manage its own systemd service.
|
||||
|
||||
```bash
|
||||
# Install service file
|
||||
sudo cp wgrplane.service /etc/systemd/system/
|
||||
sudo systemctl daemon-reload
|
||||
sudo systemctl enable wgrplane.service
|
||||
sudo systemctl start wgrplane.service
|
||||
# Check system dependencies first
|
||||
./wgrplane doctor
|
||||
|
||||
# Install as systemd service (auto-creates unit, enables, and starts)
|
||||
sudo ./wgrplane install
|
||||
|
||||
# View logs
|
||||
journalctl -u wgrplane.service -f
|
||||
journalctl -u wgrplane -f
|
||||
|
||||
# Other available commands:
|
||||
sudo ./wgrplane stop
|
||||
sudo ./wgrplane restart
|
||||
sudo ./wgrplane uninstall
|
||||
```
|
||||
|
||||
### Manual Serve & Config
|
||||
|
||||
To run the server manually in the foreground with custom ports:
|
||||
|
||||
```bash
|
||||
./wgrplane serve --port 8080 --host 127.0.0.1
|
||||
```
|
||||
|
||||
On first run, it generates a default configuration file at `~/.config/wgrplane/config.json`.
|
||||
|
||||
---
|
||||
|
||||
## 📁 Project Structure
|
||||
|
||||
Reference in New Issue
Block a user