Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

GirthP

macrumors regular
Original poster
Oct 1, 2007
121
0
Ok, I hope this is the right forum to place this query.

I want to set up an automatic script to run hamachi at login.

I just need a little direction, and don't mind doing most of the legwork.

Do I write a bash script to start tuncfg (which is required first), then to start hamachi?

Do I link it somehow to launchd?

These are my guesses at this point... if I'm getting close, that would be great to know, or if I'm way off, that would be great to know.

Thanks very much for any help you can offer!
 

numero

macrumors regular
Jul 23, 2002
106
3
OR
Haven't tried this, but here is how it seems it should work.

Make a launchd .plist file. Put it in /Library/LaunchDaemons. The .plist should target a shell script that does the work you need. No need for sudo in the shell script as launchd will run the script as root. No special place required for the shell script. It can be anywhere you like.

--numero
 

krymzon40

macrumors newbie
Jul 8, 2008
8
0
Help?

Haven't tried this, but here is how it seems it should work.

Make a launchd .plist file. Put it in /Library/LaunchDaemons. The .plist should target a shell script that does the work you need. No need for sudo in the shell script as launchd will run the script as root. No special place required for the shell script. It can be anywhere you like.

--numero

Hey, can you help me out? I have no idea how to to what you said there. Could you guide me through the process?
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.