I'd like my Linux server that runs SlimServer to shut down automatically
at night if no players are currently playing.  I mentioned this a while
ago and someone pointed out that I could do this using the SlimServer
CLI.  I've now written a Perl script to do just this, so thought I'd
post it to get some general comments.  The script interrogates the cli
to find out if any players are playing and, if not, displays a warning
on each player before triggering a delayed shutdown of the server. 
It's designed to be cronned every day between a certain time range
(midnight to 8am, for example).

I'd appreciate any comments on this script.  Part of the reason for
doing it was to refresh my very rusty Perl, so picky language points
are very welcome!

I haven't yet cronned this script myself, so caveat emptor!

Max


+-------------------------------------------------------------------+
|Filename: shutdown.pl.txt                                          |
|Download: http://forums.slimdevices.com/attachment.php?attachmentid=194|
+-------------------------------------------------------------------+

-- 
max.spicer

The wild things roared their terrible roars and gnashed their terrible
teeth
and rolled their terrible eyes and showed their terrible claws
but Max stepped into his private boat and waved good-bye
_______________________________________________
Discuss mailing list
[email protected]
http://lists.slimdevices.com/lists/listinfo/discuss

Reply via email to