We are trying to deploy several dmg packages to a Mac via Automox. I am setting them as required software. Here is the script:
#!/bin/bash
DMG_PATH="/path/to/Avid_Link_25.5.1_Mac.dmg"
MOUNT_POINT=$(mktemp -d /tmp/avidlink.XXXXXX)
echo "đź”§ Mounting DMG to $MOUNT_POINT..."
hdiutil attach "$DMG_PATH" -mountpoint "$MOUNT_POINT" -nobrowse -quiet
# Confirm mount succeeded
if [ ! -d "$MOUNT_POINT" ] || [ -z "$(ls -A "$MOUNT_POINT")" ]; then
echo "❌ Mount failed or mount point is empty. Exiting."
rmdir "$MOUNT_POINT"
exit 1
fi
# Locate the .pkg file
PKG_PATH=$(find "$MOUNT_POINT" -name "*.pkg" | head -n 1)
if [ -z "$PKG_PATH" ]; then
echo "❌ No .pkg found. Unmounting and exiting."
hdiutil detach "$MOUNT_POINT" -quiet
rmdir "$MOUNT_POINT"
exit 1
fi
echo "📦 Installing package: $PKG_PATH"
sudo installer -pkg "$PKG_PATH" -target /
echo "đź§ą Unmounting DMG..."
hdiutil detach "$MOUNT_POINT" -quiet
rmdir "$MOUNT_POINT"
echo "âś… Avid Link installed successfully."The script gives this output.

Any ideas on why this isn’t working?
This discussion is archived and closed to replies. Continue it in the Automox Community Slack.
Discuss on Slack