Azure Container appをTerraformで実現したい
解決したいこと
Azure Container appをTerraformで実現したい。
元はhttps://registry.terraform.io/providers/hashicorp/azurerm/latest/docs/resources/container_app
です。
発生している問題・エラー
Error: polling after CreateOrUpdate: executing request: unexpected status 404 (404 Not Found) with error: ResourceNotFound: The Resource 'Microsoft.OperationalInsights/workspaces/acctest-01' under resource group 'example-resources' was not found. For more details please go to https://aka.ms/ARMResourceNotFoundFix
│
│ with azurerm_log_analytics_workspace.example,
│ on main.tf line 11, in resource "azurerm_log_analytics_workspace" "example":
│ 11: resource "azurerm_log_analytics_workspace" "example" {
main.tf
provider "azurerm" {
subscription_id=""
features {}
}
resource "azurerm_resource_group" "example" {
name = "example-resources"
location = "West Europe"
}
resource "azurerm_log_analytics_workspace" "example" {
name = "acctest-01"
location = azurerm_resource_group.example.location
resource_group_name = azurerm_resource_group.example.name
sku = "PerGB2018"
retention_in_days = 30
}
resource "azurerm_container_app_environment" "example" {
name = "Example-Environment"
location = azurerm_resource_group.example.location
resource_group_name = azurerm_resource_group.example.name
log_analytics_workspace_id = azurerm_log_analytics_workspace.example.id
}
resource "azurerm_container_app" "example" {
name = "example-app"
container_app_environment_id = azurerm_container_app_environment.example.id
resource_group_name = azurerm_resource_group.example.name
revision_mode = "Single"
template {
container {
name = "examplecontainerapp"
image = "mcr.microsoft.com/k8se/quickstart:latest"
cpu = 1
memory = "1Gi"
}
}
}
自分で試したこと
CPU、メモリーを変更した。
0