-
Notifications
You must be signed in to change notification settings - Fork 95
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
vsphere-iso
: docs are insufficient for iso_paths
with a content library
#313
Comments
Documentation should advise that there are three parts, content library name, item name, and file name, and these can be retrieved from govc library.ls command
and use the final output minus the leading Note: this is also because of a poor UX in vCenter/Content Libraries. When you are looking at the "Item", no where do you see a file name. |
I don't think that there's a need for the
➜ govc library.ls -json /m01-cl01/ubuntu-22.04.3-live-server-amd64 | jq .
[
{
"cached": true,
"content_version": "2",
"creation_time": "2023-10-20T00:55:46.228Z",
"description": "",
"id": "7b1af331-0bb6-4a09-afd3-b46a59f51d6b",
"last_modified_time": "2023-10-20T01:06:12.638Z",
"library_id": "c9ac8ddf-3650-492a-9c22-d1c88df3d975",
"metadata_version": "1",
"name": "ubuntu-22.04.3-live-server-amd64",
"size": 2133391360,
"type": "iso",
"version": "1",
"security_compliance": true,
"certificate_verification_info": {
"status": "NOT_AVAILABLE"
}
}
] You need: iso_paths = "[<datastore_name>] contentlib-<library-guid>/<item-guid>/<item_name>_<other-guid>.iso The location can be seen in the vSphere Client: ![]() Example: iso_paths = "[local-ssd-01] contentlib-c9ac8ddf-3650-492a-9c22-d1c88df3d975>/7b1af331-0bb6-4a09-afd3-b46a59f51d6b/ubuntu-22.04.3-live-server-amd64_88cfaf0c-e0aa-4506-b4c6-172d33cc4dc0.iso Refer to this enhancement request to support data sources in the plugin which would be a cleaner approach to retrieving the item path. |
vsphere-iso
: doc are insufficient for iso_paths
with a content library
vsphere-iso
: doc are insufficient for iso_paths
with a content libraryvsphere-iso
: docs are insufficient for iso_paths
with a content library
My point is, that in content libraries, there are item names, and file names, and both must be referenced in the So I think that's the difference in your point of view, because you are looking at the datastore, and the reference on your screen, but I was looking at the content library screen, which does not show the file name, only the item name. |
Fair point. I think perhaps I happened to immediately know where to look and/or query myself. Adding this to the documentation would be trivial and I can look at it next week if time permits. Ryan Johnson |
here is my suggestion for the docs: (or something similar)
|
When filing a bug please include the following headings, if possible.
code:
iso_paths = ["ag6hq-cl/ubuntu-22.04.3-live-server-amd64.iso"]
results in this error:
Overview of the Issue
I have a two host vCenter. I created a content library, backed by a local datastore of one of the hosts.
I uploaded an Ubuntu ISO to the content library, and specified the the output of
govc library.ls ag6hq-cl/
(minus the leading /) in the iso_paths as shown above.I have tried inserting /iso/ and /ISO/ in the path between.
And then, while writing this, I recalled that vSphere chopped the
.iso
off the name, so I added it back in.That made me think that's the second level you are looking for in the code (yea, I dug through the code best I could)
The Correct name now is:
because I add the
.iso
back in when I was importing the file to the field "item name".Reproduction Steps
I think I described them pretty well above.
Packer Version
packer=1.9.2
Plugin Version and Builders
Please provide the plugin version.
packer-plugin-vsphere=1.2.1
Please select the builder.
vsphere-iso
vsphere-clone
VMware vSphere Version
Please provide the VMware vSphere version.
7.0.3n
Guest Operating System
Ubuntu 22.04 LTS x64
Simplified Packer Buildfile
If the file is longer than a few dozen lines, please include the URL to the gist of the log or use the GitHub detailed format instead of posting it directly in the issue.
Operating System and Environment Details
Please add any information you can provide about the environment.
MacOS 13.5.2 (Intel)
Log Fragments and
crash.log
FilesInclude appropriate log fragments. If the log is longer than a few dozen lines, please include the URL to the gist of the log or use the Github detailed format instead of posting it directly in the issue.
Set the env var
PACKER_LOG=1
for maximum log detail.The text was updated successfully, but these errors were encountered: