macadmins / outset

Automatically process packages and scripts during boot, login, or on demand.
Apache License 2.0
150 stars 11 forks source link

Service status Jamf Pro extension attribute #48

Closed ghost closed 6 months ago

ghost commented 6 months ago

I made a quick script to get the status of Outset and return it as an extension attribute. I'm using this alongside a smart group to determine if any services are somehow disabled by a local user.

bartreardon commented 6 months ago

While this will tell you the state of the services it's a bit raw. Could we consider cleaning it up into a "Healthy/Not Healthy" type status instead?

e.g. if any of the agents return something other than Enabled then the EA will indicate it with a simple value, rather than show the raw output of --service-status.

ghost commented 6 months ago

The script now counts the number of enabled services, which should equal 6. If all services are enabled it will report "Healthy" otherwise it will return "Not Healthy"

bartreardon commented 6 months ago

nice - yeah, we can assume that all 6 need to be loaded for "healthy". If an admin has different needs for their environment they can craft their own EA 🙂