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

Add support for moid attribute in vsphere_virtual_machine data source #1867

Closed
4 tasks done
sestegra opened this issue Mar 24, 2023 · 1 comment · Fixed by #1868
Closed
4 tasks done

Add support for moid attribute in vsphere_virtual_machine data source #1867

sestegra opened this issue Mar 24, 2023 · 1 comment · Fixed by #1868
Labels
enhancement Type: Enhancement

Comments

@sestegra
Copy link
Contributor

sestegra commented Mar 24, 2023

Community Guidelines

  • I have read and agree to the HashiCorp Community Guidelines .
  • Vote on this issue by adding a 👍 reaction to the original issue initial description to help the maintainers prioritize.
  • Do not leave "+1" or other comments that do not add relevant information or questions.
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment.

Description

When querying virtual machine by tags using vsphere_dynamic data source, the returned value type is Managed Object Id.

In the current implementation of vsphere_virtual_machine data source, the only wsys to get it is by name or by UUID.

So, the attribute moid should be exposed on vsphere_virtual_machine data source.

Use Case(s)

  • Query a VM by tag (using vsphere_dynamic data source
  • Use vsphere_virtual_machine data source to get the VM
  • Clone the VM using vsphere_virtual_machine resource

Potential Terraform Provider Configuration

data "vsphere_virtual_machine" "template" {
  moid = "VirtualMachine:vm-19116"
}

References

No response

@github-actions
Copy link

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 14, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement Type: Enhancement
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant