How to install the Backblaze Client Silently with Addigy
  • 19 Sep 2025
  • Dark
    Light

How to install the Backblaze Client Silently with Addigy

  • Dark
    Light

Article summary

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.

  1. Sign in to the Addigy console.
  2. On the left sidebar, select Catalog.
  3. Select the Variables tab.
  4. Create a variable for your Group ID.
    1. Click New.
    2. In the Key field, enter groupID.
    3. In the Default Value field, enter your GroupID value.
    4. Click Save.
  5. Create a variable for your Group Authentication Token.
    1. Click New.
    2. In the Key field, enter groupToken.
    3. In the Default Value field, enter your GroupAuthenticationToken value.
    4. Click Save.

Create a Smart Software Item

Before you begin: Download the Backblaze Installer .dmg file: https://secure.backblaze.com/mac/install_backblaze.dmg.

  1. On the left sidebar, select Catalog.
  2. Select Software, and select the Smart Software tab.
  3. Click New.
  4. Enter a name (for example, Backblaze Backup).
  5. Upload the installer, and add an installation command.
    1. Click Select File(s).
    2. Upload your .dmg file.
    3. In the Install Command section, click Add.
    4. Enter the following command using the variables you created in the last task:
      # The Backblaze email associated with deployment
      email="user@mycompany.com"
      # 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"
  6. Add a condition for install.
    1. 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
    2. Ensure that Install if return value is 0 is enabled.
  7. (Optional) Add a removal script if you want Backblaze to be removed when you delete the Smart Software from a policy.
    1. 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
  8. Click Save.

Add the Smart Software to a Policy

  1. Select Policies, and select the Software tab.
  2. In the Smart Software tab, click Add/Remove.
  3. 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?