Hi, Scott James Remnant: > This is automatic enabling and disabling, and is solved in the 0.10 > design, you'd just use a while state that specified either on AC power > only, or on battery only. > I don't particularly care if it's automatic, manual, or by phase-of-moon. The point is that some process needs to add this while clause to the MySQL-or-whatever config file in question.
And that's a problem. Provisionally I'd invent a scheme whereby a
section of the upstart files are marked along these lines
### BEGIN AUTOMATED SECTION ###
## added by PowerManager
while ac-powered
## added by NetworkManager
while has-default-route
### END AUTOMATED SECTION ###
but IMHO that's really ugly, and Debian-based distributions don't play
well with that kind of thing.
A possible alternate way would be to support clauses like
# cat /etc/event.d/PowerManagerMods
modify mysql-server
while ac-powered
which would have the exact same semantics. That'd also be a rather easy
way to disable a service. All without touching said service's own config
files.
--
Matthias Urlichs | {M:U} IT Design @ m-u-it.de | [EMAIL PROTECTED]
Disclaimer: The quote was selected randomly. Really. | http://smurf.noris.de
v4sw7$Yhw6+8ln7ma7u7L!wl7DUi2e6t3TMWb8HAGen6g3a4s6Mr1p-3/-6 hackerkey.com
- -
For 20 dollars, I'll give you a good fortune next time ...
signature.asc
Description: Digital signature
-- upstart-devel mailing list [email protected] Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/upstart-devel
