-
Notifications
You must be signed in to change notification settings - Fork 35
/
prepay-db-instance.yml
63 lines (63 loc) · 1.78 KB
/
prepay-db-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
ROSTemplateFormatVersion: '2015-09-01'
Description:
zh-cn: 创建预付费RDS实例,支持MySQL、SQLServer、PostgreSQL、PPAS,配置实例类型、存储、版本及付费周期,输出订单ID与内部连接信息。
en: Create a prepaid RDS instance, compatible with MySQL, SQL Server, PostgreSQL,
and PPAS. Configure instance type, storage, version, and payment cycle. Output
the order ID and internal connection details.
Parameters:
EngineVersion:
Type: String
Description: 'MySQL: 5.5、5.6、5.7、5.8,SQLServer:2008r2,PostgreSQL:9.4'
DBInstanceClass:
Type: String
Description: Instance Class
DBInstanceStorage:
Type: Number
Description: MySQL:5-1000,SQLServer:10-1000,others:5-2000
Engine:
Type: String
Description: 'RDS Engine, Allowed values: MySQL、SQLServer、PostgreSQL、PPAS。'
PeriodType:
Type: String
Description: Period of Pay Type, allowed Month or Year
Period:
Type: Number
Description: If PeriodType is Month, Period between 1-9, else 1-3
Resources:
PrepayRDSInstance:
Type: ALIYUN::RDS::PrepayDBInstance
Properties:
EngineVersion:
Ref: EngineVersion
DBInstanceClass:
Ref: DBInstanceClass
DBInstanceStorage:
Ref: DBInstanceStorage
Engine:
Ref: Engine
PeriodType:
Ref: PeriodType
CommodityCode: rds
Period:
Ref: Period
Outputs:
OrderId:
Value:
Fn::GetAtt:
- PrepayRDSInstance
- OrderId
InnerPort:
Value:
Fn::GetAtt:
- PrepayRDSInstance
- InnerPort
InnerIPAddress:
Value:
Fn::GetAtt:
- PrepayRDSInstance
- InnerIPAddress
InnerConnectionString:
Value:
Fn::GetAtt:
- PrepayRDSInstance
- InnerConnectionString