utmapp / UTM

Virtual machines for iOS and macOS
https://getutm.app
Apache License 2.0
26.29k stars 1.31k forks source link

Vagrant support for macOS #3718

Open osy opened 2 years ago

osy commented 2 years ago

Cross referencing with https://github.com/hashicorp/vagrant/issues/12518

This has been requested by quite a bit of users and this issue should track it.

JasonvanBrackel commented 1 year ago

I just discovered you all and would love to work this into my processes. Consider me a willing tester if/when you get around to this.

madhavajay commented 1 year ago

Looks like Orb won't do this so I think its worth doing it here for UTM instead. https://github.com/orbstack/orbstack/issues/105

andronat commented 1 year ago

Any work done on this? Given that QEMU 8.1.0 creates major issues with broken x86_64 VMs, I would love to use UTM through Vagrant.

tdesaules commented 9 months ago

Hey UTM team !

Is a Vagrant provider plugin is on the roadmap ?

I'm just moving on Mac and was looking for a Virtualization software (I was looking for an open source one and not a big fan of VirtualBox) and I have to say that I'm used to Vagrant to provision things on my laptop.

naveenrajm7 commented 1 month ago

Hello!

Thank you for exposing UTM via APIs. I was able to build a Vagrant plugin for UTM using those. (https://github.com/hashicorp/vagrant/issues/12518#issuecomment-2278629170)

Check out https://naveenrajm7.github.io/vagrant_utm/ and please share your feedback.

For some Vagrant actions, the plugin currently works around the existing UTM APIs, which can be improved by simply exposing the existing functionality via API either through the command line (ideal) or Apple Scripting Bridge.

I will list a couple here .

  1. utmctl import <file.utm> --name <name> Imports utm file with given name and returns uuid , this is basically the utm://downloadVM?url=.. with few changes.
  2. utmctl export <name/uuid> -o <file.utm> Exports the VM to the given path, this is exactly the 'Share..' action button.

I also have a working Packer plugin for UTM which enables building reproducible UTM images. Exposing existing functions through API , can improve the packer plugin to do unattended OS installs. Required API support includes the ability to add Qemu additional arguments to VM config, add/remove devices through AppleScript.

I can create issues for each and possibly work towards that. Please share your thoughts.