forked from aliyun/ros-templates
-
Notifications
You must be signed in to change notification settings - Fork 1
/
rds-quickly-use-rds-mysql-serverless-instance.yml
99 lines (99 loc) · 3.04 KB
/
rds-quickly-use-rds-mysql-serverless-instance.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
ROSTemplateFormatVersion: '2015-09-01'
Description:
en: Quickly use RDS MySQL Serverless instance.
zh-cn: 快速使用RDS MySQL Serverless实例。
Parameters:
DBInstanceId:
Type: String
Label:
en: RDS MySQL Serverless InstanceId
zh-cn: RDS MySQL Serverless实例Id
Description:
en: The id of RDS MySQL Serverless instance, make sure the instance has entered
the running state
zh-cn: RDS MySQL Serverless实例Id,请确保实例已经进入运行中的状态。
AssociationProperty: ALIYUN::RDS::Instance::InstanceId
AccountName:
Type: String
Label:
en: Database Account
zh-cn: 数据库账号
Description:
en: The account name must be 2 to 32 characters in length and can contain lowercase
letters, digits, and underscores (_). It must start with a letter and end
with a letter or digit.
zh-cn: 由小写字母、数字、下划线(_)组成,以字母开头,以字母或数字结尾,最多32个字符。
Default: testuser
Password:
Type: String
Label:
en: Database account password
zh-cn: 数据库账号密码
Description:
en: 'The password must be 8 to 32 characters in length and must contain at least
three of the following types: uppercase letters, lowercase letter, digits,
and special characters. Special characters include <span style="background:#E7E9EB;"><b>!@#$%^&*()_+-=</b></span>'
zh-cn: 必须包含三种及以上类型:大写字母、小写字母、数字、特殊符号。长度为8~32位。特殊字符包括<span style="background:#E7E9EB;"><b>!@#$%^&*()_+-=</b></span>
AssociationProperty: ALIYUN::ECS::Instance::Password
NoEcho: true
Resources:
Account:
Type: ALIYUN::RDS::Account
Properties:
AccountName:
Ref: AccountName
AccountType: Super
AccountDescription: tutorial account
AccountPassword:
Ref: Password
DBInstanceId:
Ref: DBInstanceId
SecurityIps:
Type: ALIYUN::RDS::DBInstanceSecurityIps
Properties:
DBInstanceId:
Ref: DBInstanceId
DBInstanceIPArrayAttribute: 0.0.0.0/0
DBInstanceIPArrayName: mywhitelist
Connection:
Type: ALIYUN::RDS::Connection
Properties:
DBInstanceId:
Ref: DBInstanceId
Port: 3306
ConnectionStringPrefix:
Fn::Sub: ${DBInstanceId}o
Outputs:
PublicEndpoint:
Description:
en: Public Endpoint.
zh-cn: 外网地址。
Value:
Fn::GetAtt:
- Connection
- ConnectionString
PublicPort:
Description:
en: Public port.
zh-cn: 外网端口。
Value:
Fn::GetAtt:
- Connection
- Port
AccountName:
Description:
en: Database username.
zh-cn: 数据库用户名。
Value:
Fn::GetAtt:
- Account
- AccountName
Metadata:
ALIYUN::ROS::Interface:
ParameterGroups:
- Parameters:
- DBInstanceId
- AccountName
- Password
TemplateTags:
- acs:document:试用教程:快速使用RDS MySQL Serverless实例