[MacPorts] #22570: startupitems - No RunAtLoad setting ?
#22570: startupitems - No RunAtLoad setting ? ---------------------------------+------------------------------------------ Reporter: dreamcat4@… | Owner: macports-tickets@… Type: defect | Status: new Priority: Normal | Milestone: Component: base | Version: 1.8.1 Keywords: | Port: ---------------------------------+------------------------------------------ It seems that we could easily template - out some flexibility in the launchd startupitems. Ideally, to allow users to run a command which affects the "RunAtLoad" plist key. OnDemand key is also worthwhile to template. <key>OnDemand</key><false/> <key>RunAtLoad</key><false/> Similar tickets #18174 and #22471 -- Ticket URL: <http://trac.macports.org/ticket/22570> MacPorts <http://www.macports.org/> Ports system for Mac OS
#22570: startupitems - No RunAtLoad setting ? ---------------------------------+------------------------------------------ Reporter: dreamcat4@… | Owner: macports-tickets@… Type: defect | Status: new Priority: Normal | Milestone: Component: base | Version: 1.8.1 Keywords: | Port: ---------------------------------+------------------------------------------ Comment(by dreamcat4@…): BUT RunAtLoad generally doesn't play nicely with Daemondo. It's all to do with forking and listen ports. Launchd can't hand over the TCP port / sockets its listening in on to anything other than the process it launched. So uh-oh! Running daemondo will *not* work. Period. Launchd must perform certain process - port - handover to the newly launched process, and daemondo doesn't know anything about TCP port / unix socket to hand over. Just running the command directly will solve such problem entirely. So to use effectively by a startupitem template we need an alternate non- daemondo template. Currently all startupitems templates use daemondo. This would have to change for allowing some bare command running in the generated plist file. -- Ticket URL: <http://trac.macports.org/ticket/22570#comment:1> MacPorts <http://www.macports.org/> Ports system for Mac OS
#22570: startupitems - RunAtLoad setting ---------------------------------+------------------------------------------ Reporter: dreamcat4@… | Owner: macports-tickets@… Type: enhancement | Status: new Priority: Normal | Milestone: Component: base | Version: 1.8.1 Keywords: | Port: ---------------------------------+------------------------------------------ Changes (by jmr@…): * type: defect => enhancement -- Ticket URL: <http://trac.macports.org/ticket/22570#comment:2> MacPorts <http://www.macports.org/> Ports system for Mac OS
#22570: startupitems - RunAtLoad setting ---------------------------------+------------------------------------------ Reporter: dreamcat4@… | Owner: macports-tickets@… Type: enhancement | Status: new Priority: Normal | Milestone: Component: base | Version: 1.8.1 Keywords: | Port: ---------------------------------+------------------------------------------ Comment(by dreamcat4@…): {{{ BUT RunAtLoad generally doesn't play nicely with Daemondo. }}} Sorry I meant to say "OnDemand" and not RunAtLoad. -- Ticket URL: <http://trac.macports.org/ticket/22570#comment:3> MacPorts <http://www.macports.org/> Ports system for Mac OS
#22570: startupitems - RunAtLoad setting ---------------------------------+------------------------------------------ Reporter: dreamcat4@… | Owner: macports-tickets@… Type: enhancement | Status: new Priority: Normal | Milestone: Component: base | Version: 1.8.1 Keywords: | Port: ---------------------------------+------------------------------------------ Comment(by dreamcat4@…): In 10.6 you can programmatically manipulate the overrides.plist. Although there is no sanctioned command to do so. /var/db/launchd.db/com.apple.launchd/overrides.plist It would be possible to write an api command to insert / modify the relevant xml fragment. For example {{{ <key>org.macports.nginx</key> <dict> <key>Disabled</key> <false/> </dict> <key>org.macports.rabbitmq-server</key> <dict> <key>Disabled</key> <false/> <key>RunAtLoad</key> <true/> </dict> <key>org.macports.rb-chef-indexer</key> <dict> <key>Disabled</key> <false/> </dict> <key>org.macports.rb-chef-server</key> <dict> <key>Disabled</key> <true/> </dict> }}} -- Ticket URL: <http://trac.macports.org/ticket/22570#comment:4> MacPorts <http://www.macports.org/> Ports system for Mac OS
#22570: startupitems - RunAtLoad setting ---------------------------------+------------------------------------------ Reporter: dreamcat4@… | Owner: macports-tickets@… Type: enhancement | Status: new Priority: Normal | Milestone: Component: base | Version: 1.8.1 Keywords: | Port: ---------------------------------+------------------------------------------ Comment(by dreamcat4@…): Okay, I've attached some sensible defaults for: http://trac.macports.org/browser/trunk/base/src/port1.0/portstartupitem.tcl The OnDemand key itself is now deprecated and defaults to false anyway. Use Sockets / WatchPaths / QueueDirectories keys for setting OnDemand status. That's a more complex area. Until then please use the patch. This patch will make the "port load" command persistent across reboots. Update base and re-install ports to take effect. -- Ticket URL: <http://trac.macports.org/ticket/22570#comment:5> MacPorts <http://www.macports.org/> Ports system for Mac OS
#22570: startupitems - RunAtLoad setting --------------------------+-------------------------------- Reporter: dreamcat4@… | Owner: macports-tickets@… Type: enhancement | Status: closed Priority: Normal | Milestone: Component: base | Version: 1.8.1 Resolution: fixed | Keywords: Port: | --------------------------+-------------------------------- Changes (by cal@…): * status: new => closed * resolution: => fixed Comment: I think this is fixed because we use `<key>KeepAlive</key><true/>` on systems > 10.4 now. -- Ticket URL: <https://trac.macports.org/ticket/22570#comment:6> MacPorts <http://www.macports.org/> Ports system for OS X
participants (1)
-
MacPorts