Hi all. Here is my First post in which I would like to share some information how you could deploy Cura via Microsoft Endpoint Manager - Intune. Of course you can also use this post to make your deployment for other MDM's like SCCM, Zenworks etc by using knowledge from this topic.
You can make an intunewin package that calls the install.cmd.
The instruction for intunewin is available here.
You can download the Microsoft-Win32-Content-Prep-Tool here.
Scope of the scripts:
It uninstalls older versions of Cura
It makes sure a firewall rule is created so that there is no firewall popup at first start that needs elevated permissions
It copies shortcuts in the start menu which is lacking in the current Cura 5.0.0 install.
For Cura 5.0.0 it currently looks like this: install.cmd
SET INSTALLPATH=%~dp0
powershell.exe -executionpolicy Bypass -file "%INSTALLPATH%removeCura.ps1"
netsh advfirewall set currentprofile state off
"%INSTALLPATH%Ultimaker-Cura-5.0.0-win64.exe" /S /quiet /norestart
del /F /Q "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Ultimaker Cura\*.*"
rd /S /Q "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Ultimaker Cura"
md "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Ultimaker Cura"
copy "%INSTALLPATH%Development Resources.url" "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Ultimaker Cura\Development Resources.url"
copy "%INSTALLPATH%Online Documentation.url" "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Ultimaker Cura\Online Documentation.url"
timeout /t 30 /nobreak >nul
copy "%INSTALLPATH%Ultimaker-Cura 5.0.0.lnk" "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Ultimaker Cura\Ultimaker-Cura 5.0.0.lnk"
timeout /t 30 /nobreak >nul
copy "%INSTALLPATH%Uninstall Ultimaker Cura 5.0.0.lnk" "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Ultimaker Cura\Uninstall Ultimaker Cura 5.0.0.lnk"
netsh advfirewall set currentprofile state on
netsh advfirewall firewall add rule name="Ultimaker Cura 5.0.0" dir=in action=allow program="C:\Program Files\Ultimaker Cura 5.0.0\Ultimaker-Cura.exe" enable=yes
removeCura.ps1
# Get installed Cura versions
$InstalledCuraVersions = Get-Package -Provider Programs -IncludeWindowsInstaller | Where-Object{$_.Name -like "*Cura*"}
# Loop through folders and uninstall
$InstalledCuraVersions | ForEach-Object {
& "C:\Program Files\$($_.Name)\Uninstall.exe" /S
}
uninstall.cmd
"C:\Program Files\Ultimaker Cura 5.0.0\Uninstall.exe" /S
del /F /Q "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Ultimaker Cura\*.*"
rd /S /Q "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Ultimaker Cura"
netsh advfirewall firewall delete rule name="Ultimaker cura 5.0.0" program="C:\program files\Ultimaker cura 5.0.0\Ultimaker-Cura.exe"
I have attached a ZIP file that contains everything except the Cura 5.0.0 installer itself so you can create your intunewin package yourself.
Ultimaker Cura 5.0.0.zip