Todos os produtos
Search
Central de documentação

Resource Orchestration Service:ALIYUN::SLS::RdsExternalStore

Última atualização: Jun 27, 2026

Cria um repositório externo do ApsaraDB RDS for MySQL para o Simple Log Service (SLS).

Sintaxe

{
  "Type": "ALIYUN::SLS::RdsExternalStore",
  "Properties": {
    "Db": String,
    "ExternalStoreName": String,
    "Host": String,
    "Project": String,
    "Port": Integer,
    "Password": String,
    "Region": String,
    "StoreType": String,
    "Table": String,
    "Username": String,
    "VpcId": String,
    "InstanceId": String
  }
}

Propriedades

Propriedade

Tipo

Obrigatório

Editável

Descrição

Restrição

Db

String

Sim

Sim

Nome do banco de dados na instância do ApsaraDB RDS for MySQL.

Nenhuma.

ExternalStoreName

String

Sim

Não

Nome do repositório externo.

Nenhuma.

Host

String

Sim

Sim

Endpoint privado ou público da instância do ApsaraDB RDS for MySQL.

Nenhuma.

Project

String

Sim

Não

Nome do projeto do Simple Log Service.

Nenhuma.

Port

Integer

Sim

Sim

Porta privada ou pública da instância do ApsaraDB RDS for MySQL.

Nenhuma.

Password

String

Sim

Sim

Senha da instância do ApsaraDB RDS for MySQL.

Nenhuma.

Region

String

Sim

Sim

Região onde a instância do ApsaraDB RDS for MySQL está localizada.

Valores válidos:

  • cn-qingdao

  • cn-beijing

  • cn-hangzhou

StoreType

String

Sim

Não

Tipo de armazenamento.

Defina como rds-vpc para especificar um banco de dados do ApsaraDB RDS for MySQL em uma VPC.

Table

String

Sim

Sim

Nome da tabela do banco de dados na instância do ApsaraDB RDS for MySQL.

Nenhuma.

Username

String

Sim

Sim

Nome de usuário da instância do ApsaraDB RDS for MySQL.

Nenhuma.

VpcId

String

Sim

Sim

ID da VPC à qual a instância do ApsaraDB RDS for MySQL pertence.

Nenhuma.

InstanceId

String

Não

Sim

ID da instância do ApsaraDB RDS for MySQL.

Nenhuma.

Valores de retorno

Fn::GetAtt

  • Project: nome do projeto do Simple Log Service.

  • ExternalStoreName: nome do repositório externo.

Exemplos

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  StoreType:
    Type: String
    Description:
      en: The storage type. Set the value to rds-vpc, which indicates an ApsaraDB RDS for MySQL database in a virtual private cloud (VPC).
    AllowedValues:
      - rds-vpc
    Required: true
  Project:
    Type: String
    Description:
      en: The name of the project.
    Required: true
  Table:
    Type: String
    Description:
      en: The name of the database table in the ApsaraDB RDS for MySQL instance.
    Required: true
  VpcId:
    AssociationProperty: ALIYUN::ECS::VPC::VPCId
    Type: String
    Description:
      en: The ID of the VPC to which the ApsaraDB RDS for MySQL instance belongs.
    Required: true
  Username:
    Type: String
    Description:
      en: The username that is used to log on to the ApsaraDB RDS for MySQL instance.
    Required: true
  Port:
    Type: Number
    Description:
      en: The internal or public port of the ApsaraDB RDS for MySQL instance.
    Required: true
  Region:
    Type: String
    Description:
      en: 'The region where the ApsaraDB RDS for MySQL instance resides. Valid values: cn-qingdao, cn-beijing, and cn-hangzhou.'
    AllowedValues:
      - cn-qingdao
      - cn-beijing
      - cn-hangzhou
    Required: true
  Host:
    Type: String
    Description:
      en: The internal or public endpoint of the ApsaraDB RDS for MySQL instance.
    Required: true
  ExternalStoreName:
    Type: String
    Description:
      en: The name of the external store. The name must be unique in a project and different from Logstore.
    Required: true
  Db:
    Type: String
    Description:
      en: The name of the database in the ApsaraDB RDS for MySQL instance.
    Required: true
  Password:
    Type: String
    Description:
      en: The password that is used to log on to the ApsaraDB RDS for MySQL instance.
    Required: true
Resources:
  RdsExternalStore:
    Type: ALIYUN::SLS::RdsExternalStore
    Properties:
      StoreType:
        Ref: StoreType
      Project:
        Ref: Project
      Table:
        Ref: Table
      VpcId:
        Ref: VpcId
      Username:
        Ref: Username
      Port:
        Ref: Port
      Region:
        Ref: Region
      Host:
        Ref: Host
      ExternalStoreName:
        Ref: ExternalStoreName
      Db:
        Ref: Db
      Password:
        Ref: Password
Outputs:
  Project:
    Description: The name of the project to which the external store belongs.
    Value:
      Fn::GetAtt:
        - RdsExternalStore
        - Project
  ExternalStoreName:
    Description: The name of the external store.
    Value:
      Fn::GetAtt:
        - RdsExternalStore
        - ExternalStoreName
{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "StoreType": {
      "Type": "String",
      "Description": {
        "en": "The storage type. Set the value to rds-vpc, which indicates an ApsaraDB RDS for MySQL database in a virtual private cloud (VPC)."
      },
      "AllowedValues": [
        "rds-vpc"
      ],
      "Required": true
    },
    "Project": {
      "Type": "String",
      "Description": {
        "en": "The name of the project."
      },
      "Required": true
    },
    "Table": {
      "Type": "String",
      "Description": {
        "en": "The name of the database table in the ApsaraDB RDS for MySQL instance."
      },
      "Required": true
    },
    "VpcId": {
      "AssociationProperty": "ALIYUN::ECS::VPC::VPCId",
      "Type": "String",
      "Description": {
        "en": "The ID of the VPC to which the ApsaraDB RDS for MySQL instance belongs."
      },
      "Required": true
    },
    "Username": {
      "Type": "String",
      "Description": {
        "en": "The username that is used to log on to the ApsaraDB RDS for MySQL instance."
      },
      "Required": true
    },
    "Port": {
      "Type": "Number",
      "Description": {
        "en": "The internal or public port of the ApsaraDB RDS for MySQL instance."
      },
      "Required": true
    },
    "Region": {
      "Type": "String",
      "Description": {
        "en": "The region where the ApsaraDB RDS for MySQL instance resides. Valid values: cn-qingdao, cn-beijing, and cn-hangzhou."
      },
      "AllowedValues": [
        "cn-qingdao",
        "cn-beijing",
        "cn-hangzhou"
      ],
      "Required": true
    },
    "Host": {
      "Type": "String",
      "Description": {
        "en": "The internal or public endpoint of the ApsaraDB RDS for MySQL instance."
      },
      "Required": true
    },
    "ExternalStoreName": {
      "Type": "String",
      "Description": {
        "en": "The name of the external store. The name must be unique in a project and different from Logstore."
      },
      "Required": true
    },
    "Db": {
      "Type": "String",
      "Description": {
        "en": "The name of the database in the ApsaraDB RDS for MySQL instance."
      },
      "Required": true
    },
    "Password": {
      "Type": "String",
      "Description": {
        "en": "The password that is used to log on to the ApsaraDB RDS for MySQL instance."
      },
      "Required": true
    }
  },
  "Resources": {
    "RdsExternalStore": {
      "Type": "ALIYUN::SLS::RdsExternalStore",
      "Properties": {
        "StoreType": {
          "Ref": "StoreType"
        },
        "Project": {
          "Ref": "Project"
        },
        "Table": {
          "Ref": "Table"
        },
        "VpcId": {
          "Ref": "VpcId"
        },
        "Username": {
          "Ref": "Username"
        },
        "Port": {
          "Ref": "Port"
        },
        "Region": {
          "Ref": "Region"
        },
        "Host": {
          "Ref": "Host"
        },
        "ExternalStoreName": {
          "Ref": "ExternalStoreName"
        },
        "Db": {
          "Ref": "Db"
        },
        "Password": {
          "Ref": "Password"
        }
      }
    }
  },
  "Outputs": {
    "Project": {
      "Description": "The name of the project to which the external store belongs.",
      "Value": {
        "Fn::GetAtt": [
          "RdsExternalStore",
          "Project"
        ]
      }
    },
    "ExternalStoreName": {
      "Description": "The name of the external store.",
      "Value": {
        "Fn::GetAtt": [
          "RdsExternalStore",
          "ExternalStoreName"
        ]
      }
    }
  }
}