Skip to content

Commit 60974ad

Browse files
committed
docs: make it more obvious that on_disconnect runs on the proxy host
1 parent edee761 commit 60974ad

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ machines:
5151
ssh_port: 22 # port to proxy/probe on the target
5252
wol_port: 9 # WOL UDP port (7 or 9)
5353
keepalive_packets: true # send periodic WOL packets while connected
54-
on_disconnect: "systemctl suspend" # optional: run this command after each session ends
54+
on_disconnect: "curl -s ntfy.sh/your-topic -d 'Gaming PC session ended'" # optional: shell command run on the proxy host after each session ends
5555

5656
- label: "Workstation"
5757
port: 2223
@@ -79,7 +79,7 @@ machines:
7979
| `machines[].ssh_port` | no | `22` | Port to probe and proxy on the target |
8080
| `machines[].wol_port` | no | `9` | UDP port for WOL magic packet |
8181
| `machines[].keepalive_packets` | no | `false` | Send a WOL packet every `keepalive_packets_interval` seconds while at least one connection is active. If the machine suspends mid-session, this re-wakes it within one interval so the SSH connection can resume without a manual reconnect. |
82-
| `machines[].on_disconnect` | no | - | Shell command (`sh -c`) to run on the proxy host after a session ends. Only fires when a connection was successfully proxied; skipped if the machine never woke up. Runs in the background so it does not block new connections. |
82+
| `machines[].on_disconnect` | no | - | Shell command (`sh -c`) run on the **proxy host** (not the target machine) after a session ends. Only fires when a connection was successfully proxied; skipped if the machine never woke up. Runs in the background so it does not block new connections. |
8383

8484
## Deployment (Docker)
8585

config.example.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ machines:
1515
ssh_port: 22 # SSH port on the target machine
1616
wol_port: 9 # WOL UDP port (7 or 9 are standard)
1717
keepalive_packets: true # send periodic WOL packets while connected to re-wake if the machine suspends
18-
on_disconnect: "systemctl suspend" # optional: command to run on the proxy host after each session ends
18+
on_disconnect: "curl -s ntfy.sh/your-topic -d 'Gaming PC session ended'" # optional: shell command run on the proxy host (not the target) after each session ends
1919

2020
- label: "Workstation"
2121
port: 2223

0 commit comments

Comments
 (0)