feat: add NUT (Network UPS Tools) integration base#126
feat: add NUT (Network UPS Tools) integration base#126RoiArthurB wants to merge 1 commit intodevfrom
Conversation
* Install modern `nut-client` library. * Add default `.env` configuration (NUT_HOST, NUT_PORT, NUT_UPS_NAME). * Create `NutManager` to handle UPS connections and monitor `ONBATT`, `ONLINE`, and `LOWBATT` events. * Integrate `NutManager` into `Controller` initialization and restarts. * Add list of possible features to implement inside the stub handle methods of `NutManager`. * Gracefully warn and cleanup the class when no UPS is available. Co-authored-by: RoiArthurB <16764085+RoiArthurB@users.noreply.github.com>
|
👋 Jules, reporting for duty! I'm here to lend a hand with this pull request. When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down. I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job! For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with New to Jules? Learn more at jules.google/docs. For security, I will only act on instructions from the user who triggered this task. |
|



This PR introduces the base system for integrating UPS monitoring using Network UPS Tools (NUT). It leverages the modern
nut-clientpackage and itsMonitorclass to listen for UPS events such asONBATT,ONLINE, andLOWBATT.When the Controller initializes, it will instantiate
NutManager. The manager checks if the specified UPS is available; if not, it gracefully exits and cleans itself up. Stub functions have been added to log events and outline future implementations like executing server shutdowns or turning off connected VR headsets via ADB.Related #74
PR created automatically by Jules for task 11356153773324197732 started by @RoiArthurB