You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Given that Apple is writing their own containerization framework, it would be great to see the ability to run macOS itself inside a container. CI/CD is so much easier with containers and macOS not supporting being run in a container makes it harder to manage CI/CD processes for mac and iOS apps. I'd love to see that change.
Obviously mac containers would have to run on a mac host and might only run in this container framework but it would be a huge improvement for mac development.
Code of Conduct
I agree to follow this project's Code of Conduct
Reacted by ManuW, lin72h, Matt Coster, jershell, subnix, Alexey Fedechkin , Evgeniy Zhelenskiy, Sergey Bezrukov, Anatoliy Pokhresnyi, vladyslavv-ua and 11 more
Reacted by Patrik Nyblad
Reacted by Patrik Nyblad
Reacted by Michael Grupp, jershell, Emiliano Maccaferri, Konradas Bunikis and Patrik Nyblad
As I understand it, this is some kind of misunderstanding, and either we misunderstood something, or it’s really not possible to create a container with macOS itself?
As I understand it, this is some kind of misunderstanding, and either we misunderstood something, or it’s really not possible to create a container with macOS itself?
As far as I know, you can't create a container with macOS itself. There are a few macOS containers on github but those run qemu in a container and a full macOS VM in that. Slow, requires going through OOBE, violates Apple's license so can't use it commercially without consequences.
What I want is a container inside which I can run macOS software. Mostly xcode builds. Would be a game changer for CI/CD with macOS and iOS development. This currently does not exist, but seems like the next logical step in Apple's official container support.
I understand the request, and thanks for opening the issue @jbschooley. I think you are highlighting that there'd be utility in being able to have a container like construct for a macOS based workload. Right?
Today github.com/apple/containerization and this project focus just on Linux based container workloads.
Reacted by Jun Moriuchi and Jacob Schooley
Reacted by Emiliano Maccaferri and Konradas Bunikis
@egernst Yep, this exactly. I've been waiting a long time for the day where I can run macOS/iOS builds in containers just like I can with Windows and Linux builds and not have to worry about cleanup or software updates breaking things on the host.
@jbschooley Unless I'm missing something about what you're looking for, virtualizing macOS has been possible for ~5 years via Apple's Virtualization.framework, no qemu or other emulation necessary. It's not lightweight like minimal Linux VMs, but that's because macOS isn't lightweight and the typical container patterns don't really make sense with a full OS. Nevertheless, it's been available and there are several open source projects utilizing it.
For more info, I recommend Apple's documentation [1] and Howard Oakley [2] has dozens of articles about it (scroll down past the author's own software offerings for a list of articles).
macOS isn't lightweight and the typical container patterns don't really make sense with a full OS
Before containers existed this was how things worked with Linux and Windows too. Windows containers still aren't exactly lightweight, but containerization still makes CI with Windows apps so much easier.
Yes, Apple does have their virtualization framework for full VMs. But say you want to try building your iOS app with a new version of Xcode. You have to create a new VM, manually click through OOBE and set up user accounts, and eventually you get to a terminal and can paste in a script to install everything. Or you copy your existing VM and update Xcode but then you have assets left over from the old version that might cause different behavior than a fresh install would.
Whereas with a container you could just write a dockerfile to do all that boring stuff. Or you pull from someone else's image that already has it all installed, and all your dockerfile or build script has to do is clone your code into it and build, and maybe pull credentials from secrets or env vars or keychain. macOS or Xcode releases an update, just update version numbers and let it run.
With Apple developing their own containerization framework, now seems like a great time to join the other platforms in making CI better.
Ah that makes sense. Maybe look into MDM workflows for macOS? Apple provides utilities and there are 3rd party ones as well, though I'm not sure how streamlined they are for virtualized instances. I'd be surprised if something doesn't already exist, though.
Activity
jershell commentedon Aug 5, 2025
As I understand it, this is some kind of misunderstanding, and either we misunderstood something, or it’s really not possible to create a container with macOS itself?
jbschooley commentedon Aug 5, 2025
As far as I know, you can't create a container with macOS itself. There are a few macOS containers on github but those run qemu in a container and a full macOS VM in that. Slow, requires going through OOBE, violates Apple's license so can't use it commercially without consequences.
What I want is a container inside which I can run macOS software. Mostly xcode builds. Would be a game changer for CI/CD with macOS and iOS development. This currently does not exist, but seems like the next logical step in Apple's official container support.
egernst commentedon Aug 7, 2025
I understand the request, and thanks for opening the issue @jbschooley. I think you are highlighting that there'd be utility in being able to have a container like construct for a macOS based workload. Right?
Today github.com/apple/containerization and this project focus just on Linux based container workloads.
patriknyblad commentedon Aug 27, 2025
Adding my +1 here, it would be fantastic to run macOS containers so I can run macOS software in a container inside of macOS 😍
jbschooley commentedon Sep 3, 2025
@egernst Yep, this exactly. I've been waiting a long time for the day where I can run macOS/iOS builds in containers just like I can with Windows and Linux builds and not have to worry about cleanup or software updates breaking things on the host.
altaic commentedon Sep 3, 2025
@jbschooley Unless I'm missing something about what you're looking for, virtualizing macOS has been possible for ~5 years via Apple's
Virtualization.framework, no qemu or other emulation necessary. It's not lightweight like minimal Linux VMs, but that's because macOS isn't lightweight and the typical container patterns don't really make sense with a full OS. Nevertheless, it's been available and there are several open source projects utilizing it.For more info, I recommend Apple's documentation [1] and Howard Oakley [2] has dozens of articles about it (scroll down past the author's own software offerings for a list of articles).
[1] https://developer.apple.com/documentation/virtualization
[2] https://eclecticlight.co/virtualisation-on-apple-silicon/
jbschooley commentedon Sep 3, 2025
Before containers existed this was how things worked with Linux and Windows too. Windows containers still aren't exactly lightweight, but containerization still makes CI with Windows apps so much easier.
Yes, Apple does have their virtualization framework for full VMs. But say you want to try building your iOS app with a new version of Xcode. You have to create a new VM, manually click through OOBE and set up user accounts, and eventually you get to a terminal and can paste in a script to install everything. Or you copy your existing VM and update Xcode but then you have assets left over from the old version that might cause different behavior than a fresh install would.
Whereas with a container you could just write a dockerfile to do all that boring stuff. Or you pull from someone else's image that already has it all installed, and all your dockerfile or build script has to do is clone your code into it and build, and maybe pull credentials from secrets or env vars or keychain. macOS or Xcode releases an update, just update version numbers and let it run.
With Apple developing their own containerization framework, now seems like a great time to join the other platforms in making CI better.
altaic commentedon Sep 3, 2025
Ah that makes sense. Maybe look into MDM workflows for macOS? Apple provides utilities and there are 3rd party ones as well, though I'm not sure how streamlined they are for virtualized instances. I'd be surprised if something doesn't already exist, though.