Quantcast
Channel: 318, Inc. | Technology. Solutions. Consulting. » script
Viewing all articles
Browse latest Browse all 5

Add OS X Network Settings Remotely (Without Breaking Stuff)

0
0

So you’re going to send a computer off to a colocation facility, and it’ll use a static IP and DNS when it gets there, the info for which it’ll need before it arrives. Just like colo, you access this computer remotely to prepare it for its trip, but don’t want to knock it off the network while prepping this info, so you can verify it’s good to go and shut it down.

It’s the type of thing, like setting up email accounts programmatically, that somebody should have figured out and shared with the community as some point. But even if my google-fu is weak, I guess I can deal with having tomatoes thrown at me, so here’s a rough mock-up:

 
[gist]https://gist.github.com/dev318/6639046[/gist]

Caveats: The script assumes the interface you want to be active in the future is en0, just for ease of testing before deployment. Also, that there isn’t already a network location called ‘Static’, and that you do want all interface populated upon creation(because I couldn’t think of particularly good reasons why not.)

If you find the need, give it a try and tweet at us with your questions/comments!



Viewing all articles
Browse latest Browse all 5

Latest Images

Trending Articles





Latest Images