Documentation
¶
Overview ¶
Terraform provider for Hyper-V. This is the entry point; real provider behavior lives under internal/provider. This file does only the minimum needed for `terraform init` to discover us: parse a -debug flag, then hand off to providerserver.Serve.
Directories
¶
| Path | Synopsis |
|---|---|
|
hack
|
|
|
bench-run
command
Maintainer-only WinRM script runner against the Hyper-V bench, for arbitrary PowerShell without a full terraform plan/apply.
|
Maintainer-only WinRM script runner against the Hyper-V bench, for arbitrary PowerShell without a full terraform plan/apply. |
|
krb5-probe
command
Maintainer-only diagnostic: exercises gokrb5's password-mode AS-REQ directly, with verbose error reporting, to disambiguate AD-vs-gokrb5 preauth issues from masterzen/winrm wrapping noise.
|
Maintainer-only diagnostic: exercises gokrb5's password-mode AS-REQ directly, with verbose error reporting, to disambiguate AD-vs-gokrb5 preauth issues from masterzen/winrm wrapping noise. |
|
lint-comments
command
Comment-style gate for CLAUDE.md's code-comment rules.
|
Comment-style gate for CLAUDE.md's code-comment rules. |
|
ssh-probe
command
|
|
|
internal
|
|
|
acctest
Package acctest provides acceptance-test scaffolding shared across resource packages.
|
Package acctest provides acceptance-test scaffolding shared across resource packages. |
|
connection
Package connection defines the transport abstraction the typed Hyper-V client (internal/hyperv) uses to ship PowerShell scripts to a Windows host and read their results back.
|
Package connection defines the transport abstraction the typed Hyper-V client (internal/hyperv) uses to ship PowerShell scripts to a Windows host and read their results back. |
|
datasources/host
Package host implements the hyperv_host data source — read-only information about the Hyper-V host.
|
Package host implements the hyperv_host data source — read-only information about the Hyper-V host. |
|
datasources/iso_volume
Package iso_volume implements the data.hyperv_iso_volume data source: pure runner-side synthesis of a deterministic ISO9660 volume from (volume_label, files) inputs, exposed as bytes (base64), sha256, and size.
|
Package iso_volume implements the data.hyperv_iso_volume data source: pure runner-side synthesis of a deterministic ISO9660 volume from (volume_label, files) inputs, exposed as bytes (base64), sha256, and size. |
|
datasources/vm_state
Package vm_state implements the hyperv_vm_state data source: read-only power-state plus IP-address lookup for an existing VM by name, for HCL conditionals and downstream resources that gate on live VM state without managing the VM.
|
Package vm_state implements the hyperv_vm_state data source: read-only power-state plus IP-address lookup for an existing VM by name, for HCL conditionals and downstream resources that gate on live VM state without managing the VM. |
|
datasources/vswitch
Package vswitch implements the hyperv_virtual_switch data source: read-only access to an existing switch by name.
|
Package vswitch implements the hyperv_virtual_switch data source: read-only access to an existing switch by name. |
|
hyperv
Package hyperv is the typed Go wrapper over the connection layer.
|
Package hyperv is the typed Go wrapper over the connection layer. |
|
iso
Package iso synthesizes deterministic ISO9660 volumes on the runner for the data.hyperv_iso_volume data source: same volume_label + files map always produces byte-identical output, so sha256 stays stable across applies and the runner-streamed transport-corruption check never false-positives.
|
Package iso synthesizes deterministic ISO9660 volumes on the runner for the data.hyperv_iso_volume data source: same volume_label + files map always produces byte-identical output, so sha256 stays stable across applies and the runner-streamed transport-corruption check never false-positives. |
|
provider
Package provider implements the Hyper-V Terraform provider.
|
Package provider implements the Hyper-V Terraform provider. |
|
resources/image_file
Package image_file implements the hyperv_image_file resource.
|
Package image_file implements the hyperv_image_file resource. |
|
resources/nat_static_mapping
Package nat_static_mapping implements the hyperv_nat_static_mapping resource.
|
Package nat_static_mapping implements the hyperv_nat_static_mapping resource. |
|
resources/vhd
Package vhd implements the hyperv_vhd resource.
|
Package vhd implements the hyperv_vhd resource. |
|
resources/vm
Package vm implements the hyperv_vm resource, wrapping the vm/{get,new,set,remove}.ps1 contract via the typed hyperv.Client.
|
Package vm implements the hyperv_vm resource, wrapping the vm/{get,new,set,remove}.ps1 contract via the typed hyperv.Client. |
|
resources/vswitch
Package vswitch implements the hyperv_virtual_switch resource.
|
Package vswitch implements the hyperv_virtual_switch resource. |
|
scripts
Package scripts embeds the PowerShell scripts the provider runs against the host, one subdirectory per resource family.
|
Package scripts embeds the PowerShell scripts the provider runs against the host, one subdirectory per resource family. |
|
testutil
Package testutil provides shared test helpers — primarily a deterministic fake of connection.Runner that lets typed-client tests exercise the JSON contract without needing a real Hyper-V host or even a real pwsh binary.
|
Package testutil provides shared test helpers — primarily a deterministic fake of connection.Runner that lets typed-client tests exercise the JSON contract without needing a real Hyper-V host or even a real pwsh binary. |
|
typeflatten
Package typeflatten holds small helpers that translate typed hyperv-client DTOs into terraform-plugin-framework types.List / types.Object values.
|
Package typeflatten holds small helpers that translate typed hyperv-client DTOs into terraform-plugin-framework types.List / types.Object values. |
|
types/mac
Package mac provides a Terraform attribute type for MAC addresses that suppresses spurious plan-vs-apply diffs from cosmetic representation differences.
|
Package mac provides a Terraform attribute type for MAC addresses that suppresses spurious plan-vs-apply diffs from cosmetic representation differences. |
|
types/path
Package path provides a Terraform attribute type for Windows file paths that suppresses spurious plan-vs-apply diffs from cosmetic representation differences.
|
Package path provides a Terraform attribute type for Windows file paths that suppresses spurious plan-vs-apply diffs from cosmetic representation differences. |
Click to show internal directories.
Click to hide internal directories.