Skip to main content
版本:v1.3

Azure DATABASE-MARIADB

描述

用于部署 Azure mariadb 数据库的组件说明

示例

apiVersion: core.oam.dev/v1beta1
kind: Application
metadata:
name: mariadb-backend
spec:
components:
- name: mariadb-backend
type: azure-database-mariadb
properties:
resource_group: "kubevela-group"
location: "West Europe"
server_name: "kubevela"
db_name: "backend"
username: "acctestun"
password: "H@Sh1CoR3!Faked"
writeConnectionSecretToRef:
name: azure-db-conn
namespace: vela-system

参数说明

属性

名称描述类型是否必须默认值
db_nameDatabase instance namestringfalse
locationAzure locationstringfalse
passwordDatabase instance passwordstringfalse
resource_groupResource groupstringfalse
server_namemariadb server namestringfalse
usernameDatabase instance usernamestringfalse
writeConnectionSecretToRefThe secret which the cloud resource connection will be written towriteConnectionSecretToReffalse

writeConnectionSecretToRef

名称描述类型是否必须默认值
nameThe secret name which the cloud resource connection will be written tostringtrue
namespaceThe secret namespace which the cloud resource connection will be written tostringfalse

输出

如果设置了 writeConnectionSecretToRef,一个 Kubernetes Secret 将会被创建,并且,它的数据里有这些键(key):

名称描述
DB_HOSTDatabase instance host
DB_NAMEDatabase instance name
DB_PASSWORDDatabase instance password
DB_PORTDatabase instance port
DB_USERDatabase instance username
SERVER_NAMEmariadb server name