Bryan - I agree with the Ubuntu community that OpenHPI should not be started by default.
I am fine with either method you have suggested - but I prefer your second option - simply because it does not violate the syntax rules for the openhpi.conf file - and perhaps will aviod some user confusion. --michael > -----Original Message----- > From: Sutula, Bryan (Open Source Program Office) > Sent: Thursday, June 10, 2010 10:07 AM > To: [email protected] > Subject: [Openhpi-devel] Proposal to not run OpenHPI daemon by default > > > I've received a request from the Ubuntu community that the OpenHPI > daemon not be started by default. This is a common issue for Linux > distributions, but I do think it would be a helpful change for the > OpenHPI project itself. > > Right now, OpenHPI ships with an openhpi.conf file that runs the > simulator plug-in. Although that is fairly benign, it is probably not > useful to the end user, and almost certainly not the > configuration that > is desired in the end. It seems to me (and to the Ubuntu people) that > it would be better if the OpenHPI daemon did not run unless > the user had > configured the openhpi.conf file. > > I think there is a simple way to do this, that doesn't break backward > compatibility with existing installations: > > 1) Add lines to the top of the default openhpi.conf file, > something like > the following: > > # The OpenHPI daemon will not run by default, until you have set it up > # for your particular hardware situation. After modifying this file, > # remove the following line: > unconfigured > > 2) The openhpid init script could grep for "^unconfigured$", > and simply > exit rather than starting openhpid if that line is found. > > Done this way, upgrades are not affected because the user's existing > openhpi.conf file is already configured. In addition, the behavior is > backward compatible because the change in behavior will only > occur if a > user obtains a fresh (unconfigured) version of openhpi.conf, such as > would happen with a new installation. > > The mechanism I proposed above is the simplest I can see, and could be > done in time for 2.15.0. A drawback is that if the user tries to run > the daemon by hand, the daemon will see a syntax error in the config > file. > > A different implementation of the same idea could involve the addition > of a new environment variable to the first section of the openhpi.conf > file (perhaps OPENHPI_UNCONFIGURED) which would be uncommented in the > default version of the file. We would then modify the daemon > such that > it does an immediate exit if a true value is detected in this > variable. > This is a cleaner approach, but is a little more work. > > Thoughts? I propose to implement one of the above solutions > towards the > end of this week unless there is objection. > > Bryan Sutula > > > -------------------------------------------------------------- > ---------------- > ThinkGeek and WIRED's GeekDad team up for the Ultimate > GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the > lucky parental unit. See the prize list and enter to win: > http://p.sf.net/sfu/thinkgeek-promo > _______________________________________________ > Openhpi-devel mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/openhpi-devel > ------------------------------------------------------------------------------ ThinkGeek and WIRED's GeekDad team up for the Ultimate GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the lucky parental unit. See the prize list and enter to win: http://p.sf.net/sfu/thinkgeek-promo _______________________________________________ Openhpi-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/openhpi-devel
