gpt4 book ai didi

Azure存储: Error checking for existence of existing Storage Share

转载 作者:行者123 更新时间:2023-12-02 07:00:15 33 4
gpt4 key购买 nike

我正在尝试使用 Terraform 配置 Azure 存储帐户和文件共享:

resource "random_pet" "prefix" {}

provider "azurerm" {
version = "~>2.25.0"
features {}
}

resource "azurerm_resource_group" "default" {
name = "${random_pet.prefix.id}-rg"
location = "australiaeast"
}


resource "azurerm_storage_account" "default" {
name = replace("${random_pet.prefix.id}storage", "-", "")
resource_group_name = azurerm_resource_group.default.name
location = azurerm_resource_group.default.location
account_tier = "Premium"
account_replication_type = "LRS"
}

resource "azurerm_storage_share" "default" {
name = "${azurerm_storage_account.default.name}share"
storage_account_name = azurerm_storage_account.default.name
}

但是,我在尝试申请时遇到以下错误:

Error: Error checking for existence of existing Storage Share "patientducklingstorageshare" (Account "patientducklingstorage" / Resource Group "patient-duckling-rg"): shares.Client#GetProperties: Failure sending request: StatusCode=0 -- Original Error: Get "https://patientducklingstorage.file.core.windows.net/patientducklingstorageshare?restype=share": dial tcp: lookup patientducklingstorage.file.core.windows.net on 192.168.1.1:53: no such host

on aks-cluster.tf line 22, in resource "azurerm_storage_share" "default":
61: resource "azurerm_storage_share" "default" {
``

最佳答案

此问题已通过运行 terraform init 得到解决。

关于Azure存储: Error checking for existence of existing Storage Share,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/65101461/

33 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com