Comment by mightysashiman
3 months ago
Would you mind educating me about use cases for having one or even multiple MacOS VMs on an apple silicon machine please?
3 months ago
Would you mind educating me about use cases for having one or even multiple MacOS VMs on an apple silicon machine please?
I have an M4 Mac Mini running the following in a VM:
- OpenWRT (previously OPNSense & once Mikrotik RouterOS) using 2x 2.5Gbps Ethernet NICs via USB-C
- OpenMediaVault (Exposing a 4-bay DAS via USB-C, 2x3TB Drives in Btrfs RAID-1)
- HassOS (Home Assistant OS)
On the host, I'm running OLlama and a reverse proxy through Docker.
The whole thing uses 7 watts of power at any given time - I've seen max peaks of 12w when running LLM queries. The drive bay actually uses more than it.
Through power saving alone, it will pay for itself in 5 years over my previous AMD Zen 2 build.
My question was rather about MacOS guest(s) on a MacOS host. Contrarily to specialised linux distros (Home Assistant, OpenWRT...) MacOS doesn't strike me as particularly minimalistic won I wonder about the amount of overhead and plain storage requirements just running them idle...
I understand for specific MacOS or iOS development wanting template envs one would want to easily and repeatedly spawn up / destroy.
Out of curiosity, why not containers for OMV and Haas? QoS? And I’m dying to know what you are using openwrt for. I’m looking at setting up a Mini as well, and have been using Colima/LIMA to run containers on Rosetta/Mac vz locally and it seems to work well enough.
I assume you mean something other than OMV, ran in a container? Reason I put it in a VM was that I wanted to use a Linux compatible file system. I’m using BTRFS with raid, I’m sure I could have ran APFS in raid instead!
For haas, it was partly QoS, partly because I had historically ran all of my things separately. I might look at bringing that to the container level.
I’m using OpenWRT as my main router! One port to my LAN switch, one to the modem.
Haas has massive limitations in its container mode. (Add-ons, OTA updates,...)
I’d use a Mac Mini in a heartbeat if they had an ECC option :(
What is your use case where not having an ECC is critical? Assuming something related to complex calculations that cannot fail and takes a lot of time to process?
2 replies →
Trying to run complex CI/CD for automated build/test toolchains for building iOS apps.
We have a Mac Studio dedicated to that purpose. Periodically something on it stops working (software updates are a common reason). Trying to run CI/CD on a bare metal consumer oriented OS is an exercise in frustration.
It’s also handy to be able to sandbox different environments from each other. Once you have multiple projects that need different versions of Xcode, or even macOS (a good example is wanting to spin things on a beta), you need VMs or multiple machines. (And yes I’m aware of tools like Xcodes, but testing on a beta of macOS requires a reboot and a lengthy install.)
This. I've been managing a CI/CD system of around 50 macOS build machines for a few years now, previously our own hardware in a data center, currently EC2 Mac instances.
All the things Apple puts in place to make macOS more secure and consumer friendly make it really hard to manage as a server, especially if you don't want to use MDM. For example with the current version of macOS, the macOS AMI that Amazon provides requires manually logging in over screen sharing to enable local networking. So I haven't updated to Sequoia yet. As it is, my AMI build process is fully automated but still takes almost 2 hours and involves first mounting the Amazon AMI to a Linux instance to modify parts of the image that are read-only when it's booted from.
Our current CI/CD process is to create a unique build user per build, then tear it down afterwards. EC2 has something called root volume replacement to allow you to reset a machine to its AMI, but that still takes too long (~ 10 minutes) to do between every build.
(At least with EC2 Macs I no longer need to open a ticket with DC ops when there's a hardware issue.)
Using macOS VMs that can be quickly reset makes this all a lot easier, more flexible, secure, and cleaner. The only currently viable options I'm aware of are tart and anka. I'm glad to see some open source competition in this space.
Check out my project, WarpBuild [1], if you want managed Mac VMs for CI/CD purposes. It plugs in nicely to the GitHub actions ecosystem and provides machines on demand.
[1] https://warpbuild.com
When IT policy prevents root access to the host but VMs are fine
Shh. I need my VMs and they also help me run software the corp malware doesn’t play nice with.
I'm probably an oddball compared to most, but I use a VM as my main work environment. My main reason is because it's super easy to create a backup and test anything like OS or major software updates there first to make sure it doesn't hose anything. Or if I just want to tinker and try new things without risking breaking anything. Also, where I work they get us new hardware every 3 years, and it means I don't have to spend a long time trying to set my environment up on a new computer. I just copy over the VM and jump right in.
I recently used virtualbuddy with a macOS VM to test a developer environment setup with an Ansible playbook.
Worked well for my simple use case.
The same use case as any other VM? Isolated systems that are portable, easy to bootstrap and destroy, etc, the list goes on.
> Isolated systems that are portable, easy to bootstrap and destroy, etc
So, like Docker but without the part where it's fast or convenient!
Test environments for macOS configuration, compliance workflows, application installer build processes, matrix testing across macOS versions, etc. I work for an MDM provider and constantly have 2-3 machines with 2 VMs each running.
The first thing that comes to my mind is runners for automated workflows that need to happen on MacOS.
The most common ones are for QA testing and CI pipelines.
I wonder if this is a good alternative for running potentially malicious tools like random fine tunes of LLMs or coding agent outputs with little to no risk