Install the Backblaze Client with Addigy
- Print
- DarkLight
Install the Backblaze Client with Addigy
- Print
- DarkLight
Article summary
Did you find this summary helpful?
Thank you for your feedback
Addigy is a device management platform (for macOS and iOS) that allows you to push custom software, scripts, and policies, as well as manage endpoints.
Create Addigy Variables
Add a variable to use pre-configured values and secrets across Addigy. For more information, see Addigy Variables.
Before you begin: Locate your GroupID and GroupAuthenticationToken values.
- Sign in to the Addigy console.
- On the left sidebar, select Catalog.
- Select the Variables tab.
- Create a variable for your Group ID.
- Click New.
- In the Key field, enter groupID.
- In the Default Value field, enter your GroupID value.
- Click Save.
- Create a variable for your Group Authentication Token.
- Click New.
- In the Key field, enter groupToken.
- In the Default Value field, enter your GroupAuthenticationToken value.
- Click Save.
Create a Smart Software Item
Before you begin: Download the Backblaze Installer .dmg file: https://secure.backblaze.com/mac/install_backblaze.dmg.
- On the left sidebar, select Catalog.
- Select Software, and select the Smart Software tab.
- Click New.
- Enter a name (for example, Backblaze Backup).
- Upload the installer, and add an installation command.
- Click Select File(s).
- Upload your .dmg file.
- In the Install Command section, click Add.
- Enter the following command using the variables you created in the last task:
# The Backblaze email associated with deployment email="[email protected]" # Group ID for Group user is/will part of group_id='$groupID' # Group Token group_token='$groupToken' /usr/bin/hdiutil attach -nobrowse "/Library/Addigy/ansible/packages/Backblaze (5.0.0)/install_backblaze.dmg" "/Volumes/Backblaze Installer/Backblaze Installer.app/Contents/MacOS/bzinstall_mate" -nogui bzdiy -signin "${login}" "${password}" /usr/sbin/diskutil unmount "/Volumes/Backblaze Installer"
- Add a condition for install.
- Open Condition for Install, and enter the following command:
if [ -e "/Library/Backblaze.bzpkg/bztransmit" ]; then echo "Backblaze already installed. Not installing" exit 1 else echo "Backblaze not installed. Attempting to install now..." exit 0 fi
- Ensure that Install if return value is 0 is enabled.
- Open Condition for Install, and enter the following command:
- (Optional) Add a removal script if you want Backblaze to be removed when you delete the Smart Software from a policy.
- In the Removal Command section, enter the following command:
Click here to open.
# Copyright (c) 2007-2010 Backblaze Inc. All rights reserved. # # Shout out to Adam Fisk for writing about AppleScript uninstallers! function die { echo $* exit 1 } function remove { rm -r "$1" || die "Could not remove file: $1" } function shutdown_bzserv { local output=`ps -cA | grep bzserv` local bz_plist='/Library/LaunchDaemons/com.backblaze.bzserv.plist' if [ -n "$output" ] then test -f $bz_plist && launchctl unload $bz_plist test -f $bz_plist && remove $bz_plist else if [ -f $bz_plist ] then remove $bz_plist fi fi } function clean_library_backblaze { local bz_pkgs='/Library/Backblaze.bzpkg' local bz_apps='/Library/Backblaze' if [ -d $bz_apps ] then remove $bz_apps fi if [ -d $bz_pkgs ] then remove $bz_pkgs fi } function clean_system_preferences_backblaze { local bz_pref_pane='/Library/PreferencePanes/BackblazeBackup.prefPane' if [ -d $bz_pref_pane ] then remove $bz_pref_pane fi } function clean_applications_backblaze { local bz_app='/Applications/Backblaze.app' if [ -d $bz_app ] then remove $bz_app fi } function clean_misc { local bz_extbx="/Library/Application Support/ExtBX" if [ -d "$bz_extbx" ] then remove "$bz_extbx" fi } function shutdown_bzbmenu { local output=`ps -cA | grep bzbmenu` if [ -n "$output" ] then killall -9 bzbmenu fi } function restore_ac_powersetting_to_normal { bz_victoryfile="/Library/Backblaze/bzdata/bzreports/bzstat_endfirstbackupmillis.txt" if [ ! -f $bz_victoryfile ] then pmset -c sleep 11 &> /dev/null fi } function unload_bzbmenu { for dir in /Users/* do userName=${dir:7} if [ $userName == 'Guest' -o $userName == 'Shared' ] then continue fi bzbmenuPlist="$dir/Library/LaunchAgents/com.backblaze.bzbmenu.plist" if [ -f "$bzbmenuPlist" ] then sudo -u "$userName" launchctl unload "$bzbmenuPlist" remove "$bzbmenuPlist" fi done } function bz_main { shutdown_bzbmenu shutdown_bzserv clean_library_backblaze clean_system_preferences_backblaze clean_applications_backblaze clean_misc unload_bzbmenu } # main bz_main
- In the Removal Command section, enter the following command:
- Click Save.
Add the Smart Software to a Policy
- Select Policies, and select the Software tab.
- In the Smart Software tab, click Add/Remove.
- Select your Backblaze Smart Software item (for example, Backblaze Backup), and click Add.
For more information about integrating Backblaze with Addigy, see Installing BackBlaze with Account Sign-in.
Was this article helpful?