Terraform-provider-azurerm: Provider incompatible with terraform 0.12.x

Created on 16 Jan 2019  ·  5Comments  ·  Source: terraform-providers/terraform-provider-azurerm

Replacing the vendor tree here via (from https://github.com/hashicorp/terraform/issues/19221):

cd $GOPATH/src/github.com/terraform-providers
git clone https://github.com/terraform-providers/terraform-provider-azurerm.git
cd terraform-provider-azurerm
rm -rf vendor
govendor init
govendor fetch github.com/hashicorp/terraform/...@=v0.12.0-alpha2
govendor fetch +m
go build

Results in a clean compile. However, attempting to use the provider results in:

2019-01-16T08:54:41.914-0700 [DEBUG] plugin: starting plugin: path=/Users/pcj/go/src/github.com/terraform-providers/terraform-provider-azurerm/terraform-provider-azurerm args=[/Users/pcj/go/src/github.com/terraform-providers/terraform-provider-azurerm/terraform-provider-azurerm]
2019-01-16T08:54:41.920-0700 [DEBUG] plugin: plugin started: path=/Users/pcj/go/src/github.com/terraform-providers/terraform-provider-azurerm/terraform-provider-azurerm pid=21256
2019-01-16T08:54:41.920-0700 [DEBUG] plugin: waiting for RPC address: path=/Users/pcj/go/src/github.com/terraform-providers/terraform-provider-azurerm/terraform-provider-azurerm
2019-01-16T08:54:41.949-0700 [INFO]  plugin.terraform-provider-azurerm: configuring server automatic mTLS: timestamp=2019-01-16T08:54:41.949-0700
2019-01-16T08:54:41.983-0700 [DEBUG] plugin.terraform-provider-azurerm: plugin address: address=/var/folders/ft/hhfr3jns16n3g89p5j86zy6h0000gn/T/plugin112259503 network=unix timestamp=2019-01-16T08:54:41.983-0700
2019-01-16T08:54:41.983-0700 [DEBUG] plugin: using plugin: version=5
2019/01/16 08:54:41 [TRACE] GRPCProvider: GetSchema
2019/01/16 08:54:42 [TRACE] GRPCProvider: Close
2019-01-16T08:54:42.053-0700 [DEBUG] plugin: plugin process exited: path=/Users/pcj/go/src/github.com/terraform-providers/terraform-provider-azurerm/terraform-provider-azurerm pid=21256
2019-01-16T08:54:42.053-0700 [DEBUG] plugin: plugin exited
[tf-err]:
Error: Failed to retrieve schema from provider "azurerm": rpc error: code = Unimplemented desc = unknown service tfplugin5.Provider

What's the roadmap getting this provider compatible with terraform 0.12.x?

question upstream-terraform

Most helpful comment

It's a long shot, but you may want to replace this line

govendor fetch github.com/hashicorp/terraform/...@=v0.12.0-alpha2

with

govendor fetch github.com/hashicorp/terraform/...

This will use the latest code from the master branch, instead of an older alpha2 version.

The errors you're seeing could be fixed in the provider plugin, or equally likely it could be the 0.12 alpha2 code is still rough around the edges for your use case.

Also, if you try this, be sure the terraform binary itself is freshly built from the master branch too.

All 5 comments

It's a long shot, but you may want to replace this line

govendor fetch github.com/hashicorp/terraform/...@=v0.12.0-alpha2

with

govendor fetch github.com/hashicorp/terraform/...

This will use the latest code from the master branch, instead of an older alpha2 version.

The errors you're seeing could be fixed in the provider plugin, or equally likely it could be the 0.12 alpha2 code is still rough around the edges for your use case.

Also, if you try this, be sure the terraform binary itself is freshly built from the master branch too.

hi @pcj

Thanks for opening this issue :)

There's been changes in the Protocol between the initial Alpha releases (e.g. Alpha 1 and Alpha 2) and the current WIP state. Whilst this may potentially work by upgrading to the latest branch pluginsdk-v0.12-early2 (or even master as @sjwl has suggested) - unfortunately the upstream branch is still in development and as such we're unable to offer support with upgrading to this at this time. That said - if vendoring to that release doesn't work for you I'd suggest opening an issue on the main repository where the Core team should be able to assist you further.

What's the roadmap getting this provider compatible with terraform 0.12.x?

We're not planning on shipping support for Terraform 0.12 in this provider until the first Beta of 0.12 ships, however at this point the main blocker is the fact that the Provider SDK is a moving target (since it's still under development). From our side we're planning on migrating to Go Modules first (since these have been adopted in Terraform Core, these mean we can better obtain the transitive dependencies) and then to the new Provider SDK in the future.

Since this is a question related to 0.12 (which isn't officially supported by this Provider at this time) - I'm going to close this issue but I'd like to thank you for your interest here. As mentioned above if the vendor step mentioned above doesn't work for you then please file an issue on the Terraform Core repo and we'll try our best to help you there :)

Thanks!

OK thanks for the update. Yes the dependencies look quite different from 0.11

Vendoring works for me, at least it seems to work.

cd $GOPATH/src/github.com/terraform-providers
git clone https://github.com/terraform-providers/terraform-provider-azurerm.git
cd terraform-provider-azurerm
rm -rf vendor
govendor init
govendor fetch github.com/hashicorp/terraform/...
govendor fetch +m
go build

Hopefully I can find this again, next time I need it....

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 feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. If you feel I made an error 🤖 🙉 , please reach out to my human friends 👉 [email protected]. Thanks!

Was this page helpful?
0 / 5 - 0 ratings