0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

Azure Database for MySQLをTerraformで作る

Last updated at Posted at 2024-12-09

Azure Database for MySQLをTerraformで作りました。

main.tf
provider "azurerm" {
  subscription_id=""
  features {}
}

resource "azurerm_resource_group" "example" {
  name     = "example-resource-group"
  location = "Japan East"
}

resource "azurerm_mysql_flexible_server" "example" {
  name                 = "example-mysql-server"
  location             = azurerm_resource_group.example.location
  resource_group_name  = azurerm_resource_group.example.name
  administrator_login = "your_admin_user"
  administrator_password = "MyStr0ngP@ssw0rd123"
  sku_name              = "GP_Standard_D2ds_v4"
  backup_retention_days = 7
  version               = "8.0.21"
}

sku_nameに悩みましたが、これでいけました。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?