Step 1:

  • Launch NinjaRMM and navigate to your NinjaRMM dashboard, and then navigate to Policies

Step 2:

  • If you have not created a policy to install third-party application installers, then create a new policy otherwise create a new Scheduled Script. In this case, it can be called CyberSmart Installer. It Only needs to run once.

Step 3:

  • Click on Add script, select Install Application from the list, then check the Upload File checkbox then click on the "Choose a File" space, locate the CyberSmart.msi file downloaded earlier then click upload. 
  • Next, set the Name to CyberSmart.msi and set Run As to System then click Apply 

NOTE: Upon uploading CyberSmart.msi, Ninja RMM will automatically create the URL needed for the MSI URL field

Step 4:

This step is optional but if you want the application to startup after being deployed, continue, otherwise skip to Step 6. Create a new Script, Run Application from the scripts list.

  • Set the Name to CyberSmart
  • Set Path to "%windir%\System32\cmd.exe" without quotes
  • Set Parameters to "/c /min echo %PROCESSOR_ARCHITECTURE% | findstr 64 && "%ProgramFiles(x86)%\CyberSmart\CyberSmart.exe" || "%ProgramFiles%\CyberSmart\CyberSmart.exe" without quotes
  • Set Run as Current User
  • Click Apply

Step 5:

  • When done, click Save. Depending on how the policies are managed/applied, you may not need to do this step. 
  • Select the group of computers intended to have CyberSmart Installed and apply the policy created.

Deploying to Individual Computers

  • When deploying to individual computers via the Search tab, only Step 4 from above is necessary here. 

Using a script

Requirements

  • Powershell 2.0 or above
  1. From the main dashboard, select Configuration
  2. Select Scripting
  3. Select Create New Script in the top right

4. Copy and paste the following as a PowerShell script

$URL = "<CyberSmart app URL>"

$REINSTALL = $false;

 

$TEMPLOCATION = "$env:TMP\\CyberSmart-installer.msi"

$LOG = "$env:TMP\\CyberSmart-installer.log"

$CyberSmartPath = "$env:ProgramFiles\\CyberSmart\\CyberSmart.exe"

 

$currentPrincipal = New-Object Security.Principal.WindowsPrincipal([Security.Principal.WindowsIdentity]::GetCurrent());

$isElevated = $currentPrincipal.IsInRole([Security.Principal.WindowsBuiltInRole]::Administrator);

 

if((gwmi win32_operatingsystem | select osarchitecture).osarchitecture -eq "64-bit"){

    $CyberSmartPath = "$env:ProgramFiles(x86)\\CyberSmart\\CyberSmart.exe"

}

 

if(([System.IO.File]::Exists($CyberSmartPath) -eq $true) -and ($REINSTALL -eq $false)){

    write-host "CyberSmart is already installed on this machine($env:COMPUTERNAME). Use 'REINSTALL = true' to re-install";

    exit 1;

}else{

    if($isElevated -eq $false){

        write-host "Process unable to continue without being elevated to install MSI";

        exit 1;

    }

    write-host "Downloading"

    $wc = New-Object System.Net.WebClient

    $wc.DownloadFile($URL, $TEMPLOCATION)

    write-host "Installing"

    Msiexec /i $TEMPLOCATION /quiet /qn /norestart /log $LOG

}


5. Replace <CyberSmart app URL> with the download link of the CyberSmart MSI file from the CyberSmart web dashboard(https://download.cybersmart.co.uk/oelt37bavohs8z)

6. In the right pane,

  • Set Name to "Install CyberSmart
  • Set Description to "CyberSmart PowerShell installer" or leave blank
  • Set Category to the category that makes the most sense(Software), is this guide, we are using Uncategorized as this is the default
  • Set Language to PowerShell
  • Leave Operating System and Architecture as is
  • Leave Parameters blank

7. Click Save then Close
8. Additionally, a script to run the app can also be created here.
9. Select Create New Script again and paste the following:

run cybersmart

if((gwmi win32_operatingsystem | select osarchitecture).osarchitecture -eq "64-bit"){

    Start-process -filepath "${env:ProgramFiles(x86)}\\CyberSmart\\CyberSmart.exe";

}else{

  Start-process -filepath "${env:ProgramFiles}\\CyberSmart\\CyberSmart.exe";

}


10. In the right pane,

  • Set Name to "Run CyberSmart"
  • Set Description to "Run CyberSmart app" or leave blank
  • Set Category to the category that makes the most sense(Software), is this guide, we are using Uncategorised as this is the default
  • Set Language to PowerShell
  • Leave Operating System and Architecture as is
  • Leave Parameters blank

11. Click Save then Close

Selecting computers


In the Groups tab, select the group of computers or select each computer individually, select Run and then Script library. Type Install CyberSmart to find the script just created. Check Run As System then click Apply.

Assigning script to existing policy

Follow steps 1- 2 in Deployment

  1. From here, select the "Install CyberSmart" script.
  2. Check Run As System
  3. Click Apply
  4. Additionally, if you already create the script to run the app after the first install and would like to include it here, you can
  5. Select "Run CyberSmart"
  6. Check Run As Current User
  7. Click Apply

Done! 🎉

Did this answer your question?