Top

Deploying Huntress with Ninja RMM

UPDATE 2021-02-22: Ninja introduced a new variable called $env:NINJA_ORGANIZATION_NAME that elements the need for our API. The new way is just a simple deployment script that needs to be set up in your Ninja RMM instance.

UPDATE 05/26/2020: Huntress has updated the NinjaRMM deployment script with the following enhancements: Forcing PowerShell to use TLS 1.2 or greater; this is part of our effort to phase out support for TLS 1.0/1.1. Improved validation that the agent installed properly and registered. Enhanced logging in case we need to help troubleshoot. Please update the PowerShell script created in Download, Edit, and Import the Huntress Deployment Script for NinjaRMM.

NinjaRMM provides the ability to create Scheduled Scripts to deploy third-party software. This document provides the instructions to add a Scheduled Script to your Policies to deploy the Huntress Agent to your customer's computers.

The Organization Name and Organization key will match the site name from NinjaRMM.

This guide is meant to provide a basic overview of deploying the Huntress Agent using NinjaRMM. We are not able to offer comprehensive support for NinjaRMM, please refer to the NinjaRMM documentation for full details regarding the usage of NinjaRMM policies and scheduled scripts.

NOTE:  If you've used the previous version of this script where the organization keys were not automatically pulled from NinjaRMM, a duplicate organization may be created if there is a name mismatch. To correct this, move the agents from the old organization into the new one matching the site name in NinjaRMM and delete the old organization from the Huntress console. 


1
Retrieve Your Huntress Account Key
2
Download, Edit, and Import the Huntress Deployment Script for NinjaRMM
3
Add a Scheduled Script to Your Policy

Retrieve Your Huntress Account Key

  1. Login to the Huntress Web Interface.
  2. Hover over the Huntress options menu in the upper-right corner of the dashboard.
  3. Select the "Download Agent" option from the menu.
  4. On the Installer page click the clipboard icon to copy your secret account key to your clipboard.

Download, Edit, and Import Huntress Deployment Script

  1. Download our PowerShell Deployment Script
  2. In your NinjaRMM dashboard, click on "Configuration" in the left-hand menu.
  3. Click on "Scripting"
  4. Click on "Create New Script" in the upper right-hand area.
  5. Paste the entire PowerShell script from step 1 into the left-hand pane. Scroll down to around line 47 and paste your Huntress account secret key over the __ACCOUNT KEY__ text in the script. Scroll down to around line 50 and paste $env:NINJA_ORGANIZATION_NAME over the __ORGANIZATION KEY__ text in the script. 
    Note: It is important that your script matches. 

  6. Fill out the form on the right-hand pane with a name, description, category, scripting language, operating system, and architecture as shown below. You may set custom values for name, description, and category, but the language must be PowerShell and Architecture must be set to All
  7. Click the "save" button in the upper-right corner of the script editor.

Add a Scheduled Script to Your Policy

NOTE: This section is provided as a general guideline. You may wish to add the Huntress script to one or more custom policies in your deployment. We are not able to offer comprehensive support for NinjaRMM, please refer to the NinjaRMM documentation for full details regarding the usage of NinjaRMM policies and scheduled scripts.

  1. Log in to NinjaRMM.
  2. Navigate to the policy you want to use to install the Huntress Agent by clicking configuration, policies, and the policy name. Alternatively, you can create a new policy. In this example, we're using the "Windows Workstation" policy.
  3. Click on the Scheduled Scripts menu in the left and then Add a scheduled Script on the right.
  4. In the Scheduled Script window choose an appropriate name and description for the script. Set the Schedule and Notification preferences to your preferred settings. Click the "Add Script" button. 
  5. Navigate to the category you set for your script in Step 6 of the previous section and click on the script to import it into the schedule. 
  6. Leave the "Preset Parameter" field blank and leave "Run As" set to "System", and click Apply
  7. This will close the parameter window. Now click "Add" to add the script to the schedule. 
  8. Click "Save" in the upper right hand corner. You are now ready to deploy the Huntress Agent via NinjaRMM! 
Did this answer your question? Thanks for the feedback There was a problem submitting your feedback. Please try again later.

Need help? Click here to Contact Us Click here to Contact Us