Onboarding

Script library

Enlist's own scripts for everyday fixes and checks on Windows and Mac, ready for blueprints and the Terminal.

The script library is Enlist's own set of 81 scripts for the fixes and checks MSPs run every day: disk space, network, Windows Update, printing, security baselines, accounts and more. Enlist wrote every one of them, and each is listed with exactly what it changes.

Use a library script #

  1. In a blueprint: add a Run a script step, pick Start from the script library and choose a script. Its parameters are filled in with their defaults; change them in the step.

  2. As a ready check: scripts marked check exit 0 when all is well, so they also work in a Check item with My own script.

  3. On one device: in the device's Terminal, pick Script library, choose a script, fill in its parameters and run it.

How library scripts stay trustworthy #

Each script ships inside the Enlist server with its SHA-256 pinned in the catalog; the server won't start if a script's bytes don't match. A step or a Terminal run shows From the script library, unchanged while the text still matches. And like any script, a library script runs on a device only after a passkey signs exactly that text: the admin passkeys that publish a blueprint, or your own passkey in the Terminal. The device checks that signature itself.

Parameters reach scripts as environment variables, never pasted into the script. Exit code 0 means done (or, for a check, all is well); 1 means it failed or found a problem; 2 means a parameter was wrong.

Install keys for security tools #

The Install scripts for security tools (Huntress, SentinelOne, ThreatLocker, CrowdStrike, Sophos, Bitdefender, Defender for Endpoint and Todyl) need each client's own key, token or installer link. Those are install keys: you set them once on the client (or for all clients), and Enlist seals each device's value to that device when the step runs. They are never in the blueprint, so one blueprint serves every client.

Windows scripts (PowerShell, run as SYSTEM) #

ScriptWhat it doesParameters
Battery health
win-battery-report
What the battery holds against new, and its charge cycles.
Diagnostics, read-only, check
WARN_HEALTH_PERCENT (60)
Disk space report
win-disk-space
Free space on every disk and the folders that usually fill up, largest profiles first.
Diagnostics, read-only, check
WARN_PERCENT (10)
Domain and Entra join status
win-join-status
Entra, Active Directory, hybrid or workgroup, and whether the domain trust works.
Diagnostics, read-only, check
none
Is a restart pending?
win-pending-reboot
Whether Windows waits for a restart, and why (updates, servicing, renames).
Diagnostics, read-only, check
none
Recent errors and crashes
win-recent-errors
The most frequent errors in the System and Application logs, unexpected shutdowns and blue screens.
Diagnostics, read-only
HOURS (24)
System summary
win-system-summary
Model, serial number, Windows version, CPU, memory, disks, uptime and who is signed in.
Diagnostics, read-only
none
BitLocker status
win-bitlocker-status
Encryption, protection and key protectors on every fixed drive, and the TPM.
Security, read-only, check
none
Block or allow USB drives
win-usb-storage
Blocks USB flash drives and external disks (keyboards and mice keep working), or allows them again.
Security, changes the device
ACTION (block)
Defender scan
win-defender-scan
Updates Defender signatures, scans, and lists anything it found.
Security, changes the device, check
SCAN_TYPE (quick)
Defender status
win-defender-status
Defender mode, real-time and tamper protection, signature age, last scans and any other antivirus.
Security, read-only, check
MAX_SIGNATURE_DAYS (3)
Firewall status
win-firewall-status
Windows Firewall on or off for each profile, and which network uses which.
Security, read-only, check
none
Install Bitdefender GravityZone
win-install-bitdefender
Installs Bitdefender from this client's GravityZone installation package link.
Security, changes the device
BITDEFENDER_WINDOWS_INSTALLER_URL (install key)
Install CrowdStrike Falcon
win-install-crowdstrike
Installs the Falcon sensor from your hosted installer under this client's customer ID.
Security, changes the device
CROWDSTRIKE_CID (install key), CROWDSTRIKE_WINDOWS_INSTALLER_URL (install key), INSTALLER_SHA256, GROUPING_TAGS
Install Huntress
win-install-huntress
Installs the Huntress agent into this client's organization, or reports it when it already runs.
Security, changes the device
HUNTRESS_ACCOUNT_KEY (install key), HUNTRESS_ORGANIZATION_KEY (install key), TAGS
Install SentinelOne
win-install-sentinelone
Installs the SentinelOne agent from your hosted installer into this client's site.
Security, changes the device
SENTINELONE_SITE_TOKEN (install key), SENTINELONE_WINDOWS_INSTALLER_URL (install key), INSTALLER_SHA256
Install Sophos Endpoint
win-install-sophos
Installs Sophos Endpoint from this client's Sophos Central installer link.
Security, changes the device
SOPHOS_WINDOWS_INSTALLER_URL (install key), DEVICE_GROUP
Install ThreatLocker
win-install-threatlocker
Installs the ThreatLocker agent with ThreatLocker's stub installer into this client's computer group.
Security, changes the device
THREATLOCKER_INSTALL_KEY (install key), STUB_URL (https://api.threatlocker.com/updates/installers/threatlockerstubx64.exe)
Install Todyl SGN Connect
win-install-todyl
Installs Todyl SGN Connect with the deployment key of this client's Todyl policy.
Security, changes the device
TODYL_DEPLOY_KEY (install key)
Onboard to Defender for Endpoint
win-onboard-defender
Onboards the PC to Microsoft Defender for Endpoint in this client's tenant, from its onboarding package.
Security, changes the device
DEFENDER_ONBOARDING_PACKAGE_URL (install key), PACKAGE_SHA256
Security baseline check
win-security-check
PASS or FAIL for firewall, Defender, BitLocker, Secure Boot, TPM, UAC, SMBv1, LLMNR, WDigest, AutoRun, Guest and RDP.
Security, read-only, check
none
Turn Remote Desktop on or off
win-remote-desktop
Remote Desktop on with Network Level Authentication and its firewall rules, or off.
Security, changes the device
ACTION (required)
Turn the firewall on
win-firewall-on
Turns Windows Firewall on for every profile, blocking unsolicited inbound traffic.
Security, changes the device
none
Flush DNS
win-flush-dns
Clears the DNS cache and registers the PC in DNS again.
Network, changes the device
none
Network check
win-network-check
Adapters, addresses, gateway, DNS and an HTTPS connection, bottom up.
Network, read-only, check
TEST_NAME (www.microsoft.com)
Reset the network stack
win-reset-network
Resets Winsock and TCP/IP and clears DNS; needs a restart, which it can schedule. Refuses on static addresses unless told.
Network, changes the device, can restart
RESTART (no), RESET_STATIC (no)
Test a connection to a server
win-test-connection
Checks whether the PC can reach a server on a TCP port.
Network, read-only, check
TARGET_HOST (required), TARGET_PORT (required)
Disable or enable a local account
win-disable-user
Disables a leaver's local account or the built-in Administrator, or enables one again.
Accounts, changes the device
ACCOUNT_NAME (required), ACTION (disable)
Local accounts and administrators
win-local-users
Local accounts with last sign-in and password age, and everyone in the Administrators group.
Accounts, read-only
none
Remove a local administrator
win-remove-admin
Takes an account out of local Administrators; refuses to leave no other administrator.
Accounts, changes the device
ACCOUNT_NAME (required)
Clear the Teams cache
win-clear-teams-cache
Closes Teams and clears its cache (classic and new Teams) for the signed-in people or one person.
Apps, changes the device
ACCOUNT_NAME
Install DWG TrueView 2027
win-install-dwg-trueview
Installs Autodesk DWG TrueView 2027 (English) from Autodesk's pinned 2 GB archive, checking its hash and Autodesk's signature.
Apps, changes the device
none
Installed apps
win-installed-apps
Every installed app with version, publisher and install date, for everyone and for signed-in people.
Apps, read-only
FILTER
Uninstall an app
win-uninstall-app
Silently uninstalls an app by name: MSI apps with msiexec, others only with a quiet uninstall command.
Apps, changes the device
APP_NAME (required), ALL_MATCHES (no)
Reset Windows Update
win-reset-windows-update
Stops Windows Update, sets aside its cache and catalog, starts it again and asks for a scan.
Updates, changes the device
none
Update all apps with winget
win-winget-upgrade-all
Updates every app winget can update, silently, as SYSTEM.
Updates, changes the device
none
Windows Update history
win-update-history
The latest Windows updates with their result, and when Windows last checked and installed.
Updates, read-only
COUNT (25)
Apply Group Policy now
win-group-policy-update
gpupdate for the computer, without restarting, and the policies that apply.
Maintenance, changes the device
none
Clear temp files
win-clear-temp
Deletes old temp files (Windows' and every profile's), error reports and crash dumps; can empty the Recycle Bins.
Maintenance, changes the device
DAYS (7), EMPTY_RECYCLE_BIN (no)
Repair Windows system files
win-repair-system-files
DISM RestoreHealth, then System File Checker. Restart afterwards if files were fixed.
Maintenance, changes the device, can restart
none
Restart a service
win-restart-service
Restarts a service and its dependents; refuses Windows' core services and Enlist's agent.
Maintenance, changes the device
SERVICE_NAME (required)
Restart with a warning
win-restart-later
Restarts after a warning the person sees, or cancels a restart that is counting down.
Maintenance, changes the device, can restart
ACTION (restart), MINUTES (15), MESSAGE
Shrink the component store
win-component-cleanup
Removes superseded update files from WinSxS (DISM StartComponentCleanup).
Maintenance, changes the device
none
Sync the clock
win-sync-time
Syncs the clock now; a workgroup PC with no time source gets time.windows.com.
Maintenance, changes the device
none
Add a network printer
win-add-printer
Adds a printer by IP address or host name for everyone on the PC.
Printing, changes the device
PRINTER_NAME (required), PRINTER_ADDRESS (required), DRIVER_NAME (Microsoft PCL6 Class Driver)
Fix stuck printing
win-fix-print-spooler
Stops the Print Spooler, deletes stuck jobs, starts it again and lists the printers.
Printing, changes the device
none
Set the time zone
win-set-time-zone
Sets the time zone and turns off automatic time zone.
Settings, changes the device
TIME_ZONE (required)
Sleep and screen settings
win-power-settings
When the screen turns off and the PC sleeps, plugged in and on battery; can turn Fast Startup off.
Settings, changes the device
SLEEP_PLUGGED_IN (0), SLEEP_ON_BATTERY (30), SCREEN_PLUGGED_IN (15), SCREEN_ON_BATTERY (10), FAST_STARTUP (unchanged)

Mac scripts (zsh, run as root unless noted) #

ScriptWhat it doesParameters
Battery health
mac-battery-health
The battery's condition, maximum capacity and charge cycles.
Diagnostics, read-only, check
none
Disk space report
mac-disk-space
Free space and the folders that usually fill up, per home folder.
Diagnostics, read-only, check
WARN_PERCENT (10)
MDM enrollment status
mac-mdm-status
Whether and how the Mac is enrolled in an MDM, its server, and the configuration profiles.
Diagnostics, read-only, check
none
System summary
mac-system-summary
Model, chip, serial number, macOS version, memory, disk, uptime and who is signed in.
Diagnostics, read-only
none
Install CrowdStrike Falcon
mac-install-crowdstrike
Installs the Falcon sensor from your hosted package and licenses it with this client's customer ID.
Security, changes the device
CROWDSTRIKE_CID (install key), CROWDSTRIKE_MAC_INSTALLER_URL (install key), INSTALLER_SHA256, GROUPING_TAGS
Install Huntress
mac-install-huntress
Installs the Huntress agent into this client's organization; its system extension needs Huntress's MDM profile or someone's approval.
Security, changes the device
HUNTRESS_ACCOUNT_KEY (install key), HUNTRESS_ORGANIZATION_KEY (install key), SYSTEM_EXTENSION (yes)
Install SentinelOne
mac-install-sentinelone
Installs the SentinelOne agent from your hosted package into this client's site.
Security, changes the device
SENTINELONE_SITE_TOKEN (install key), SENTINELONE_MAC_INSTALLER_URL (install key), INSTALLER_SHA256
Install Sophos Endpoint
mac-install-sophos
Installs Sophos Endpoint from this client's Sophos Central installer link.
Security, changes the device
SOPHOS_MAC_INSTALLER_URL (install key)
Install ThreatLocker
mac-install-threatlocker
Downloads ThreatLocker for Mac with this client's group install key and starts it.
Security, changes the device
THREATLOCKER_INSTALL_KEY (install key)
Install VeraCrypt
mac-install-veracrypt
Installs macFUSE, then VeraCrypt; says when macFUSE's extension waits for an MDM profile or the person.
Security, changes the device
MACFUSE_DMG_URL (https://github.com/macfuse/macfuse/releases/download/macfuse-5.5.0/macfuse-5.5.0.dmg), MACFUSE_SHA256 (92c21ef2db4199bcf5bddc8e6efb57b23ecb9715f74ab38cba2c77ab226d3830), VERACRYPT_DMG_URL (https://github.com/veracrypt/VeraCrypt/releases/download/VeraCrypt_1.26.31/VeraCrypt_1.26.31.dmg), VERACRYPT_SHA256 (a596f2e5cd43fd8e1a343a1e85869b9d72c4244206b511724455d02297d12290)
Install Zscaler Client Connector
mac-install-zscaler
Installs Zscaler Client Connector from your hosted installer, set to this client's cloud and domain.
Security, changes the device
ZSCALER_MAC_INSTALLER_URL (install key), ZSCALER_CLOUD_NAME (install key), ZSCALER_USER_DOMAIN (install key), TEAM_ID
Onboard to Defender for Endpoint
mac-onboard-defender
Installs Microsoft Defender and onboards the Mac to Defender for Endpoint in this client's tenant.
Security, changes the device
DEFENDER_MAC_ONBOARDING_PACKAGE_URL (install key), PKG_URL (https://go.microsoft.com/fwlink/?linkid=2097502)
Security baseline check
mac-security-check
PASS or FAIL for FileVault, firewall, SIP, Gatekeeper, automatic updates and the guest account; sharing services listed.
Security, read-only, check
none
Turn the firewall on
mac-firewall-on
Turns on the application firewall, and optionally stealth mode.
Security, changes the device
STEALTH (no)
Flush DNS
mac-flush-dns
Clears the DNS cache.
Network, changes the device
none
Network check
mac-network-check
Connection, address, router, DNS and HTTPS, bottom up.
Network, read-only, check
TEST_NAME (www.apple.com)
Test a connection to a server
mac-test-connection
Checks whether the Mac can reach a server on a TCP port.
Network, read-only, check
TARGET_HOST (required), TARGET_PORT (required)
Local accounts and administrators
mac-local-users
Accounts with admin or standard role, secure token and last login.
Accounts, read-only
none
Remove an administrator
mac-remove-admin
Makes an account standard; refuses to leave no other administrator.
Accounts, changes the device
ACCOUNT_NAME (required)
Install Adobe Acrobat
mac-install-acrobat-pro
Installs Adobe Acrobat from Adobe's installer; people license it by signing in with their Adobe ID.
Apps, changes the device
DMG_URL (https://trials.adobe.com/AdobeProducts/APRO/Acrobat_HelpX/osx10/Acrobat_DC_Web_WWMUI.dmg), INSTALLER_SHA256
Install Adobe Creative Cloud
mac-install-creative-cloud
Installs the Creative Cloud desktop app silently; people sign in to install their Adobe apps.
Apps, changes the device
DMG_URL (https://ccmdls.adobe.com/AdobeProducts/StandaloneBuilds/ACCC/ESD/6.11.0/478.6/macarm64/ACCCx6_11_0_478_6.dmg), INTEL_DMG_URL (https://ccmdls.adobe.com/AdobeProducts/StandaloneBuilds/ACCC/ESD/6.11.0/478.6/osx10/ACCCx6_11_0_478_6.dmg)
Install Backblaze Computer Backup
mac-install-backblaze
Installs Backblaze and adds the person signed in to the Mac to your Backblaze group as short-name@domain.
Apps, changes the device
BACKBLAZE_GROUP_ID (install key), BACKBLAZE_GROUP_TOKEN (install key), DMG_URL (https://secure.backblaze.com/api/install_backblaze?file=bzinstall-mac-10.0.4.1082.dmg), EMAIL_DOMAIN (required)
Install Logi Options+
mac-install-logi-options-plus
Installs Logitech's Logi Options+ for Logitech mice and keyboards, silently.
Apps, changes the device
ZIP_URL (https://download01.logi.com/web/ftp/pub/techsupport/optionsplus/logioptionsplus_installer.zip)
Install TeamViewer Host
mac-install-teamviewer-host
Installs TeamViewer Host for unattended access and assigns it to your TeamViewer account.
Apps, changes the device
DMG_URL (https://download.teamviewer.com/download/version_15x/TeamViewerHost.dmg), ASSIGNMENT_ID
Install VMware Fusion
mac-install-vmware-fusion
Installs VMware Fusion from your hosted copy of Broadcom's disk image and sets it up; no license key needed.
Apps, changes the device
VMWARE_FUSION_DMG_URL (install key), TEAM_ID (EG7KH642X6)
Install Zoom Rooms
mac-install-zoom-rooms
Installs Zoom Rooms on a room Mac; sign it in with an activation code or Zoom Device Management.
Apps, changes the device
PKG_URL (https://zoom.us/client/latest/ZoomRooms.pkg)
Installed apps
mac-installed-apps
Apps in /Applications and in each ~/Applications, with version and bundle ID.
Apps, read-only
FILTER
Install Apple updates
mac-install-updates
Installs missing Apple updates; macOS upgrades on Apple silicon may still need a person or the MDM.
Updates, changes the device, can restart
RESTART (no)
Missing Apple updates
mac-update-list
Which macOS and Apple updates the Mac is missing, and what installed recently.
Updates, read-only, check
none
Clear the person's caches
mac-clear-user-caches
Runs as the signed-in person and deletes their old app caches.
Maintenance, changes the device, runs as the signed-in person
DAYS (7)
Rebuild Spotlight
mac-rebuild-spotlight
Erases and rebuilds the Spotlight index of the startup disk.
Maintenance, changes the device
none
Restart with a notice
mac-restart-later
Restarts after a notice to the person, or cancels a restart that is counting down.
Maintenance, changes the device, can restart
ACTION (restart), MINUTES (15), MESSAGE
Sync the clock
mac-sync-time
Syncs the clock now and keeps network time on.
Maintenance, changes the device
TIME_SERVER (time.apple.com)
Fix stuck printing
mac-clear-print-queue
Cancels waiting jobs, resumes paused printers and restarts printing.
Printing, changes the device
none

Last updated 2026-11-15. Something wrong or missing? Email [email protected].