Post-imaging script

mbuckner
Contributor

I have a script that I want to run on all newly imaged computers and some computers that were imaged recently. Is there a way to set up an extension attribute or a smartgroup that will let me target just those computers?

Thanks!
Mark

6 REPLIES 6

jarednichols
Honored Contributor

To pre-empt some of this, we create a dummy receipt that is laid down. The name of the receipt is the version number of our standard image. That way, if we do find something wrong with it after it's been deployed, we have an easily scope-able thing to go by.

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

Walter
New Contributor II

Also, JSS Computer ID numbers are assigned serially. If these are all new machines that were deployed at the same time then you could create a smartgroup with the JSS Computer ID range and then apply a policy to that smart group.
--
Walter Rowe, System Hosting
Enterprise Systems / OISM
walter.rowe at nist.gov<mailto:walter.rowe at nist.gov>
301-975-2885

winkelhe
New Contributor

for the newly imaged just set your script to run at reboot and add it to the image. as for the others scope by anything different like jared said, maybe a software version or something.

![external image link](attachments/1c6e7c00495e4941a2f8e42025d7811d)
![external image link](attachments/a6e18463e8414518af184b5422822fda)

tlarkin
Honored Contributor

Well,

For post image scripts just add it into your work flow and set the script to run at reboot. As for running it on current machines in the field, you can scope it out by OS version, hardware configuration, or something unique that may make them stick out.

-Tom

jarednichols
Honored Contributor

What's special about these machines? That's what you're going to target so it helps to think of how you're going to differentiate those from the rest.

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

CasperSally
Valued Contributor II

I've ran into this where I found something I needed to fix on already imaged machines but then fixed it on image so machines imaged after didn't need it.

What I did was create a Temp department ( we don't use dept in JSS, so it's a dummy field) and did an advanced search on new OS version and added all those to that dummy dept and ran policy on that dept.

Then made change on image so any machines imaged after I created that dept would not need fix.

I guess this only works if your image had some change (for us, OS version) to search on though.