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

Allow the usage of .iso files from a Content Library with device.cdrom.insert #3213

Closed
Goose29 opened this issue Aug 23, 2023 · 4 comments · Fixed by #3462
Closed

Allow the usage of .iso files from a Content Library with device.cdrom.insert #3213

Goose29 opened this issue Aug 23, 2023 · 4 comments · Fixed by #3462

Comments

@Goose29
Copy link

Goose29 commented Aug 23, 2023

Is your feature request related to a problem? Please describe.

In a previous issue found here the desired outcome was discussed and proposed, but a hacky solution was chosen (govc device.cdrom.insert -vm $vm -device cdrom-3000 $(govc library.info -L /lib1/item1/file1)) and the issue was closed. The solution previously proposed, which was to use library.info -L to get the path does not work for me (which is also the example used with the --help of the command) to mount a .iso from a content library through device.cdrom.insert. This method results in a no media found screen, the file referenced exists, and can be queried through a library.info call with the full path.

Describe the solution you'd like

I would like a solution that can reference the .iso file directly within the device.cdrom.insert command, without making a separate call to the datastore to get its path (this call doesn't work in my case). There were excellent proposed ideas in the above linked issue, but in the end I would like it to use the Content Library ISO File native feature.

Describe alternatives you've considered

I am not entirely sure what alternatives there are, I have tried the officially stated method to get a iso mounted through vm.create and then device.cdrom.insert which just ends in a no media found screen on boot. And I am not able to figure out what was meant in the last comment on the issue, so his workaround is unknown, I assume he somehow found the absolute path to the datastore itself, and not the datastore path of the .iso file... which I have not been able to find through govc commands.

Additional context

N/A

@github-actions
Copy link
Contributor

Howdy 🖐   Goose29 ! Thank you for your interest in this project. We value your feedback and will respond soon.

If you want to contribute to this project, please make yourself familiar with the CONTRIBUTION guidelines.

@Goose29 Goose29 changed the title Allow the usage of .iso files from a Content Library with vm.create Allow the usage of .iso files from a Content Library with device.cdrom.insert Aug 23, 2023
@Goose29
Copy link
Author

Goose29 commented Aug 24, 2023

Alternatively, maybe introduce a way to use .iso files from a content library through the library.deploy command.

Copy link
Contributor

This issue is stale because it has been open for 90 days with no
activity. It will automatically close after 30 more days of
inactivity. Mark as fresh by adding the comment /remove-lifecycle stale.

@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale Dec 24, 2023
@dougm dougm reopened this May 31, 2024
dougm added a commit to dougm/govmomi that referenced this issue Jun 3, 2024
govc: support Content Library iso files for cdrom backing

The 'device.cdrom.insert' and 'vm.create -iso' commands can now a URL
with 'library' scheme to back a cdrom device from a Content Library.

api: refactor 'library.info -L' functionality into library PathFinder helper.

Fixes vmware#3213
dougm added a commit to dougm/govmomi that referenced this issue Jun 3, 2024
govc: support Content Library iso files for cdrom backing

The 'device.cdrom.insert' and 'vm.create -iso' commands can now a URL
with 'library' scheme to back a cdrom device from a Content Library.

api: refactor 'library.info -L' functionality into library PathFinder helper.

Fixes vmware#3213
dougm added a commit to dougm/govmomi that referenced this issue Jun 3, 2024
govc: support Content Library iso files for cdrom backing

The 'device.cdrom.insert' and 'vm.create -iso' commands can now a URL
with 'library' scheme to back a cdrom device from a Content Library.

api: refactor 'library.info -L' functionality into library PathFinder helper.

Fixes vmware#3213
dougm added a commit to dougm/govmomi that referenced this issue Jun 4, 2024
govc: support Content Library iso files for cdrom backing

The 'device.cdrom.insert' and 'vm.create -iso' commands can now a URL
with 'library' scheme to back a cdrom device from a Content Library.

api: refactor 'library.info -L' functionality into library PathFinder helper.

Fixes vmware#3213
@dougm
Copy link
Member

dougm commented Jun 4, 2024

Next release will include support for using a library: URL, see examples:
https://github.com/vmware/govmomi/blob/main/govc/USAGE.md#devicecdrominsert
https://github.com/vmware/govmomi/blob/main/govc/USAGE.md#vmcreate

This library: URL is resolved using the same code as library.info -l -L. But removed the insert example from the doc there:
https://github.com/vmware/govmomi/blob/main/govc/USAGE.md#libraryinfo

The issue you had earlier was likely vm and CL on different datastores (need -l to include the datastore)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants