Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: vmware tools iso path for Fusion 13 #112

Merged
merged 8 commits into from
Apr 10, 2023
Merged

fix: vmware tools iso path for Fusion 13 #112

merged 8 commits into from
Apr 10, 2023

Conversation

Stromweld
Copy link
Contributor

VMware Fusion 13.x.x moved the tools iso files based on cpu arch.

Closes #109

@Stromweld Stromweld requested a review from a team as a code owner January 24, 2023 02:58
@hashicorp-cla
Copy link

hashicorp-cla commented Jan 24, 2023

CLA assistant check
All committers have signed the CLA.

@Stromweld
Copy link
Contributor Author

I'm new to golang as in this is the first time i've tried doing anything in golang so may need a bit of help if this is not correct.

@tenthirtyam tenthirtyam changed the title fusion 13 tools path fix fix: vmware tools iso path for fusion 13 Jan 24, 2023
Copy link
Contributor

@lbajolet-hashicorp lbajolet-hashicorp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @Stromweld,

There are some compilation errors in the code, which should get resolved by adding the missing import statement.

Other than that, I left some suggestions for the code, feel free to take a look and don't hesitate to reach out if you need help on implementing the feature.

That being said, thanks for taking a jab at this problem, looking forward to helping you getting this in.

builder/vmware/common/driver_fusion6.go Outdated Show resolved Hide resolved
builder/vmware/common/driver_fusion6.go Outdated Show resolved Hide resolved
builder/vmware/common/driver_fusion6.go Show resolved Hide resolved
Signed-off-by: Corey Hemminger <hemminger@hotmail.com>
@Stromweld
Copy link
Contributor Author

@lbajolet-hashicorp I fixed the missing runtime import, I'm not sure what I'd need to find the Guest OS type to fix the outer if statement.

Copy link
Contributor

@nywilken nywilken left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👋 I'm waiting on version of Fusion 13 to test. I have a nit suggestion and a question about the the Windows conditional.

builder/vmware/common/driver_fusion6.go Outdated Show resolved Hide resolved
builder/vmware/common/driver_fusion6.go Outdated Show resolved Hide resolved
Co-authored-by: Wilken Rivera <dev@wilkenrivera.com>
Co-authored-by: Wilken Rivera <dev@wilkenrivera.com>
Signed-off-by: Corey Hemminger <hemminger@hotmail.com>
@Stromweld
Copy link
Contributor Author

@lbajolet-hashicorp any other updates you'd like to see on this?

Stromweld and others added 2 commits February 10, 2023 15:35
Co-authored-by: Wilken Rivera <dev@wilkenrivera.com>
Signed-off-by: Corey Hemminger <hemminger@hotmail.com>
@Stromweld Stromweld requested review from nywilken and removed request for lbajolet-hashicorp February 13, 2023 17:25
@Stromweld Stromweld requested review from lbajolet-hashicorp and nywilken and removed request for nywilken and lbajolet-hashicorp February 27, 2023 22:52
@nywilken nywilken self-assigned this Mar 2, 2023
@nywilken
Copy link
Contributor

nywilken commented Mar 4, 2023

Overall this looks good. I would like to merge but I’m having trouble testing it. @Stromweld can you confirm that the modified code works as expected for your test environment , please.

@Stromweld
Copy link
Contributor Author

Stromweld commented Mar 4, 2023

@nywilken I'm having trouble with that. I swapped my m1 mac mini for a new m2 mac mini. I can't seem to get packer vmware-iso builds to provision at all. See https://github.com/chef/bento/actions/runs/4328485365/jobs/7558243945. I'm using a hard coded path that fixed the error in the plugin and was allowing the builds to run on my previous m1 mac mini. Not sure if a packer update, vmware-fusion update, or the m2 upgrade is the culprit, as all has happened while waiting to get my M2. PACKER_LOG=1 doesn't give me any additional information. I'm running the latest versions of each software. It'll take me a bit to test different versions of software to see if I can get it working again.

@nywilken
Copy link
Contributor

@nywilken I'm having trouble with that. I swapped my m1 mac mini for a new m2 mac mini. I can't seem to get packer vmware-iso builds to provision at all. See https://github.com/chef/bento/actions/runs/4328485365/jobs/7558243945. I'm using a hard coded path that fixed the error in the plugin and was allowing the builds to run on my previous m1 mac mini. Not sure if a packer update, vmware-fusion update, or the m2 upgrade is the culprit, as all has happened while waiting to get my M2. PACKER_LOG=1 doesn't give me any additional information. I'm running the latest versions of each software. It'll take me a bit to test different versions of software to see if I can get it working again.

Thanks for giving this a test run. I’m running into the same error.

I spent some time looking into it and found that the guest type needs to be set to arm-denian-64 to get the iso to take. But fusion runs into a boot issue because the scsi disk type is no longer supported. Guessing we might need to create a new driver that creates a valid vmx file for fusion 13.

@Stromweld
Copy link
Contributor Author

@nywilken So I got my templates working again by switching vmware_cdrom_adapter_type to "sata", vmware_disk_adaptor_type to "sata", and setting my ubuntu templates with vmware_guest_os_type to "arm-ubuntu-64". That got me past the service implementation error. Now how do I figure out all the guest OS types for vmware arm machines. Or is it as simple as the same as x86_64 but with "arm-" prefix now?

@nywilken
Copy link
Contributor

@Stromweld thanks for updating the PR with your latest changes. I pulled down your repo to work with it as well. I see the changes are working. I think this is in a good place to merge. But we will need to update the documentation for Fusion 13 as the adapter_types and guest_os_types changes won't be so obvious. This is a change for me tomorrow.

Copy link
Contributor

@nywilken nywilken left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The changes look good and have been validated to work.

@nywilken nywilken dismissed lbajolet-hashicorp’s stale review April 10, 2023 21:11

The changes have been applied and the plugin works as expected.

@nywilken nywilken changed the title fix: vmware tools iso path for fusion 13 fix: vmware tools iso path for Fusion 13 Apr 10, 2023
@nywilken nywilken added the bug label Apr 10, 2023
@nywilken nywilken merged commit 773b143 into hashicorp:main Apr 10, 2023
@Stromweld
Copy link
Contributor Author

Thanks for the update

@Stromweld Stromweld deleted the patch-1 branch April 10, 2023 22:38
@nywilken
Copy link
Contributor

Thanks for the update

@Stromweld maybe you can help me out. I reinstalled Fusion 13.0.1 and I am finding that my builds (M1 pro) freeze at the grub menu. I'm using the bento packer templates. Did you run into this issue?

If so is there something outside of Packer that I need to do to get things working?

@Stromweld
Copy link
Contributor Author

@nywilken Sorry just saw this now, I did run into the same issue and found from another user some config changes that are needed for arm builds to work. I've incorporated those into recent bento packer templates. There is still a lot more work that needs to be done on the arm variables/templates that I haven't gotten around to. Several machines are building on arm now for both parallels and vmware. My focus is getting the x86_64 builds all working correctly for parallels, virtualbox, and vmware, then focusing on arm, and then hyper-v and qemu. Doing this as side work so it's slow going.

@hashicorp hashicorp locked and limited conversation to collaborators Jun 29, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Plugin doesn't find tools ISOs on Fusion 13
5 participants