Beginning Scripting Information Request

Mhomar
Contributor

Hi All, I would like to introduces myself, and ask for advice related to
beginning scripting. My company just bought Casper Suite 7.3.1 and our
JumpStart is soon to be scheduled for probably around the beginning of
December. I am the lucky person to lead this effort! As I read through
many of the mailing list threads here, I noticed very quickly that I need to
learn Unix scripting NOW!. I have limited knowledge of Unix commands and
have been poking around the resource kit to familiarize myself with its
contents. I am ready and able to 'Take On' the terminal!

Will anyone take the time to point me to what you would believe to be a
beginning resource (Books and or websites) that would methodically lead me
down the correct path of learning the language as it related to Casper Suite
scripting? For instance, I am seriously looking at the Book titled 'Mac OS
X Command Line: Unix under the hood' good choice?

I realize this is a huge topic that many of you are passionate about and my
request could generate a lot of mail. So I apologize in advance for the
spam! I also realize this is not a small nor quick endeavor and will take a
huge commitment on my part!!! I am committed and looking for your help on
focusing my education.

Thanks!!!!

8 REPLIES 8

donmontalvo
Esteemed Contributor III

Along with Jared's suggestions, I would recommend "UNIX In A Nutshell". Make sure it's the 4th edition that references Mac OS X:

http://oreilly.com/catalog/9780596100292/

If your employer would let you, the CompTIA Linux+ class is worth every penny. Bootcamp style class, I remember the instructor was nice enough to let us surf the internet during breaks. The catch, you could only surf with a text based browser. That's right, the entire class was done without any GUI whatsoever. It was the best course I can remember. I was familiar with the shell from having to sift through logs and config files on the old Solaris servers (Xinet), but the course really opened my eyes and increased my confidence. Of course my eyes still get crossed when Steve W, Jared N, Thomas L, and the rest of the UNIX gurus toss Perl, Ruby, etc., at us. That's OK, at least I have a better understanding and can piece together stuff to make things happen (in a LAB environment first of course!).

Do

--
https://donmontalvo.com

John_Wetter
Release Candidate Programs Tester

Welcome to Casper Michael! I agree with the comments so far that it isn’t a necessity to come in knowing command line, but it really helps you understand how Casper does stuff and helps down the road. I don’t think you need it up front, but it’ll help later on! Along with the terminal, it might also be helpful to know some AppleScript to do UI scripting especially. A great book for that is AppleScript 1-2-3 by Sal Soghoian and Bill Cheeseman.

John

jarednichols
Honored Contributor

I'd recommend this one:http://www.amazon.com/Learning-bash-Shell-Programming-Nutshell/dp/0596009658/ref=sr_1_3?s=books&ie=UTF8&qid=1286994048&sr=1-3
Or this one: http://www.amazon.com/Classic-Shell-Scripting-Arnold-Robbins/dp/0596005954/ref=sr_1_1?s=books&ie=UTF8&qid=1286994085&sr=1-1

j
--
Jared F. Nichols
Desktop Engineer, Client Services
Information Services Department
MIT Lincoln Laboratory
244 Wood Street
Lexington, Massachusetts 02420
781.981.5436

Not applicable

Welcome, to the world of JAMF. You will enjoy the ride.

My 2 cents or "just one mans opinion from 5k aerial feet"

Don’t worry about the scripting too much right now. There will be plenty of meat to keep you full as you get used to using all of Casper's components.
There is a TON of work you can accomplish with out ever opening a terminal window. Once you get a good grasp on it all, then you can take it to the next level.

Nick Caro Senior Desktop Support Administrator

davelb20
New Contributor III

Also you might want to check out the free guides online as well.

http://tldp.org/LDP/abs/html/
http://www.linuxconfig.org/Bash_scripting_Tutorial

David Bruno
Security +, RHCT, CCNA, CCA
Computer Scientist
ARL/CISD
410-278-8929
david.bruno at us.army.mil

tlarkin
Honored Contributor

Michael,

Scripting is just the icing on the cake. You certainly do not need to
know it to use the Casper tools, however, knowing it allows you to do
pretty much anything you would need to do at your job. On top of that
Jamf does have their own set of command line binaries that make things a
lot easier. For example, if you wanted to manually create a user
account using dscl it would take you about 15 lines of code, where as
the jamf createUser command line can do it in about 2 (well one long
line) lines of code. So, starting with Casper should help you to ease
into the scripting world.

I am on my 4th year now of using Casper, and in the beginning I was a
mild shell script writer/user. Now, I do it for at least half of my
configurations. However, I am not your standard out-of-the-box user of
Casper either. Shell is my language of choice because it is the one I
know the most. However, you can just as easily use perl, python, ruby,
php, apple script, and so forth with Casper. You can pick your poison. I at times to invoke perl and python but I do mostly use shell. I
also sometimes use Applescript.

A previous email listed two of the major sites I taught myself from. I
also purchased some O'Rielly books on BASH, awk, and sed. I have yet
to actually buy a book specifically on shell scripting because I find
most online material just as good. Though, if you are used to a
classroom type learning session a book may be th way to go. It will be
more methodical than google and websites.

You'll find with Casper that the more you use it, the more you learn in
every aspect. Casper is something that is hard to describe. It is easy
to learn but can be tough to master in certain regards. My advice is,
go head first into your Jump Start. Then about 6+ months down the road
look into a CCA training course. This will help you more than you know. I used Casper for a year before I went to the training course and while
I did not learn all that much since I was using Casper for a full year,
however, the Jamf guys fixed a lot of bad habits I had developed over
the year. It will take you months of using it to get a full grasp of
everything it can do, because it can do a lot of things.

Welcome to Casper.

-Tom

Mhomar
Contributor

I would like to thank everyone for their input. I have been given some
sound advice and pointed to excellent resources. The best advice was, and I
paraphrase ' although scripting WILL be important in the future, chill out,
as the tools in the Casper suite will keep you very busy for a while to
come' that helped me to calm down a bit on the subject. I will be using a
online resource to start my scripting education sooner than later!

Again thanks for the input

tlarkin
Honored Contributor

Also, check out the resource kit. It contains a bunch of prebuilt
scripts from the Jamf staff that may fit a lot of your basic scripting
needs. Most of the time you can tweak those scripts to get what you
want. It also helps you learn syntax and commands. Then if you are
really in a jam just email the list and there is most likely one of us
who have done something similar in the past and can share our scripts.

You'll need at least 6 months working with Casper to really grasp
everything you can do with it. Like for example, I am a 4th year Casper
user now and I really don't ever use Casper Remote. Not that I don't
need it, but I just really don't use it. So, there are definitely
things I can still learn about Casper even after 4 years of using it.

After about 6 months have your work spring for the CCA course. At
that point you will be a Casper wizard.

-Tom