01-23-2023 05:30 PM - edited 01-23-2023 05:32 PM
Hi all,
I have a question in relation to what people are doing re: Local Distro for policies..?
GOAL: I'd like to run specific policies just for our device runups, this can easily be achieved by calling policies triggers during DEP that point to a local distro.
At this point i've gathered the following results speed testing both running policies via Jamf Cloud, local MacOS distro and Windows Server 2019 IIS distro all tested on both wired and wireless connections.
1. Local MacOS Distro, SMB: via Jamf Policy
2. Local MacOS Distro, HTTPS: via Jamf Policy
3. HTTPS: via Jamf Cloud
4. Direct to Local Distro using SCP:
scp -r jamfread@10.136.3.10:/Volumes/Cache/jamfshare/Packages/Catalina.pkg .
5. RSYNC: Slower than SMB
rsync -azP jamfread@10.136.3.10:'/Volumes/Cache/jamfshare/Packages/Catalina.pkg' .
6. Local Windows Distro, HTTPS: via Jamf Policy
7. Curl via Windows 2019 Server running IIS:
/usr/bin/curl -o "/Applications/Catalina.pkg" "<ServerURL>/jamf_share/Packages/Catalina.pkg" -u "svc_jamfshare_ro:<password>"
A fun bonus for anyone who has read through this not sure if anyone has messed around with using DEPNotify in conjunction with Curl but here is a demo and the script related to it.
https://youtu.be/hkSZPk3TlK0
#!/bin/bash
DEP_NOTIFY_LOG="/var/tmp/depnotify.log"
rm -f ${DEP_NOTIFY_LOG}
echo "Status: Downloading MacOS Catalina.." >> "$DEP_NOTIFY_LOG"
echo "Command: Video: https://imgur.com/I3T3K9m.mp4" >> "$DEP_NOTIFY_LOG"
open ${DEP_NOTIFY_LOG}
open -a "DEPNotify"
runInstall () {
rm /tmp/hpipe
mkfifo /tmp/hpipe
chmod 777 /tmp/hpipe
/usr/bin/curl -o "/Applications/Catalina.pkg" "https://<serverFQDN>/jamfshare/Packages/Catalina.pkg" -u "jamfread:<password>" &> /tmp/hpipe &
echo "Command: Determinate: 100" >> ${DEP_NOTIFY_LOG}
echo "Command: Video: https://imgur.com/I3T3K9m.mp4" >> "$DEP_NOTIFY_LOG"
eval $(echo m=M | tr 'M' '\015')
while read -r -d "$m" line
do echo -e "Status: % Total %Rec %XferdDl AvgUp SpeedTtl TSpent TLeft Current\r${line}" >> ${DEP_NOTIFY_LOG}
done < /tmp/hpipe
rm /tmp/hpipe
echo "Status: ${line}..." >> "$DEP_NOTIFY_LOG"
}
runInstall
sleep 2
killall "DEPNotify"
exit 0
Of course there are some parameters to change like the curl URL, username and password and there is not check for the DEPNotify.app or an 'Exit' command for DEPNotify but simply and fun test that I may incorporate with our current Zero touch for super-fast deployment of packages.
Any help would be much appreciated in relation to how people maximise local distribution points,
Pete