A custom bash script can be a great option for deploying apps that have standard .pkg
files and do not require KEXT (kernel extension whitelisting). To do this:
1. Host your .pkg file in a web server (i.e. Amazon AWS, etc.)
2. Write a script that downloads/installs the .pkg.
3. Log into the Fleetsmith web app, and use the "Custom Bash Script" tool (offered in "Apps & Settings") to deploy it.
Example script:
Here's an example script that would download and install a .pkg
file. In this example the .pkg
file would be hosted on Amazon AWS. Please modify it to your specific needs.
⚡️ IMPORTANT! ⚡️ Custom scripts are powerful tools. Make sure to extensively test your script in a safe, isolated environment, and deploy only the final production version via Fleetsmith.
#!/bin/bash
# Note, this script is an example of how to download and install
# custom installer packages. The example uses a pkg installer; DMGs
# or other formats would require modifying the script below.
# For production use, you'll want to ensure you add authentication,
# consistency checking, signature verification, error handling, etc.
# vars
remote_pkg="https://aws-zone.amazonaws.com/bucket/path/to/your/installer.pkg"
local_pkg="/tmp/installer.pkg"
# download package
/usr/bin/curl -L $remote_pkg -o $local_pkg
# install package
/usr/sbin/installer -target / -pkg $local_pkg