Expand description
Daemonization support for running hyprstream in the background
Provides helper functions for detaching the process from the terminal and running as a background daemon.
§Usage
ⓘ
use hyprstream::cli::daemon::maybe_daemonize;
// In server startup, before creating tokio runtime:
maybe_daemonize(detach, working_dir, pid_file)?;Functions§
- check_
running - Check if a PID file exists and the process is still running
- maybe_
daemonize - Daemonize the process if requested
- stop_
daemon - Stop a running daemon by sending SIGTERM