Nexthink Collector Deployment

adm-laurf
New Contributor

Dear All, i have trouble deploying Nexthink collector though JAMF.

I have re-package the 'Nexthink collector' installer using "composer",

I do not have any error on deloyment but we lack files.

Does anyone of you know a proper way to deploy the Nexthink collector with Jamf?

6 REPLIES 6

allanp81
Valued Contributor

Yes, it's simple. You need the installer but in our case we also needed a root ca txt file and also a customer key text file. You then distribute the package with a post install command that runs something like:

cd Nexthink_collector_6.1.1.1/csi.app/Contents/Macos
./csi -address serveraddress -port 999 -tcp_port 999 -rootca /path/to/txtfile -key /path/to/txtfile

adm-laurf
New Contributor

Fantastic, thanks for your help. It is working now

Surajit
New Contributor III

Just wanted to share what we are douing, hope it might help someone.
We package the Nexthink_Collector installer, RootCA & Customer Key & place it in /private/tmp/
Below is the Installation Script:

#!/bin/sh
#Description: Script to install the Nexthink Collector form the pre-cached dmg installer file, Root CA & Customer Key.

# Variables used by this script.
dmgName="Nexthink_Collector.dmg"

# CHECK TO SEE IF A VALUE WERE PASSED IN Jamf FOR PARAMETER 4 AND ASSIGN THEM
if [ "$4" != "" ] && [ "$dmgName" == "" ]; then
    dmgName="$4"
fi

# Mount the DMG
/usr/bin/hdiutil attach /private/tmp/Nexthink_Collector/$dmgName -noverify -nobrowse -noautoopen

# Change the directory to the path of the csi application:
cd /Volumes/Nexthink_Collector_6.23.1.9 OSX 10.12 - 10.15/csi.app/Contents/MacOS/

# Define the parameters for csi.app for installing the Collector from the command line interface
sudo ./csi -address x.x.x.x 
-port xxx -tcp_port xxxx 
-rootca /private/tmp/Nexthink_Collector/Nexthink-root-ca.txt -key /private/tmp/Nexthink_Collector/Nexthink-customer-key.txt 
-campaign enabled

# Unmount the DMG
hdiutil detach /Volumes/Nexthink_Collector_6.23.1.9 OSX 10.12 - 10.15/ -force

# Delete the package contents
/bin/rm -rf /private/tmp/Nexthink_Collector/

And here goes the EA:

#!/bin/bash
#Description: Extension Attribute to report the installed version of the Nexthink agent, or Not Installed.

if [ -f "/Library/Application Support/Nexthink/config.json" ]; then
    VERSION=$( /bin/cat /Library/Application Support/Nexthink/config.json | grep -i version | cut -d '"' -f4 )
else
    VERSION="Not Installed"
fi
echo "<result>$VERSION</result>"

walt
Contributor III

@Surajit Did you repackage the DMG for nexthink? or curious how the DMG was deployed to the /private/tmp/?

do you have a separate pkg with the rootca and customer key?

Thank you

Surajit
New Contributor III

Yes, @walt I repackaged the source DMG, rootca and customer key using Composer as one package.

walt
Contributor III

@Surajit okay and that was a flat pkg? and the script above is a postinstall script?

thank you in advance for the clarification!

edit: think I got it, I used a flat package and that seemed to work with our version on 10.15, but if there is a better method I am still curious. thank you again