yep / virtualOS

macOS Virtual Machine using Virtualization.framework
https://apps.apple.com/us/app/virtualos/id1614659226
Other
203 stars 19 forks source link

Support for downloading old macOS versions #6

Closed fumoboy007 closed 2 years ago

fumoboy007 commented 2 years ago

It would be great if the app could support easily downloading old macOS versions.

Potential use cases:

yep commented 2 years ago

TL;DR Looks like it is only possible to install relatively recent versions of macOS.

By default, VZMacOSRestoreImage only supports fetching the latest supported restore image.

However, you can still manually download and use a restore image using the following steps:

This is the application's sandbox location, it is where the files used by virtualOS are stored. The files of interest are:

If you move your downloaded restore image here and name it RestoreImage.ipsw, it will be used on next install.

You can also manually manage multiple virtual machines by renaming virtualOS.bundle to something else before installing another version.

The files from ipsw.me point to a download location at updates-http.cdn-apple.com. Although the domain does not end on apple.com, it appears to be owned by Apple, according to the whois entry

On a machine running 12.4, I was able to install version 12.1, 12.2.1, 12.3.1 and the beta version of macOS 13.0 (Ventura), but installing 11.0.1, 11.1 or 11.6 failed.

On iOS, Apple does not allow downgrades to older versions: they have to sign the ipsw file during install. After a new version of iOS has been released, they stop signing older versions making downgrades impossible (without a jailbreak).

If Apple also stops signing old versions of macOS, you could keep a copy of virtualOS.bundle and never update it. Once you successfully installed a certain version of macOS, it should keep working.

Of course, this is less convenient than being able to install arbitrary old macOS versions.

On the plus side, using the steps above, it is possible to test your apps on macOS beta releases without having to install the beta permanently.

fumoboy007 commented 2 years ago

Thanks, @yep!

Yup, I believe the Apple framework only supports Monterey and later guest OSes. I was thinking about the future where most people have Ventura or later as the host OS. 😀

It would be great if the app could be given a URL to download so that the user wouldn’t have to know implementation details of the app. Perhaps the app could download the restore image to a temporary folder and then use the load(from:completionHandler:) method to proceed with the installation?

yep commented 2 years ago

There is a public beta test for version 1.1 which allows selecting a custom ipsw restore image. By downloading a restore image from https://ipsw.me/product/Mac you can now install old versions of macOS.

You can sign up for the beta here: https://testflight.apple.com/join/vWKNYgmM