Smart Groups based on Custom Plugins?

jaugust
New Contributor III

Hi everyone, I've recently inherited a JSS, and they have configuration profiles and policies go to certain smart groups. The criteria for these smart groups is based on if the machine has a specific plug-in. I need to create a new plug-in, but I'm not sure if I'm doing it the right way (I'm doing a touch command to write the plug-in to /Library/Internet Plug-Ins/nameofiplugin.plugin.

I can successfully create a zero kb plugin file, however I can't get it to appear as a criteria option in the JSS. The previously created ones are under that however...

1 ACCEPTED SOLUTION

jaugust
New Contributor III

Referencing this solved it. It isn't an EA, rather, after placing that item on my machine, and running recon, the JSS updated to reflect this as a valid plug-in option.

https://www.jamf.com/jamf-nation/discussions/5800/smart-group-membership-based-on-existence-of-a-local-file

View solution in original post

3 REPLIES 3

tomhastings
Contributor II

It sounds like the previous admin may have created an extension attribute based on the other plug-ins. Check to see if there are any extension attributes that are related to the plug-ins that do function.

ryan_ball
Valued Contributor

You'd have to create an extension attribute, which would be based on a script and look like this:

#!/bin/bash

plugin=/Library/Internet Plug-Ins/nameofiplugin.plugin

if [[ -e "$plugin" ]]; then
    echo "<result>Installed</result>"
else
    echo "<result>Not Installed</result>"
fi

exit 0

Then your smart group would be "name of EA" equals "Installed".

jaugust
New Contributor III

Referencing this solved it. It isn't an EA, rather, after placing that item on my machine, and running recon, the JSS updated to reflect this as a valid plug-in option.

https://www.jamf.com/jamf-nation/discussions/5800/smart-group-membership-based-on-existence-of-a-local-file