[MacPorts] #16969: Cacti: plist to use instead of cron
#16969: Cacti: plist to use instead of cron ---------------------------------+------------------------------------------ Reporter: wsiegrist@apple.com | Owner: markd@macports.org Type: enhancement | Status: new Priority: Normal | Milestone: Port Enhancements Component: ports | Version: Keywords: | Port: cacti ---------------------------------+------------------------------------------ Cacti gives the user instructions for installation involving cron. It would be nice if it also offered a plist to use like: {{{ <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> <plist version="1.0"> <dict> <key>Label</key> <string>org.macports.cacti.poll</string> <key>ProgramArguments</key> <array> <string>/opt/local/bin/php</string> <string>/opt/local/share/cacti/poller.php</string> </array> <key>StartInterval</key> <integer>300</integer> <key>UserName</key> <string>_www</string> </dict> </plist> }}} -- Ticket URL: <http://trac.macports.org/ticket/16969> MacPorts <http://www.macports.org/> Ports system for Mac OS
#16969: Cacti: plist to use instead of cron ----------------------------------+----------------------------------------- Reporter: wsiegrist@apple.com | Owner: markd@macports.org Type: enhancement | Status: new Priority: Normal | Milestone: Port Enhancements Component: ports | Version: Resolution: | Keywords: Port: cacti | ----------------------------------+----------------------------------------- Comment(by markd@macports.org): Good idea, but I wonder whether adding 'startupitem.user' and 'startupitem.interval' to base could be done? It seems like this functionality might be useful for other things too. But I'm not sure if daemondo would support 'StartInterval', so perhaps that would need to be modified as well, or perhaps another type of startupitem that does not use daemondo? I guess tracking a process isn't necessary for periodic process execution. What do you think? -- Ticket URL: <http://trac.macports.org/ticket/16969#comment:1> MacPorts <http://www.macports.org/> Ports system for Mac OS
#16969: Cacti: plist to use instead of cron ----------------------------------+----------------------------------------- Reporter: wsiegrist@apple.com | Owner: markd@macports.org Type: enhancement | Status: new Priority: Normal | Milestone: Port Enhancements Component: ports | Version: Resolution: | Keywords: Port: cacti | ----------------------------------+----------------------------------------- Comment(by wsiegrist@apple.com): Daemondo solves the problem of daemon processes not behaving correctly for launchd, but for periodic jobs I think you can skip daemondo completely. Adding the user and interval seems like a good idea. The startupitem generation could then make a daemondo or non-daemondo plist according to what options were provided. If startupitem.interval is provided (and non zero?) then you make something like I posted in the description, otherwise you make a daemondo-based plist. -- Ticket URL: <http://trac.macports.org/ticket/16969#comment:2> MacPorts <http://www.macports.org/> Ports system for Mac OS
#16969: Cacti: plist to use instead of cron ----------------------------------+----------------------------------------- Reporter: wsiegrist@apple.com | Owner: markd@macports.org Type: enhancement | Status: new Priority: Normal | Milestone: Port Enhancements Component: ports | Version: Resolution: | Keywords: Port: cacti | ----------------------------------+----------------------------------------- Comment(by markd@macports.org): Yeah, that's what I was thinking: a non-daemondo startupitem (when 'startupitem.interval' is used) that would default to user 'root' perhaps if no 'startupitem.user' is specified? Also, would a 'startupitem.inetd' be a candidate for another non-daemondo startupitem for inetd emulation? I did a little hacking in base once before I realized that daemondo couldn't handle that and quit, without ever thinking of bypassing it altogether. Inetd emulation has been asked for and I'd like it too. -- Ticket URL: <http://trac.macports.org/ticket/16969#comment:3> MacPorts <http://www.macports.org/> Ports system for Mac OS
#16969: Cacti: plist to use instead of cron ---------------------------------+------------------------------------------ Reporter: wsiegrist@… | Owner: markd@… Type: enhancement | Status: new Priority: Normal | Milestone: Port Enhancements Component: ports | Version: Keywords: | Port: cacti ---------------------------------+------------------------------------------ Comment(by snc@…): Replying to [comment:3 markd@…]:
Yeah, that's what I was thinking: a non-daemondo startupitem (when 'startupitem.interval' is used) that would default to user 'root' perhaps if no 'startupitem.user' is specified? If no username is provided I'd suggest using the name of the port as a new user (to avoid running things that could be exploited).
-- Ticket URL: <http://trac.macports.org/ticket/16969#comment:5> MacPorts <http://www.macports.org/> Ports system for Mac OS
#16969: Cacti: plist to use instead of cron --------------------------+-------------------------------- Reporter: wsiegrist@… | Owner: macports-tickets@… Type: enhancement | Status: new Priority: Normal | Milestone: Component: ports | Version: Resolution: | Keywords: Port: cacti | --------------------------+-------------------------------- Changes (by mf2k@…): * owner: markd@… => macports-tickets@… Comment: markd has retired. See #44782. -- Ticket URL: <https://trac.macports.org/ticket/16969#comment:7> MacPorts <http://www.macports.org/> Ports system for OS X
participants (1)
-
MacPorts