Search code examples
vagrantvmwarevmware-workstation

Is it posible to bring up a VM with vagrant but then manage it from WMWare?


I've been reading up on Vagrant, but i can't find anything about whether after creating a VM with vagrant (specifically using a VMWare provider) you can still manage it from the "provider" software (in this case WorkStation or Player).

I would like to bring it up using vagrant up and when it finishes provisioning, "release it" from vagrant and manage it from VMWare Workstation. Is it possible?

Thanks in advance.


Solution

  • The comment from @axiac is basically correct, but things works slightly different with VMWare, at least I am using VMware Fusion on macos so below is based on my usage.

    When you bring up VM with VMWare, the vmx file is created in .vagrant folder of your project directory and the VM is not automatically added in the VM listed in VMWare.

    Also the VM does not appear in the CLI. so when the VMs are halted and running

    fhenri@machine:/Applications/VMware Fusion.app/Contents/Library$ ./vmrun list
    Total running VMs: 0
    

    and when I spin up the VM, I will get

    fhenri@machine:/Applications/VMware Fusion.app/Contents/Library$ ./vmrun list
    Total running VMs: 2
    /Users/fhenri/project/ariba/pws.source/.vagrant/machines/db/vmware_fusion/89e5f21d-7078-44ed-8407-17dcc8c335ee/centos65.vmx
    /Users/fhenri/project/ariba/pws.source/.vagrant/machines/app/vmware_fusion/6ee0dc5d-ec17-429c-9fd0-b069bfc0b040/centos65.vmx
    

    When you open VMWare GUI, nothing appears in the VM library, if the VM are running, the VM GUI are available, beware that if you close any window form this point, the VM will shutdown (this is a main difference with VirtualBox as vb manages better the process of the VM and the vb process itself) but you can manually add the vmx file to vmware library if you want to later start and manage the VM from vmware itself