Share via


Microsoft.DBforMariaDB 伺服器 2018-06-01

Bicep 資源定義

伺服器資源類型可以部署到:

如需每個 API 版本中已變更屬性的清單,請參閱 變更記錄檔。

資源格式

若要建立 Microsoft.DBforMariaDB/servers 資源,請將下列 Bicep 新增至範本。

resource symbolicname 'Microsoft.DBforMariaDB/servers@2018-06-01' = {
  name: 'string'
  location: 'string'
  tags: {
    tagName1: 'tagValue1'
    tagName2: 'tagValue2'
  }
  sku: {
    capacity: int
    family: 'string'
    name: 'string'
    size: 'string'
    tier: 'string'
  }
  properties: {
    minimalTlsVersion: 'string'
    publicNetworkAccess: 'string'
    sslEnforcement: 'string'
    storageProfile: {
      backupRetentionDays: int
      geoRedundantBackup: 'string'
      storageAutogrow: 'string'
      storageMB: int
    }
    version: 'string'
    createMode: 'string'
    // For remaining properties, see ServerPropertiesForCreateOrServerProperties objects
  }
}

ServerPropertiesForCreateOrServerProperties 物件

設定 createMode 屬性以指定物件的類型。

針對 [預設],請使用:

  createMode: 'Default'
  administratorLogin: 'string'
  administratorLoginPassword: 'string'

針對 GeoRestore,請使用:

  createMode: 'GeoRestore'
  sourceServerId: 'string'

針對 PointInTimeRestore,請使用:

  createMode: 'PointInTimeRestore'
  restorePointInTime: 'string'
  sourceServerId: 'string'

針對 [複本],請使用:

  createMode: 'Replica'
  sourceServerId: 'string'

屬性值

servers

名稱 描述
NAME 資源名稱 需要字串 ()

字元限制:3-63

有效字元:
小寫字母、連字號和數字。

不能以連字號開頭或結尾。

資源名稱在整個 Azure 中必須是唯一的。
location 資源所在的位置。 需要字串 ()
tags 索引鍵/值組形式的應用程式特有中繼資料。 標記名稱和值的字典。 請參閱 範本中的標籤
sku SKU (伺服器) 定價層。 Sku
properties 伺服器的屬性。 ServerPropertiesForCreateOrServerProperties (必要)

ServerPropertiesForCreateOrServerProperties

名稱 描述
minimalTlsVersion 為伺服器強制執行最低 Tls 版本。 'TLS1_0'
'TLS1_1'
'TLS1_2'
'TLSEnforcementDisabled'
publicNetworkAccess 此伺服器是否允許公用網路存取。 值是選擇性的,但如果傳入,則必須是 'Enabled' 或 'Disabled' 'Disabled'
'Enabled'
sslEnforcement 在連線到伺服器時啟用 SSL 強制執行。 'Disabled'
'Enabled'
storageProfile 伺服器的儲存體設定檔。 StorageProfile
version 伺服器版本。 '10.2'
'10.3'
createMode 設定物件類型 預設值
GeoRestore
PointInTimeRestore
需要本 ()

StorageProfile

名稱 描述
backupRetentionDays 伺服器的備份保留天數。 int
geoRedundantBackup 針對伺服器備份啟用異地備援或不啟用。 'Disabled'
'Enabled'
storageAutogrow 啟用儲存體自動成長。 'Disabled'
'Enabled'
storageMB 伺服器允許的最大儲存體。 int

ServerPropertiesForDefaultCreate

名稱 描述
createMode 建立新伺服器的模式。 必要) 'Default' (
administratorLogin 伺服器的系統管理員登入名稱。 只有在建立伺服器 (且建立) 時,才能指定。 需要字串 ()
administratorLoginPassword 系統管理員登入的密碼。 需要字串 ()

ServerPropertiesForGeoRestore

名稱 描述
createMode 建立新伺服器的模式。 'GeoRestore' (必要)
sourceServerId 要從中還原的來源伺服器識別碼。 需要字串 ()

ServerPropertiesForRestore

名稱 描述
createMode 建立新伺服器的模式。 需要 'PointInTimeRestore' ()
restorePointInTime 還原點建立時間 (ISO8601 格式) ,並指定要從還原的時間。 需要字串 ()
sourceServerId 要從中還原的來源伺服器識別碼。 需要字串 ()

ServerPropertiesForReplica

名稱 描述
createMode 建立新伺服器的模式。 'Replica' (必要)
sourceServerId 要從中建立複本的主伺服器識別碼。 需要字串 ()

SKU

名稱 描述
處理能力 相應增加/放大容量,代表伺服器的計算單位。 int
family 硬體系列。 字串
NAME sku 的名稱,通常是階層 + 系列 + 核心,例如B_Gen4_1,GP_Gen5_8。 需要字串 ()
{1}size{2} 要適當地由資源解譯的大小程式代碼。 字串
tier 特定 SKU 的層級,例如基本層。 'Basic'
'GeneralPurpose'
'MemoryOptimized'

快速入門範本

下列快速入門範本會部署此資源類型。

[範本] 描述
使用 VNet 部署適用於 MariaDB 的 Azure 資料庫

部署至 Azure
此範本提供使用 VNet 整合部署適用于 MariaDB 的 Azure 資料庫的方法。

ARM 範本資源定義

伺服器資源類型可以部署到:

如需每個 API 版本中已變更屬性的清單,請參閱 變更記錄檔。

資源格式

若要建立 Microsoft.DBforMariaDB/servers 資源,請將下列 JSON 新增至範本。

{
  "type": "Microsoft.DBforMariaDB/servers",
  "apiVersion": "2018-06-01",
  "name": "string",
  "location": "string",
  "tags": {
    "tagName1": "tagValue1",
    "tagName2": "tagValue2"
  },
  "sku": {
    "capacity": "int",
    "family": "string",
    "name": "string",
    "size": "string",
    "tier": "string"
  },
  "properties": {
    "minimalTlsVersion": "string",
    "publicNetworkAccess": "string",
    "sslEnforcement": "string",
    "storageProfile": {
      "backupRetentionDays": "int",
      "geoRedundantBackup": "string",
      "storageAutogrow": "string",
      "storageMB": "int"
    },
    "version": "string",
    "createMode": "string"
    // For remaining properties, see ServerPropertiesForCreateOrServerProperties objects
  }
}

ServerPropertiesForCreateOrServerProperties 物件

設定 createMode 屬性以指定物件的類型。

針對 [預設],請使用:

  "createMode": "Default",
  "administratorLogin": "string",
  "administratorLoginPassword": "string"

針對 GeoRestore,請使用:

  "createMode": "GeoRestore",
  "sourceServerId": "string"

針對 PointInTimeRestore,請使用:

  "createMode": "PointInTimeRestore",
  "restorePointInTime": "string",
  "sourceServerId": "string"

針對 [複本],請使用:

  "createMode": "Replica",
  "sourceServerId": "string"

屬性值

servers

名稱 描述
type 資源類型 'Microsoft.DBforMariaDB/servers'
apiVersion 資源 API 版本 '2018-06-01'
NAME 資源名稱 需要字串 ()

字元限制:3-63

有效字元:
小寫字母、連字號和數字。

不能以連字號開頭或結尾。

資源名稱在整個 Azure 中必須是唯一的。
location 資源所在的位置。 需要字串 ()
tags 索引鍵/值組形式的應用程式特有中繼資料。 標記名稱和值的字典。 請參閱 範本中的標籤
sku SKU (伺服器) 定價層。 Sku
properties 伺服器的屬性。 ServerPropertiesForCreateOrServerProperties (必要)

ServerPropertiesForCreateOrServerProperties

名稱 描述
minimalTlsVersion 為伺服器強制執行最低 Tls 版本。 'TLS1_0'
'TLS1_1'
'TLS1_2'
'TLSEnforcementDisabled'
publicNetworkAccess 此伺服器是否允許公用網路存取。 值是選擇性的,但如果傳入,則必須是 'Enabled' 或 'Disabled' 'Disabled'
'Enabled'
sslEnforcement 在連線到伺服器時啟用 SSL 強制執行。 'Disabled'
'Enabled'
storageProfile 伺服器的儲存體設定檔。 StorageProfile
version 伺服器版本。 '10.2'
'10.3'
createMode 設定物件類型 預設值
GeoRestore
PointInTimeRestore
需要本 ()

StorageProfile

名稱 描述
backupRetentionDays 伺服器的備份保留天數。 int
geoRedundantBackup 針對伺服器備份啟用異地備援或不啟用。 'Disabled'
'Enabled'
storageAutogrow 啟用儲存體自動成長。 'Disabled'
'Enabled'
storageMB 伺服器允許的最大儲存體。 int

ServerPropertiesForDefaultCreate

名稱 描述
createMode 建立新伺服器的模式。 必要) 'Default' (
administratorLogin 伺服器的系統管理員登入名稱。 只有在建立伺服器 (且建立) 時,才能指定。 需要字串 ()
administratorLoginPassword 系統管理員登入的密碼。 需要字串 ()

ServerPropertiesForGeoRestore

名稱 描述
createMode 建立新伺服器的模式。 'GeoRestore' (必要)
sourceServerId 要從中還原的來源伺服器識別碼。 需要字串 ()

ServerPropertiesForRestore

名稱 描述
createMode 建立新伺服器的模式。 需要 'PointInTimeRestore' ()
restorePointInTime 還原點建立時間 (ISO8601 格式) ,並指定要從還原的時間。 需要字串 ()
sourceServerId 要從中還原的來源伺服器識別碼。 字串 (必要)

ServerPropertiesForReplica

名稱 描述
createMode 建立新伺服器的模式。 需要 'Replica' ()
sourceServerId 要從中建立複本的主伺服器識別碼。 字串 (必要)

SKU

名稱 描述
處理能力 相應增加/放大容量,代表伺服器的計算單位。 int
family 硬體系列。 字串
NAME sku 的名稱,通常是層 + 系列 + 核心,例如B_Gen4_1、GP_Gen5_8。 字串 (必要)
{1}size{2} 要視需要由資源解譯的大小代碼。 字串
tier 特定 SKU 的層,例如基本層。 'Basic'
'GeneralPurpose'
'MemoryOptimized'

快速入門範本

下列快速入門範本會部署此資源類型。

[範本] 描述
使用 VNet 部署適用於 MariaDB 的 Azure 資料庫

部署至 Azure
此範本提供使用 VNet 整合部署適用于 MariaDB 的 Azure 資料庫的方法。

Terraform (AzAPI 提供者) 資源定義

伺服器資源類型可以部署到:

  • 資源群組

如需每個 API 版本中已變更屬性的清單,請參閱 變更記錄

資源格式

若要建立 Microsoft.DBforMariaDB/servers 資源,請將下列 Terraform 新增至您的範本。

resource "azapi_resource" "symbolicname" {
  type = "Microsoft.DBforMariaDB/servers@2018-06-01"
  name = "string"
  location = "string"
  parent_id = "string"
  tags = {
    tagName1 = "tagValue1"
    tagName2 = "tagValue2"
  }
  body = jsonencode({
    properties = {
      minimalTlsVersion = "string"
      publicNetworkAccess = "string"
      sslEnforcement = "string"
      storageProfile = {
        backupRetentionDays = int
        geoRedundantBackup = "string"
        storageAutogrow = "string"
        storageMB = int
      }
      version = "string"
      createMode = "string"
      // For remaining properties, see ServerPropertiesForCreateOrServerProperties objects
    }
    sku = {
      capacity = int
      family = "string"
      name = "string"
      size = "string"
      tier = "string"
    }
  })
}

ServerPropertiesForCreateOrServerProperties 物件

設定 createMode 屬性以指定物件的類型。

針對 [預設],請使用:

  createMode = "Default"
  administratorLogin = "string"
  administratorLoginPassword = "string"

針對 GeoRestore,請使用:

  createMode = "GeoRestore"
  sourceServerId = "string"

針對 PointInTimeRestore,請使用:

  createMode = "PointInTimeRestore"
  restorePointInTime = "string"
  sourceServerId = "string"

針對 複本,請使用:

  createMode = "Replica"
  sourceServerId = "string"

屬性值

servers

名稱 描述
type 資源類型 「Microsoft.DBforMariaDB/servers@2018-06-01」
NAME 資源名稱 字串 (必要)

字元限制:3-63

有效字元:
小寫字母、連字號和數字。

不能以連字號開頭或結尾。

資源名稱在 Azure 中必須是唯一的。
location 資源所在的位置。 字串 (必要)
parent_id 若要部署至資源群組,請使用該資源群組的識別碼。 字串 (必要)
tags 索引鍵/值組形式的應用程式特有中繼資料。 標記名稱和值的字典。
sku 伺服器的 SKU (定價層) 。 Sku
properties 伺服器的屬性。 ServerPropertiesForCreateOrServerProperties (必要)

ServerPropertiesForCreateOrServerProperties

名稱 描述
minimalTlsVersion 為伺服器強制執行最低 Tls 版本。 「TLS1_0」
「TLS1_1」
「TLS1_2」
「TLSEnforcementDisabled」
publicNetworkAccess 是否允許此伺服器的公用網路存取。 值是選擇性的,但如果傳入,則必須是 'Enabled' 或 'Disabled' 「Disabled」
「Enabled」
sslEnforcement 在連線到伺服器時啟用 SSL 強制。 「Disabled」
「Enabled」
storageProfile 伺服器的儲存體設定檔。 StorageProfile
version 伺服器版本。 "10.2"
"10.3"
createMode 設定物件類型 預設值
GeoRestore
PointInTimeRestore
需要複 本 ()

StorageProfile

名稱 描述
backupRetentionDays 伺服器的備份保留天數。 int
geoRedundantBackup 針對伺服器備份啟用異地備援或不啟用。 「Disabled」
「Enabled」
storageAutogrow 啟用儲存體自動成長。 「Disabled」
「Enabled」
storageMB 伺服器允許的最大儲存體。 int

ServerPropertiesForDefaultCreate

名稱 描述
createMode 建立新伺服器的模式。 「預設」 (必要)
administratorLogin 伺服器的系統管理員登入名稱。 只有在建立伺服器 (且建立) 時才能指定。 字串 (必要)
administratorLoginPassword 系統管理員登入的密碼。 字串 (必要)

ServerPropertiesForGeoRestore

名稱 描述
createMode 建立新伺服器的模式。 必要) 「GeoRestore」 (
sourceServerId 要從中還原的來源伺服器識別碼。 字串 (必要)

ServerPropertiesForRestore

名稱 描述
createMode 建立新伺服器的模式。 「PointInTimeRestore」 (必要)
restorePointInTime 還原點建立時間 (ISO8601 格式) ,並指定要從中還原的時間。 字串 (必要)
sourceServerId 要從中還原的來源伺服器識別碼。 字串 (必要)

ServerPropertiesForReplica

名稱 描述
createMode 建立新伺服器的模式。 必要) 的「複本」 (
sourceServerId 要從中建立複本的主伺服器識別碼。 字串 (必要)

SKU

名稱 描述
處理能力 相應增加/放大容量,代表伺服器的計算單位。 int
family 硬體系列。 字串
NAME sku 的名稱,通常是層 + 系列 + 核心,例如B_Gen4_1、GP_Gen5_8。 字串 (必要)
{1}size{2} 要視需要由資源解譯的大小代碼。 字串
tier 特定 SKU 的層,例如基本層。 "Basic"
「GeneralPurpose」
「MemoryOptimized」