Replies: 1 comment 1 reply
-
|
FWIW the workaround that I've found easiest is an external watchdog service. It watches for disconnection and sends the quit instruction to sunshine via API. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Select Topic Area
Feature Request
Body
Problem
When a Moonlight client disconnects (network drop, app crash, minimize, etc.), Sunshine keeps the session in a "paused" state indefinitely. The
undocommands fromglobal_prep_cmdonly execute when the session is explicitly quit, not on disconnect.
This creates problems for users who use prep commands to modify system state:
If the client crashes or the user forgets to explicitly "Quit Session", the system remains in the prep'd state until manual intervention.
Use Case
I use Sunshine to stream to a headless virtual display while disabling physical monitors and local input devices (security measure - only the stream can interact with the unlocked
session). If Moonlight crashes or disconnects unexpectedly, local input remains disabled and I'm locked out until I can SSH in or force quit the session from another device.
Proposed Solution
One or both of:
Option A: Session timeout
session_disconnect_timeout = 30
Auto-terminate session N seconds after last client disconnects. Value of 0 preserves current behavior (infinite pause).
Option B: Disable pause entirely
terminate_on_disconnect = true
Treat disconnect as session end. No pause state - client disconnect immediately triggers session termination and undo commands.
Workarounds Considered
These work but add complexity. Native support would be cleaner and more reliable.
Related
Beta Was this translation helpful? Give feedback.
All reactions