首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >Terraform找不到% 1password模块

Terraform找不到% 1password模块
EN

Stack Overflow用户
提问于 2021-03-03 03:02:43
回答 1查看 99关注 0票数 0

我正在尝试通过以下方式使用Terraform的1Password提供程序:

代码语言:javascript
复制
 terraform {
   required_providers {
     onepassword = {
       source  = "milosbackonja/1password"
       version = "1.1.0"
     }
   }
   required_version = "~> 0.14"

   backend "remote" {
     organization = "my-co"

     workspaces {
       prefix = "my-"
     }
   }
 }

 provider "onepassword" {
   email      = "email@email.com"
   password   = var.onepassword_master_pass
   secret_key = var.onepassword_secret_key
   subdomain  = "mycompany"
 }

Terraform似乎找到了提供程序并安装了它,但是我收到一个错误,说找不到它:

代码语言:javascript
复制
Initializing modules...
- onepassword in onepassword

Initializing the backend...

Successfully configured the backend "remote"! Terraform will automatically
use this backend unless the backend configuration changes.

Initializing provider plugins...
- Finding latest version of hashicorp/onepassword...
- Finding hashicorp/aws versions matching "3.30.0"...
- Finding milosbackonja/1password versions matching "1.1.0"...
- Installing hashicorp/aws v3.30.0...
- Installed hashicorp/aws v3.30.0 (signed by HashiCorp)
- Installing milosbackonja/1password v1.1.0...
- Installed milosbackonja/1password v1.1.0 (self-signed, key ID 5B6898F46775F746)

Partner and community providers are signed by their developers.
If you'd like to know more about provider signing, you can read about it here:
https://www.terraform.io/docs/cli/plugins/signing.html

Error: Failed to query available provider packages

Could not retrieve the list of available versions for provider
hashicorp/onepassword: provider registry registry.terraform.io does not have a
provider named registry.terraform.io/hashicorp/onepassword

If you have just upgraded directly from Terraform v0.12 to Terraform v0.14
then please upgrade to Terraform v0.13 first and follow the upgrade guide for
that release, which might help you address this problem.

Error: Terraform exited with code 1.
Error: Process completed with exit code 1.

有什么建议吗?

EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2021-03-04 09:50:11

您的配置中似乎有另一个模块试图在不声明依赖项的情况下使用此提供程序。

您可以运行terraform providers来查看每个模块依赖于哪些提供者。注意任何列出hashicorp/1password而不是milosbackonja/1password的列表,并更新它们中的每一个,以包括与您在此处的问题中显示的类似的required_providers块,尽管在共享模块中,我们通常使用>=版本约束而不是确切的版本约束,以便在将来需要升级提供程序时避免协调问题。

票数 1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/66445537

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档