Quantcast
Channel: Rob V IT
Viewing all articles
Browse latest Browse all 64

A provider named “” could not be found in the Terraform Registry.

$
0
0

After installing Terraform and GO. I want to talk with my Hyper-v server for deploying some VMs.

I used this provider: https://github.com/taliesins/terraform-provider-hyperv.git

How to Install the Hyperv provider:

mkdir -p $env:GOPATH/src/github.com/taliesins; cd $env:GOPATH/src/github.com/taliesins
 git clone https://github.com/taliesins/terraform-provider-hyperv.git
 cd $env:GOPATH/src/github.com/taliesins/terraform-provider-hyperv
 go build

Now there is a file created: terraform-provider-hyperv.exe
After a terraform init you get the following message.

“A provider named “hyperv” could not be found in the Terraform Registry.”

This is because the custom provider is not installed in your default plugin directory.

The Windows default plugin directory is located in the following location: (C:\Users\YOURUSERNAME\AppData\Roaming\terraform.d\plugins\windows_amd64)

With PowerShell:

mkdir -p C:\Users\$($env:USERname)\AppData\Roaming\terraform.d\plugins\windows_amd64

Copy the (terraform-provider-hyperv.exe) file you created with the go build in the plugin folder.

Now navigate to your cloned git directory \ examples \ basic and do a terraform init.

The post A provider named “” could not be found in the Terraform Registry. appeared first on Rob V IT.


Viewing all articles
Browse latest Browse all 64

Trending Articles