Traffic Manager をデプロイするときにエラーが発生します。それは非常に基本的な構成かもしれません。ただし、不明なサービスエラーと表示されます。これを修正する手がかりがありません。
Terraform Version
Terraform v0.10.0
# サービスの原則
variable "subscription_id" {}
variable "client_id" {}
variable "client_secret" {}
variable "tenant_id" {}
リソース グループ
変数 "resource_group" {}
変数「場所」{}
変数「環境」{}
実際のスクリプト
# Service Principle
provider "azurerm" {
subscription_id = "${var.subscription_id}"
client_id = "${var.client_id}"
client_secret = "${var.client_secret}"
tenant_id = "${var.tenant_id}"
}
# Traffic Manager Profile
resource "azurerm_traffic_manager_profile" "profile" {
name = "trafficmanagerprofile"
resource_group_name = "production"
traffic_routing_method = "Weighted"
dns_config {
relative_name = "production"
ttl = 30
}
monitor_config {
protocol = "http"
port = 80
path = "/"
}
}
resource "azurerm_public_ip" "pip" {
name = "ip${count.index}"
location = "${var.azure_region}"
resource_group_name = "production"
public_ip_address_allocation = "dynamic"
domain_name_label = "${var.dns_name}${count.index}"
count = "${var.num_vms}"
}
resource "azurerm_traffic_manager_endpoint" "endpoint" {
name = "endpoint${count.index}"
resource_group_name = "production"
profile_name = "${azurerm_traffic_manager_profile.profile.name}"
target_resource_id = "${element(azurerm_public_ip.pip.*.id, count.index)}"
type = "azureEndpoints"
weight = 1
count = "${var.num_vms}"
}
Debug Output
Error: autorest/azure: Service returned an error. Status=400 Code="Unknown" Message="Unknown service error"
予想される行動
It should be create a Traffic Manager Profile instance on Azure
実際の動作
Resource Group created but traffic manager profile throws error.
I am struggling with this from long time can anybody help me out here?