简体   繁体   English

如何在 terraform aws 中添加提供者?

[英]How to add providers in terraform aws?

This is the error I'm getting:这是我得到的错误:

Failed to query available provider packages

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

For terraform > 0.13 you need to add a required_providers snippet for any un-official provider (un-official means not owned by HashiCorp and not part of their registry).对于 terraform > 0.13,您需要为任何非官方提供者添加 required_providers 片段(非官方意味着不属于 HashiCorp 并且不属于其注册表的一部分)。 There was one supported by HashiCorp but it is discontinued (you could potentially use it if you downgrade to TF12). HashiCorp 支持其中一个,但已停产(如果您降级到 TF12,您可能会使用它)。

If you are aware of a community provided one a code snippet similar to the one for docker below should suffice:如果您知道社区提供了一个类似于 docker 的代码片段,那么下面的代码片段就足够了:

terraform {
  required_providers {
    docker = {
      source = "kreuzwerker/docker"
    }
  }
}

where in source you will give a link to the provider source repo/registry.在源代码中,您将提供指向提供程序源存储库/注册表的链接。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 Terraform MySQL 提供程序“错误:无法安装提供程序” - Terraform MySQL provider 'Error: Failed to install providers' 使用Terraform创建AWS MySQL RDS实例时出错 - Error creating AWS MySQL RDS instance with Terraform 如何添加 AWS RDS 数据库进行放大 - How to add a AWS RDS database to amplify Terraform AWS Aurora 无服务器 MySQL - 错误:无效的数据库引擎 - Terraform AWS Aurora Serverless MySQL - Error: Invalid DB Engine 如何从AWS实例读取密钥并将其添加到我的MySQL查询中? - How to read key from aws instance and add into my mysql query? AWS RDS 只读机——如何添加新用户 - AWS RDS read-only machine -- how to add new user 如何在 EC2 AWS 上为 Python 脚本添加 cronjob/调度程序? - How to add cronjob/scheduler for Python scripts on EC2 AWS? 如何向 AWS RDS Aurora-Serverless 添加存储过程? - How to add a Stored Procedure to AWS RDS Aurora-Serverless? 如何使用数据提供程序实现php-mysql数据分页 - How to implement php-mysql data pagination using data providers 如何比较两个不同提供者的两个不同数据库之间的数据? - How to compare data between two different database of two different providers?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM