How can I stop the Pow server from starting when the computer boots (OS X)?

TL DR: is there a way to disable Pow-server startup when my computer boots up, but keep the ability to start the server manually through powder upwhen I need it?

I use Pow for my local development (and controlling through Powder Pearls ). I would like to configure Pow so that the server does not start automatically at startup, since starting it drains battery life, and I do not always code.

Pow added itself to launchd, and I can’t find a scenario where the Pow server does not start after starting, but it can still be executed using powder upor another equivalent command when I need to start the server.

What I tried did not work:

  • setting a disabled key for a process cx.pow.powdwith launchctl unload -w ~/Library/LaunchAgents/cx.pow.powdprevents Pow from loading at startup, but also prevents the process from starting manually when I need it
  • RunAtLoadto NOin the cx.pow.powd.plist file also does not work, later I realized that this is not for controlling the start of daemon behavior.
+4
source share
3 answers

I forgot to answer, I finished finding out.

It turns out that it is quite simple in fact and quite easy using Lunchy (a friendly shell for launchctctl) and a quick bit o 'bash aliasing. A bit hacked, and I don’t know what to launch very well, but it does the trick.

(, Lunchy Pow ):

  • lunchy stop -w pow: Pow launchctll, Pow . ( .)
  • .bash_profile ( .profile ..), . = > alias pu='lunchy start -F pow'

, Pow , pu ( ) . , /, lunchy status.

, / , , (mongo, redis ..).

+3

KeepAlive PathState.

PathState <dictionary of booleans>
       Each key in this dictionary is a file-system path. If the value of the key is true, then the job
       will be kept alive as long as the path exists.  If false, the job will be kept alive in the
       inverse condition. The intent of this feature is that two or more jobs may create semaphores in
       the file-system namespace.

, pow-.

0

I recently ran into this problem and solved it by simply moving it cx.pow.powd.plistto another folder, which successfully disables the automatic start of the Pow server. When I want to start it again, I just moved it cx.pow.powd.plistback in ~/Library/LaunchAgents/cx.pow.powdand started it powder up.

0
source

All Articles