Visual Studio for Mac deployment

Valued Contributor III

I already have users banging down my door to get Visual Studio installed on their Macs. I let 1 user download it to be a guinea pig. The installation prompted 3 or 4 times for admin credentials for several different components. It's kinda similar to XCode's extra stuff it wants to install unless you've got that installation scripted (I do). Has anyone found a way to install Visual Studio yet through Casper?


Valued Contributor III

I also just remembered that the download from Microsoft is a dmg that contains a 64MB installer app. The full installation is almost 600MB when completed. It looks like the installer is one of those "downloader installers" where it pulls most if not all of the files from the internet.

Valued Contributor III

You might study how folks deployed Xamarin in the past because all it supposedly is is a rebadged Xamarin in that first preview. I've never done it but I've been following the news on it.

Valued Contributor II

any luck with this?

Valued Contributor III

This is the closest I've come to an answer and it makes me cringe to even think about it.

Valued Contributor III

Thank you for nudging me on this @jwojda Progress report: I decided to bite the bullet and see what I could do. In the Xamarin forum link above, I clicked on the link for

You can get the installers for each component for the current stable channel at

Then I clicked on the OS X menu under "Xamarin Studio" and chose the Product Version. As I recall, if you choose the Universal Installer, that is the downloader app I'm trying to avoid. 69ba18c7671340f5882702f87a26e922
After a 223MB download I opened the DMG and copied the Xamarin to /Applications and launched it. It alerted me that I needed to also install Mono. I went to and downloaded it for Mac. Mono was a 364MB .pkg file (a 1 GB installation). I ran the installer then launched Xamarin Studio again and it appeared to launch without complaining about permissions or downloading modules. Now I don't know what happens next after devs start digging in to write their code. I'm about to package up the Xamarin and put that and the Mono pkg into Self Service and have one of the devs give it a try.

Valued Contributor II

how is it different from this? Visual Studio

Valued Contributor III

It's my understanding that Microsoft is just licensing the product from Xamarin and slapping the MS logo on it with some changes. I could be wrong. I'd love to get an actual Microsoftie to clarify.

Valued Contributor III

Also, this happened today I'm not a developer so I really don't know what the differences are. I rely on our devs to tell me what they need, but if I am presented with 2 different solutions and one is deployable and the other is not, I'll lean toward the deployable one as long as the devs say they can use it.

New Contributor


I found these instructions for creating a standard offline installer .pkg:

This was a lot more than the 600 MB app install, though. In addition to the components listed on the Xamarin support thread you posted, it seems to download every version of the Android SDK you could ever want, for a total of around 18 GB. It's also very unstable—I haven't been able to get it to finish building on various computers running Sierra or El Capitan. Either it crashes before the download even starts, or it crashes after going all the way through the download.

Good luck!

Valued Contributor III

New Contributor

Always good to know you're not the only one with a problem!

Well, if you're feeling particularly brave, you can grab all the individual component packages out of ~/Library/Caches/XamarinInstaller/Universal/Downloads and install each piece with a policy (or build a single .pkg that includes them all yourself). It would be a nightmare to update, but might satisfy the initial demand until Microsoft gets the bugs ironed out of the real installer.

Valued Contributor III

Looks like Microsoft has pulled the offline installer instructions.

Contributor III

Has anybody packaged the security update that Microsoft mentioned in the April 2017 notes? If so, I would appreciate knowing what you did. Thanks.

New Contributor II

New to JAMF here. I have a few high school labs in need of VS for Mac. What's everyone currently doing for deployment of this bad boy?

Valued Contributor III

Since Microsoft hasn't provided an offline installer, I haven't touched it again. I do check on the status of an offline installer every now and then, but it is still vaporware. Luckily I was able to get our devs to understand that they don't NEED this yet... they just want to play with it for now until the need actually arises. If the need does arise before Microsoft makes this a deployable product, I'm going to have to push back and tell management that MS hasn't provided me with a tool we can use. It is absolutely impractical to even attempt to manually install this on multiple computers. And I shudder to think of what the update process will consist of.

New Contributor III

Any news on creating a package of Visual Studio for Mac? I get questions from a variety of people who would like to use this in a classroom environment

New Contributor II

Sorry to bump and old thread, but was this ever resolved?

Valued Contributor III

I have a feeling Microsoft doesn't really care enough to do anything about it. This has been on Microsoft's page for an offline installer for a very long time: 282f6006902f44eba4d16f209c3506f8

I've given up on it. Luckily our devs don't need it at this time. If the day comes that they do need it, I'll have to push back and let them know that it isn't deployable in mass numbers.

Contributor II

@AVmcclint Looks like I might have found a solution for this if anyone is still interested.

I don't have any means of hosting the pkgs but this is tested by several people and seems to be working fine.

Only problem I have is the ANDROID SDK, but it should not be too hard to manually install this one.

its not pretty but it works 🙂

Valued Contributor

Hello @BOBW we just received a call from our IT faculty and they are wanting to have this installed in their Mac labs. Any chance you can share how you were able to get Visual Studio installed? You can email me direct if it is easier for you.

thank you!

New Contributor II

Hey @BOBW I'd be interested in knowing as well! Right now we just run Visual Code in our Mac labs but we'd love a solution to roll out VS instead (in addition?)

Contributor II

Hi @MikeMcD, ok here goes.... its long but I think I documented all of this correctly when I did it, let me know if anything doesnt work and I will edit the post:

Visual Studio install for Mac

Download Unity3d (free)

intructions on installing unity are here below but thety are incorrect and dont work... but you will get the idea

turn off SIP

Reboot into recovery mode
Open terminal
csrutil disable && reboot 
Restart device
Login and open start pkgkeeper script

download pkgkeeper

snapshot device

tmutil snapshot

Run pkgkeeper

Install Unity3d

You should see pkg's being placed onto Desktop

save files externally and return to snapshot

From here you will need to just install the pkg files you need but we needed Unity3d so I installed everything
I am pretty sure from memory the installer you need for Visual Studio is 2.dmg
I copied the Visual Studio app from here to Applications folder
Capture Visual Studio using composer and save to external

this should give you Visual Studio from this point. But here is the rest of the documentation I have for Unity3d

Install all files as required using the captured pkg files

I moved all files into a folder we use as a file repo on the local machine: /usr/local/Management/Installer/unity/

I ran through the below script to ensure everything was OK
Script might be incorrect due to updates, but you get the idea

/usr/sbin/installer -pkg "/usr/local/Management/Installer/unity/Unity.pkg" -target "/" -verbose || exit 1
/usr/sbin/installer -pkg "/usr/local/Management/Installer/unity/1.pkg" -target "/" -verbose || exit 1
hdiutil attach /usr/local/Management/Installer/unity/2.dmg
ditto -v "/Volumes/Visual Studio/" /Applications/
hdiutil detach "/Volumes/Visual Studio"
/usr/sbin/installer -pkg "2.dmg" -target "/" -verbose || exit 1
/usr/sbin/installer -pkg "/usr/local/Management/Installer/unity/Documentation.pkg" -target "/" -verbose || exit 1
/usr/sbin/installer -pkg "/usr/local/Management/Installer/unity/UnitySetup-Android-Support-for-Editor-2018.2.1f1.pkg" -target "/" -verbose || exit 1
/usr/sbin/installer -pkg "/usr/local/Management/Installer/unity/UnitySetup-iOS-Support-for-Editor-2018.2.1f1.pkg" -target "/" -verbose || exit 1
/usr/sbin/installer -pkg "/usr/local/Management/Installer/unity/UnitySetup-AppleTV-Support-for-Editor-2018.2.1f1.pkg" -target "/" -verbose || exit 1
/usr/sbin/installer -pkg "/usr/local/Management/Installer/unity/UnitySetup-Linux-Support-for-Editor-2018.2.1f1.pkg" -target "/" -verbose || exit 1
/usr/sbin/installer -pkg "/usr/local/Management/Installer/unity/UnitySetup-Mac-IL2CPP-Support-for-Editor-2018.2.1f1.pkg" -target "/" -verbose || exit 1
/usr/sbin/installer -pkg "/usr/local/Management/Installer/unity/UnitySetup-Vuforia-AR-Support-for-Editor-2018.2.1f1.pkg" -target "/" -verbose || exit 1
/usr/sbin/installer -pkg "/usr/local/Management/Installer/unity/UnitySetup-WebGL-Support-for-Editor-2018.2.1f1.pkg" -target "/" -verbose || exit 1
/usr/sbin/installer -pkg "/usr/local/Management/Installer/unity/UnitySetup-Windows-Mono-Support-for-Editor-2018.2.1f1.pkg" -target "/" -verbose || exit 1
/usr/sbin/installer -pkg "/usr/local/Management/Installer/unity/UnitySetup-Facebook-Games-Support-for-Editor-2018.2.1f1.pkg" -target "/" -verbose || exit 1

start pkg keeper again and run any software updates, pkg keeper will grab these and place them on desktop
save externally
return to snapshot again
add new items to script or replace existing after update
runs script to install everything and test

Download Visual Studio installer
run pkgkeeper install visual studio and allow pkgkeeper to capture downloads to desktop
save externally
download JDK
Save externally

return to snapshot
move XAMARIN files locally to folder /usr/local/Management/Installer/xamarin/

install Visual studio (unity as above)
install XAMARIN using this script below:


if [ -e /Applications/Visual ]; then
sudo installer -pkg "/usr/local/Management/Installer/xamarin/xamarin.ios-" -target / -allowUntrusted
sudo installer -pkg "/usr/local/Management/Installer/xamarin/MonoFramework-MDK-" -target / -allowUntrusted
sudo installer -pkg "/usr/local/Management/Installer/xamarin/JDK 8 Update 181.pkg" -target / -allowUntrusted
sudo installer -pkg "/usr/local/Management/Installer/xamarin/" -target / -allowUntrusted
sudo installer -pkg "/usr/local/Management/Installer/xamarin/xamarininteractive-1.4.3.pkg" -target / -allowUntrusted
sudo installer -pkg "/usr/local/Management/Installer/xamarin/dotnet-sdk-2.1.301-osx-x64.pkg" -target / -allowUntrusted
sudo installer -pkg "/usr/local/Management/Installer/xamarin/xamarin.mac-" -target / -allowUntrusted
sudo installer -pkg "/usr/local/Management/Installer/xamarin/profiler-mac-1.6.2-165.pkg" -target / -allowUntrusted
sudo installer -pkg "/usr/local/Management/Installer/xamarin/dotnet-runtime-2.1.1-osx-x64.pkg" -target / -allowUntrusted
echo " Visual Studio not found"
exit 0      ## Success
exit 1      ## Failure


If all is good you should have the 2 or three folders
1 with Unity / Visual Studio
2 Unity / Visual Studio updates
3 Xamarin

I created three pkgs with composer with each of these separated I then ran the scripts above as post install scripts for each individual pkg

you will then need to delete the installer pkgs from the local device and turn SIP back on of course

Reboot into recovery mode
Open terminal
csrutil enable && reboot 
Restart device

New Contributor III

@BOBW Hello

Just stumbled onto this thread, we are new to jamf and i am trying to deploy Unity to some Lab machines. The instructions that unity provides are so bad and I keep trying to deploy. I have gotten to the part where i have downloaded all the packages but cant get them to deploy/licence correctly. I was wondering if you are still deploying this in your environment and could possibly lend a hand?

Contributor II

Unity is on the list of apps that I will be deploying soon. I'll share what I have learned as I work through the process as well.

Contributor II

@stephaniemm77 We are currently struggling a little with the licensing for Unity, but haven't spent too much time on it (our license expires in 2 weeks so I need to do something soon)
But we have found if you are deploying the DMG's as in the instructions above you might have issues as these are not APFS compliant. If you pull the pkg out of the DMG and install then it works much better.
Can you give me an indication of what the specific issues are? We just deployed this to about 80 lab devices and it seemed to work fine once we had done this.

tried this below to license UNITY but it does not want to work for some reason, if anyone has any reason why.
I have reached to Unity for assistance
/Applications/Unity/ -quit -batchmode -serial -username ' -password '**' || :

New Contributor III

So I have downloaded all the the separate .pkg files via the unity download assistant. I am having trouble after that point, i i cant get the script that comes is in the folder to execute to do the installs. I keep getting errors. can you give me an idea of what your workflow is like? I put the installers in jamf admin but seems like i get stuck from there.

New Contributor III


Contributor II

Here's how I'm distributing Visual Studio 8x

Downloading the following components
- Mono Framework -
.- Net Core LTS and/or Current) -
- Core VS App - See Below
- Xamarin Profiler -
- Xamarin Inspector & Workbooks -

The core app can be a bit tricky, but they do have full dmg downloads of the core app, when they release a new version, it's guess the file link.

Here's what I have

To minimum get VS to open, you have to have the core app and the Mono Framework.

Contributor II

HI @stephaniemm77 I really need to see where you are getting stuck to help out. When you run the script or policy manually through terminal what errors are you getting?

It should just be a matter of running each pkg with "sudo installer -pkg /path/to/pkg -target /" one at a time. If one of these fail this is what you need to show me and what the error is.

You are going to need Xcode installed, with the devtools etc, and Java, OpenJDK works fine I think.

Sorry for the delay in response.


Thanks @jstillio so much for this, 11th hour bacon saved1