-
Notifications
You must be signed in to change notification settings - Fork 35
/
ram-account-rights-management.yml
2262 lines (2260 loc) · 65.8 KB
/
ram-account-rights-management.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
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
ROSTemplateFormatVersion: '2015-09-01'
Description:
zh-cn: 单账号多环境RAM用户与资源治理方案,含VPC、ECS、OSS、RDS资源分组、权限配置及自动化部署策略。
en: Single-account Multi-environment RAM User and Resource Governance Solution,
encompassing VPC, ECS, OSS, RDS resource grouping, permission configurations,
and automated deployment strategies.
Parameters:
ResourceGroupId1Dev:
Type: String
Label:
en: Development Resource Group ID
zh-cn: 开发资源组ID
Description:
en: <font color='blue'><b>Development environment resource group ID where the
instance is located
zh-cn: <font color='blue'><b>实例所在的开发环境资源组ID。
MinLength: 3
ResourceGroupId2Prod:
Type: String
Label:
en: Production Resource Group ID
zh-cn: 生产资源组ID
Description:
en: <font color='blue'><b>The production environment resource group ID of the
instance
zh-cn: <font color='blue'><b>实例所在的生产环境资源组ID。
MinLength: 3
ResourceGroupId3Test:
Type: String
Label:
en: Test Resource Group ID
zh-cn: 测试资源组ID
Description:
en: <font color='blue'><b>The test environment resource group ID of the instance
zh-cn: <font color='blue'><b>实例所在的测试环境资源组ID。
MinLength: 3
VpcCidrBlock1Dev:
Type: String
Label:
en: Develop Environment VPC CIDR Block
zh-cn: 开发环境专有网络网段
Description:
en: Develop Environment VPC CIDR Block
zh-cn: 开发环境专有网络网段
Default: 172.16.0.0/12
AllowedValues:
- 10.0.0.0/8
- 172.16.0.0/12
- 192.168.0.0/16
VpcCidrBlock2Prod:
Type: String
Label:
en: Production Environment VPC CIDR Block
zh-cn: 生产环境专有网络网段
Description:
en: Production Environment VPC CIDR Block
zh-cn: 生产环境专有网络网段
Default: 10.0.0.0/8
AllowedValues:
- 10.0.0.0/8
- 172.16.0.0/12
- 192.168.0.0/16
VpcCidrBlock3Test:
Type: String
Label:
en: Test Environment VPC CIDR Block
zh-cn: 测试环境专有网络网段
Description:
en: Test Environment VPC CIDR Block
zh-cn: 测试环境专有网络网段
Default: 192.168.0.0/16
AllowedValues:
- 10.0.0.0/8
- 172.16.0.0/12
- 192.168.0.0/16
VSwitchZoneId:
Type: String
Label:
en: VSwitch Availability Zone
zh-cn: 交换机可用区
Description:
en: Availability Zone ID,<br><b>note: <font color='blue'>Before selecting, please
confirm that the Availability Zone supports the specification of creating
ECS resources</font></b>
zh-cn: 可用区ID。<br><b>注: <font color='blue'>选择可用区前请确认该可用区是否支持创建ECS资源的规格</font></b>
AssociationProperty: ALIYUN::ECS::Instance:ZoneId
VSwitchCidrBlockDev:
Type: String
Label:
en: Develop VSwitch CIDR Block
zh-cn: 开发交换机网段
Description:
en: Must be a sub-network segment of the proprietary network and is not occupied
by other VSwitches.
zh-cn: 必须是所属专有网络的子网段,并且没有被其他交换机占用。
Default: 172.16.10.0/24
VSwitchCidrBlockProd:
Type: String
Label:
en: Production VSwitch CIDR Block
zh-cn: 生产交换机网段
Description:
en: Must be a sub-network segment of the proprietary network and is not occupied
by other VSwitches.
zh-cn: 必须是所属专有网络的子网段,并且没有被其他交换机占用。
Default: 10.0.10.0/24
VSwitchCidrBlockTest:
Type: String
Label:
en: Test VSwitch CIDR Block
zh-cn: 测试交换机网段
Description:
en: Must be a sub-network segment of the proprietary network and is not occupied
by other VSwitches.
zh-cn: 必须是所属专有网络的子网段,并且没有被其他交换机占用。
Default: 192.168.10.0/24
EcsInstanceType:
Type: String
Label:
en: Instance Type
zh-cn: 实例规格
Description:
en: <font color='blue'><b>1.Before selecting the model please confirm that the
current available zone under the model is in stock, some models need to be
reported in advance</b></font><br><font color='blue'><b>2.List of optional
models</font><br></b></font>[ecs.c5.large <font color='green'>2vCPU 4GiB Intranet
bandwidth1Gbps In-grid sending and receiving packages30MillionPPS</font>]<br></b>[ecs.c5.xlarge
<font color='green'>4vCPU 8GiB Intranet bandwidth1.5Gbps In-grid sending and
receiving packages50MillionPPS</font>]<br></b>[ecs.c5.2xlarge <font color='green'>8vCPU
16GiB Intranet bandwidth2.5Gbps In-grid sending and receiving packages80MillionPPS</font>]
zh-cn: <font color='blue'><b>1.选择机型前请先确认当前可用区下该机型是否有货,部分机型需要提前报备</b></font><br><font
color='blue'><b>2.可选机型列表</font><br></b></font>[ecs.c5.large <font color='green'>2vCPU
4GiB 内网带宽1Gbps 内网收发包30万PPS</font>]<br></b>[ecs.c5.xlarge <font color='green'>4vCPU
8GiB 内网带宽1.5Gbps 内网收发包50万PPS</font>]<br></b>[ecs.c5.2xlarge <font color='green'>8vCPU
16GiB 内网带宽2.5Gbps 内网收发包80万PPS</font>]
AssociationProperty: ALIYUN::ECS::Instance::InstanceType
EcsImageId:
Type: String
Label:
en: Image
zh-cn: 镜像
Description:
en: Image ID,see detail:<b><a href='https://www.alibabacloud.com/help/en/doc-detail/112977.html'
target='_blank'><font color='blue'>Find the mirror</font></a></b>
zh-cn: 镜像ID, 详见:<b><a href='https://help.aliyun.com/document_detail/112977.html'
target='_blank'><font color='blue'>查找镜像</font></a></b>
Default: centos_7
EcsSystemDiskCategory:
Type: String
Label:
en: System Disk Type
zh-cn: 系统盘类型
Description:
en: '<font color=''blue''><b>Optional values:</b></font><br>[cloud_efficiency:
<font color=''green''>Efficient Cloud Disk</font>]<br>[cloud_ssd: <font color=''green''>SSD
Cloud Disk</font>]<br>[cloud_essd: <font color=''green''>ESSD Cloud Disk</font>]<br>[cloud:
<font color=''green''>Cloud Disk</font>]<br>[ephemeral_ssd: <font color=''green''>Local
SSD Cloud Disk</font>]'
zh-cn: '<font color=''blue''><b>可选值:</b></font><br>[cloud_efficiency: <font
color=''green''>高效云盘</font>]<br>[cloud_ssd: <font color=''green''>SSD云盘</font>]<br>[cloud_essd:
<font color=''green''>ESSD云盘</font>]<br>[cloud: <font color=''green''>普通云盘</font>]<br>[ephemeral_ssd:
<font color=''green''>本地SSD盘</font>]'
Default: cloud_efficiency
AllowedValues:
- cloud_efficiency
- cloud_ssd
- cloud
- cloud_essd
- ephemeral_ssd
EcsGroupSystemDiskSize:
Type: Number
Label:
en: System Disk Space
zh-cn: 系统盘空间
Description:
en: 'System disk size, range of values: 40-500, units: GB.'
zh-cn: 系统盘大小, 取值范围:[40, 500], 单位:GB。
Default: 40
EcsPassword:
Type: String
Label:
en: Instance Password
zh-cn: 实例密码
Description:
en: Server login password, Length 8-30, must contain three(Capital letters,
lowercase letters, numbers, ()`~!@#$%^&*_-+=|{}[]:;'<>,.?/ Special symbol
in).
zh-cn: 服务器登录密码,长度8-30,必须包含三项(大写字母、小写字母、数字、 ()`~!@#$%^&*_-+=|{}[]:;'<>,.?/ 中的特殊符号)。
ConstraintDescription:
en: Length 8-30, must contain three(Capital letters, lowercase letters, numbers,
()`~!@#$%^&*_-+=|{}[]:;'<>,.?/ Special symbol in).
zh-cn: 长度8-30,必须包含三项(大写字母、小写字母、数字、 ()`~!@#$%^&*_-+=|{}[]:;'<>,.?/ 中的特殊符号)。
AllowedPattern: '[0-9A-Za-z\_\-\&:;''<>,=%`~!@#\(\)\$\^\*\+\|\{\}\[\]\.\?\/]+$'
MinLength: 8
MaxLength: 30
NoEcho: true
DBInstanceEngineAndVersion:
Type: String
Label:
en: Type And Version
zh-cn: 类型与版本号
Description:
en: Database type and version number.
zh-cn: 数据库类型与版本号。
Default: MySQL-5.7
AllowedValues:
- MySQL-5.5
- MySQL-5.6
- MySQL-5.7
- MySQL-8.0
DBInstanceClass:
Type: String
Label:
en: Specifications
zh-cn: 实例规格
Description:
en: 'Select the instance specification based on the type of database engine
and the available area support;<br>See detail: <a href=''https://www.alibabacloud.com/help/doc-detail/26312.htm''
target=''_blank''><b><font color=''blue''>Instance specification sheet</font></b></a>'
zh-cn: 根据数据库引擎的类型和可用的区域支持选择实例规格;<br>请参见详细信息:<a href='https://help.aliyun.com/document_detail/26312.html'
target='_blank'><b><font color='blue'>实例规格列表</font></b></a>
Default: rds.mysql.s2.large
AllowedValues:
- rds.mysql.s2.large
- rds.mysql.s2.xlarge
- rds.mysql.s3.large
- rds.mysql.m1.medium
- rds.mysql.c1.large
- rds.mysql.c1.xlarge
DBInstanceStorage:
Type: Number
Label:
en: Storage Space
zh-cn: 存储空间
Description:
en: 'Database storage space, units: GB, per 5GB increment, value range: 5-1000.'
zh-cn: 数据库存储空间, 单位:GB, 每5GB进行递增,取值范围:5-1000。
Default: 5
MinValue: 5
MaxValue: 1000
BucketAccessControl:
Type: String
Label:
en: Access Control
zh-cn: 读写权限
Description:
en: '<font color=''blue''><b>Optional values: </b></font><br>[private:<font
color=''green''>All access to the file requires authentication</font>]<br>[public-read:<font
color=''green''>File writes need to be authenticated;Files can be read anonymously</font>]<br>[public-read-write:<font
color=''green''>Anyone (including anonymous visitors) can perform read and
write operators on the files in the bucket</font>]'
zh-cn: '<font color=''blue''><b>可选值: </b></font><br>[private:<font color=''green''>对文件的所有访问操作需要进行身份验证</font>]<br>[public-read:<font
color=''green''>对文件写操作需要进行身份验证;可以对文件进行匿名读</font>]<br>[public-read-write:<font
color=''green''>所有人都可以对文件进行读写操作</font>]'
Default: private
AllowedValues:
- private
- public-read
- public-read-write
BucketStorageClass:
Type: String
Label:
en: Storage Type
zh-cn: 存储类型
Description:
en: '<font color=''blue''><b>Optional values: </b></font><br>[Standard:<font
color=''green''>Standard storage type</font>]<br>[IA:<font color=''green''>Low
frequency access storage type</font>]<br>[Archive:<font color=''green''>Archive
storage type</font>]'
zh-cn: '<font color=''blue''><b>可选值: </b></font><br>[Standard:<font color=''green''>标准存储类型</font>]<br>[IA:<font
color=''green''>低频访问存储类型</font>]<br>[Archive:<font color=''green''>归档存储类型</font>]'
Default: Standard
AllowedValues:
- Standard
- IA
- Archive
BucketName1Dev:
Type: String
Label:
en: Develop Bucket Name
zh-cn: 开发存储空间名称
Description:
en: The name must be 3 to 63 bytes in length, The name must start and end with
a lowercase letter or digit.The name can contain only lowercase letters, digits,
and hyphens (-);<br><b>note:<font color='blue'>A bucket name must be globally
unique within OSS. Bucket names cannot be changed after the bucket is created.</b></font>
zh-cn: 长度为3~63个字符,必须以小写字母或数字开头和结尾,可以包含小写字母、数字和连字符(-);<br><font color='blue'><b>注:需要全网唯一性,已经存在的不能在创建</b></font>
Default: ros-projects-dev
BucketName2Prod:
Type: String
Label:
en: Production Bucket Name
zh-cn: 生产存储空间名称
Description:
en: The name must be 3 to 63 bytes in length, The name must start and end with
a lowercase letter or digit.The name can contain only lowercase letters, digits,
and hyphens (-);<br><b>note:<font color='blue'>A bucket name must be globally
unique within OSS. Bucket names cannot be changed after the bucket is created.</b></font>
zh-cn: 长度为3~63个字符,必须以小写字母或数字开头和结尾,可以包含小写字母、数字和连字符(-);<br><font color='blue'><b>注:需要全网唯一性,已经存在的不能在创建</b></font>
Default: ros-projects-prod
BucketName3Test:
Type: String
Label:
en: Test Bucket Name
zh-cn: 测试存储空间名称
Description:
en: The name must be 3 to 63 bytes in length, The name must start and end with
a lowercase letter or digit.The name can contain only lowercase letters, digits,
and hyphens (-);<br><b>note:<font color='blue'>A bucket name must be globally
unique within OSS. Bucket names cannot be changed after the bucket is created.</b></font>
zh-cn: 长度为3~63个字符,必须以小写字母或数字开头和结尾,可以包含小写字母、数字和连字符(-);<br><font color='blue'><b>注:需要全网唯一性,已经存在的不能在创建</b></font>
Default: ros-projects-test
BucketName4Code:
Type: String
Label:
en: Code Release Bucket Name
zh-cn: 代码发布空间名称
Description:
en: The name must be 3 to 63 bytes in length, The name must start and end with
a lowercase letter or digit.The name can contain only lowercase letters, digits,
and hyphens (-);<br><b>note:<font color='blue'>A bucket name must be globally
unique within OSS. Bucket names cannot be changed after the bucket is created.</b></font>
zh-cn: 长度为3~63个字符,必须以小写字母或数字开头和结尾,可以包含小写字母、数字和连字符(-);<br><font color='blue'><b>注:需要全网唯一性,已经存在的不能在创建</b></font>
Default: ros-projects-code
BucketName5Other:
Type: String
Label:
en: Other Bucket Name
zh-cn: 其他存储空间名称
Description:
en: The name must be 3 to 63 bytes in length, The name must start and end with
a lowercase letter or digit.The name can contain only lowercase letters, digits,
and hyphens (-);<br><b>note:<font color='blue'>A bucket name must be globally
unique within OSS. Bucket names cannot be changed after the bucket is created.</b></font>
zh-cn: 长度为3~63个字符,必须以小写字母或数字开头和结尾,可以包含小写字母、数字和连字符(-);<br><font color='blue'><b>注:需要全网唯一性,已经存在的不能在创建</b></font>
Default: ros-projects-other
BucketName4CodeFolderName:
Type: String
Label:
en: Publish Directory
zh-cn: 发布存储空间发布目录
Description:
en: The directory to be created in the publishing storage space divides the
read and write permissions of user groups to the publishing storage space
folder,;<br> does not allow names like ”/“or “..”Subdirectory, length 1-254
characters.
zh-cn: 即将在发布存储空间创建的目录,划分用户组对发布存储空间文件夹的读写权限;<br>不允许出现名为 “/”或“..”的子目录,长度1-254个字符。
Default: release
MinLength: 1
MaxLength: 254
BucketName5CodeFolderName:
Type: String
Label:
en: Production Directory
zh-cn: 发布存储空间生产目录
Description:
en: The directory to be created in the publishing storage space divides the
read and write permissions of user groups to the publishing storage space
folder,;<br> does not allow names like ”/“or “..”Subdirectory, length 1-254
characters.
zh-cn: 即将在发布存储空间创建的目录,划分用户组对发布存储空间文件夹的读写权限;<br>不允许出现名为 “/”或“..”的子目录,长度1-254个字符。
Default: prod
MinLength: 1
MaxLength: 254
GroupName4Sa:
Type: String
Label:
en: Operation User Group Name
zh-cn: 运维用户组名称
Description:
en: 'Operation group user group, 1 to 64 characters in length, including English
letters, Numbers, and hyphens (-);<br><b>note: <font color=''blue''>unique
in account</b></font>'
zh-cn: 运维组用户组, 长度为1~64个字符,可包含英文字母、数字,和连字符(-);<br><b>注:<font color='blue'>账号内唯一</b></font>
Default: sa
GroupName5Dev:
Type: String
Label:
en: Develop User Group Name
zh-cn: 开发用户组名称
Description:
en: 'Develop group user group, 1 to 64 characters in length, including English
letters, Numbers, and hyphens (-);<br><b>note: <font color=''blue''>unique
in account</b></font>'
zh-cn: 开发组用户组名称, 长度为1~64个字符,可包含英文字母、数字,和连字符(-);<br><b>注:<font color='blue'>账号内唯一</b></font>
Default: dev
GroupName6Test:
Type: String
Label:
en: Test User Group Name
zh-cn: 测试用户组名称
Description:
en: 'Test group user group, 1 to 64 characters in length, including English
letters, Numbers, and hyphens (-);<br><b>note: <font color=''blue''>unique
in account</b></font>'
zh-cn: 测试用户组名称, 长度为1~64个字符,可包含英文字母、数字,和连字符(-);<br><b>注:<font color='blue'>账号内唯一</b></font>
Default: test
GroupName1AppDev:
Type: String
Label:
en: Development Environment User Group Name
zh-cn: 开发环境程序用户组名称
Description:
en: 'Development environment user group name, 1 to 64 characters in length,
including English letters, Numbers, and hyphens (-);<br><b>note: <font color=''blue''>unique
in account</b></font>'
zh-cn: 开发环境程序组用户组, 长度为1~64个字符,可包含英文字母、数字,和连字符(-);<br><b>注:<font color='blue'>账号内唯一</b></font>
Default: app-dev
GroupName2AppProd:
Type: String
Label:
en: Production Environment User Group Name
zh-cn: 生产环境程序用户组名称
Description:
en: 'Production environment user group name, 1 to 64 characters in length, including
English letters, Numbers, and hyphens (-);<br><b>note: <font color=''blue''>unique
in account</b></font>'
zh-cn: 生产环境程序组用户组, 长度为1~64个字符,可包含英文字母、数字,和连字符(-);<br><font color='blue'><b>注:账号内唯一</b></font>
Default: app-prod
GroupName3AppTest:
Type: String
Label:
en: Test Environment User Group Name
zh-cn: 测试环境程序用户组名称
Description:
en: 'Test environment user group name, 1 to 64 characters in length, including
English letters, Numbers, and hyphens (-);<br><b>note: <font color=''blue''>unique
in account</b></font>'
zh-cn: 测试环境程序组用户组, 长度为1~64个字符,可包含英文字母、数字,和连字符(-);<br><b>注:<font color='blue'>账号内唯一</b></font>
Default: app-test
UserName1Dev:
Type: String
Label:
en: Development Permission User Name
zh-cn: 开发权限用户名
Description:
en: 'Development rights user name, 1 to 64 characters in length, including English
letters, Numbers, and hyphens (-);<br><b>note: <font color=''blue''>unique
in account</b></font>'
zh-cn: 开发账号用户名, 长度为1~64个字符,可包含英文字母、数字,和连字符(-);<br><b>注:<font color='blue'>账号内唯一</b></font>
ConstraintDescription:
en: '[1, 64] bits contain a maximum of 64 characters.format:^[a-zA-Z0-9\.@\-_]+$。'
zh-cn: '[1, 64]位最多包含64个字符。格式:^[a-zA-Z0-9\.@\-_]+$。'
Default: sts_dev
MinLength: 1
UserName2Prod:
Type: String
Label:
en: Production Permission User Name
zh-cn: 生产权限用户名
Description:
en: 'Production permission user name, 1 to 64 characters in length, including
English letters, Numbers, and hyphens (-);<br><b>note: <font color=''blue''>unique
in account</b></font>'
zh-cn: 生产账号用户名, 长度为1~64个字符,可包含英文字母、数字,和连字符(-);<br><b>注:<font color='blue'>账号内唯一</b></font>
ConstraintDescription:
en: '[1, 64] bits contain a maximum of 64 characters.format:^[a-zA-Z0-9\.@\-_]+$。'
zh-cn: '[1, 64]位最多包含64个字符。格式:^[a-zA-Z0-9\.@\-_]+$。'
Default: sts_prod
MinLength: 1
UserName3Test:
Type: String
Label:
en: Test Permission User Name
zh-cn: 测试权限用户名
Description:
en: 'Test permission user name, 1 to 64 characters in length, including English
letters, Numbers, and hyphens (-);<br><b>note: <font color=''blue''>unique
in account</b></font>'
zh-cn: 测试帐号用户名, 长度为1~64个字符,可包含英文字母、数字,和连字符(-);<br><b>注:<font color='blue'>账号内唯一</b></font>
ConstraintDescription:
en: '[1, 64] bits contain a maximum of 64 characters.format:^[a-zA-Z0-9\.@\-_]+$。'
zh-cn: '[1, 64]位最多包含64个字符。格式:^[a-zA-Z0-9\.@\-_]+$。'
Default: sts_test
MinLength: 1
Resources:
EcsVpc1Dev:
Type: ALIYUN::ECS::VPC
Properties:
CidrBlock:
Ref: VpcCidrBlock1Dev
ResourceGroupId:
Ref: ResourceGroupId1Dev
VpcName:
Fn::Join:
- '-'
- - Dev-StackId
- Ref: ALIYUN::StackId
Metadata:
ALIYUN::ROS::Designer:
id: ce657371-5d20-4779-9d6d-21a4c7b627d2
EcsSecurityGroup1Dev:
Type: ALIYUN::ECS::SecurityGroup
Properties:
VpcId:
Ref: EcsVpc1Dev
SecurityGroupIngress:
- IpProtocol: icmp
NicType: internet
PortRange: -1/-1
Priority: 1
SourceCidrIp: 0.0.0.0/0
- IpProtocol: tcp
NicType: internet
PortRange: 80/80
Priority: 1
SourceCidrIp: 0.0.0.0/0
- IpProtocol: tcp
NicType: internet
PortRange: 443/443
Priority: 1
SourceCidrIp: 0.0.0.0/0
- IpProtocol: tcp
NicType: internet
PortRange: 22/22
Priority: 1
SourceCidrIp: 0.0.0.0/0
SecurityGroupName:
Fn::Join:
- '-'
- - Dev-StackId
- Ref: ALIYUN::StackId
Tags:
- Key: best_practice
Value: '051'
Metadata:
ALIYUN::ROS::Designer:
id: e66ecbac-da4a-44f2-b74e-c47dd3d88f53
EcsVSwitch1Dev:
Type: ALIYUN::ECS::VSwitch
Properties:
ZoneId:
Ref: VSwitchZoneId
VpcId:
Ref: EcsVpc1Dev
CidrBlock:
Ref: VSwitchCidrBlockDev
VSwitchName:
Fn::Join:
- '-'
- - Dev-VSwitch-StackId
- Ref: ALIYUN::StackId
Metadata:
ALIYUN::ROS::Designer:
id: 794bd95b-525f-4fda-8fae-875ce12842d7
RamRole1Dev:
Type: ALIYUN::RAM::Role
Properties:
AssumeRolePolicyDocument:
Statement:
- Action: sts:AssumeRole
Effect: Allow
Principal:
Service:
- actiontrail.aliyuncs.com
Version: '1'
Description: projects-dev读写角色
RoleName:
Fn::Join:
- '-'
- - projects-dev-rw
- StackId
- Ref: ALIYUN::StackId
Metadata:
ALIYUN::ROS::Designer:
id: 7deb0cd2-4c08-4cde-9794-928907016062
RamUser1Dev:
Type: ALIYUN::RAM::User
Properties:
DisplayName: 开发STSToken
Policies:
- Description: '扮演role-projects-dev-rw角色权限 '
PolicyDocument:
Statement:
- Action:
- sts:AssumeRole
Effect: Allow
Resource:
- Fn::GetAtt:
- RamRole1Dev
- Arn
Version: '1'
PolicyName:
Fn::Join:
- '-'
- - assume_role-projects-dev-rw
- StackId
- Ref: ALIYUN::StackId
UserName:
Ref: UserName1Dev
Metadata:
ALIYUN::ROS::Designer:
id: aab44ffa-a7a5-4bd8-898c-852111f32ef5
RamAccessKey1Dev:
Type: ALIYUN::RAM::AccessKey
Properties:
UserName:
Ref: RamUser1Dev
DependsOn: RamUser1Dev
Metadata:
ALIYUN::ROS::Designer:
id: aca9826b-7f95-439f-a237-76ab291f0118
EcsInstance1Dev:
Type: ALIYUN::ECS::Instance
Properties:
VpcId:
Ref: EcsVpc1Dev
VSwitchId:
Ref: EcsVSwitch1Dev
SecurityGroupId:
Ref: EcsSecurityGroup1Dev
ImageId:
Ref: EcsImageId
AllocatePublicIP: true
InstanceChargeType: PostPaid
InstanceType:
Ref: EcsInstanceType
InternetMaxBandwidthOut: 1
IoOptimized: optimized
Password:
Ref: EcsPassword
ResourceGroupId:
Ref: ResourceGroupId1Dev
SystemDiskCategory:
Ref: EcsSystemDiskCategory
SystemDiskSize:
Ref: EcsGroupSystemDiskSize
Tags:
- Key: best_practice
Value: '051'
UserData:
Fn::Replace:
- ros-notify:
Fn::GetAtt:
- RosWaitConditionHandle
- CurlCli
- Fn::Join:
- ''
- - "#!/bin/sh \n"
- "export hostname=`hostname` \n"
- "sed -i '/127.0.0.1/d' /etc/hosts \n"
- "echo \"127.0.0.1 $hostname\" >> /etc/hosts \n"
- "echo '127.0.0.1 localhost' >> /etc/hosts \n"
- export access_key_id=
- Fn::GetAtt:
- RamAccessKey1Dev
- AccessKeyId
- " \n"
- export access_key_secret=
- Fn::GetAtt:
- RamAccessKey1Dev
- AccessKeySecret
- " \n"
- export bucket_name=
- Ref: BucketName4Code
- " \n"
- export endpoint=
- Fn::Join:
- ''
- - http://oss-
- Ref: ALIYUN::Region
- -internal.aliyuncs.com
- " \n"
- export bucket_dir1=
- Ref: BucketName4CodeFolderName
- '
'
- export bucket_dir2=
- Ref: BucketName5CodeFolderName
- '
'
- "wget http://gosspublic.alicdn.com/ossutil/1.6.10/ossutil64 \n"
- "chmod 755 ossutil64 \n"
- "./ossutil64 config -k $access_key_secret -i $access_key_id -e $endpoint\
\ \n"
- ./ossutil64 mkdir oss://
- Ref: BucketName4Code
- "/$bucket_dir1/ \n"
- "./ossutil64 config -k $access_key_secret -i $access_key_id -e $endpoint\
\ \n"
- ./ossutil64 mkdir oss://
- Ref: BucketName4Code
- "/$bucket_dir2/ \n"
- "ros-notify -d \"{\\\"Data\\\" : \\\"Success\\\", \\\"Status\\\" : \\\
\"Success\\\"}\" \n"
DependsOn:
- RamAccessKey1Dev
- RamUser1Dev
Metadata:
ALIYUN::ROS::Designer:
id: 862da07d-7b3c-4e05-9843-624a3c711269
EcsVpc2Prod:
Type: ALIYUN::ECS::VPC
Properties:
CidrBlock:
Ref: VpcCidrBlock2Prod
ResourceGroupId:
Ref: ResourceGroupId2Prod
VpcName:
Fn::Join:
- '-'
- - Prod-StackId
- Ref: ALIYUN::StackId
Metadata:
ALIYUN::ROS::Designer:
id: 097c50f2-9a75-4da8-b255-d4666e1a3df1
EcsSecurityGroup2Prod:
Type: ALIYUN::ECS::SecurityGroup
Properties:
VpcId:
Ref: EcsVpc2Prod
SecurityGroupIngress:
- IpProtocol: icmp
NicType: internet
PortRange: -1/-1
Priority: 1
SourceCidrIp: 0.0.0.0/0
- IpProtocol: tcp
NicType: internet
PortRange: 80/80
Priority: 1
SourceCidrIp: 0.0.0.0/0
- IpProtocol: tcp
NicType: internet
PortRange: 443/443
Priority: 1
SourceCidrIp: 0.0.0.0/0
- IpProtocol: tcp
NicType: internet
PortRange: 22/22
Priority: 1
SourceCidrIp: 0.0.0.0/0
SecurityGroupName:
Fn::Join:
- '-'
- - Prod-StackId
- Ref: ALIYUN::StackId
Tags:
- Key: best_practice
Value: '051'
Metadata:
ALIYUN::ROS::Designer:
id: 8c5dac94-b362-4011-948c-6ad3a3abcaac
EcsVSwitch2Prod:
Type: ALIYUN::ECS::VSwitch
Properties:
ZoneId:
Ref: VSwitchZoneId
VpcId:
Ref: EcsVpc2Prod
CidrBlock:
Ref: VSwitchCidrBlockProd
VSwitchName:
Fn::Join:
- '-'
- - Prod-VSwitch-StackId
- Ref: ALIYUN::StackId
Metadata:
ALIYUN::ROS::Designer:
id: 5df8cc6d-0d20-4b84-969d-6ca110774eb2
EcsInstance2Prod:
Type: ALIYUN::ECS::Instance
Properties:
VpcId:
Ref: EcsVpc2Prod
VSwitchId:
Ref: EcsVSwitch2Prod
SecurityGroupId:
Ref: EcsSecurityGroup2Prod
ImageId:
Ref: EcsImageId
AllocatePublicIP: false
InstanceChargeType: PostPaid
InstanceType:
Ref: EcsInstanceType
InternetMaxBandwidthOut: 0
IoOptimized: optimized
Password:
Ref: EcsPassword
ResourceGroupId:
Ref: ResourceGroupId2Prod
SystemDiskCategory:
Ref: EcsSystemDiskCategory
SystemDiskSize:
Ref: EcsGroupSystemDiskSize
Tags:
- Key: best_practice
Value: '051'
Metadata:
ALIYUN::ROS::Designer:
id: 783320d2-9319-4f8d-adc6-4ef8776d2f45
EcsVpc3Test:
Type: ALIYUN::ECS::VPC
Properties:
CidrBlock:
Ref: VpcCidrBlock3Test
ResourceGroupId:
Ref: ResourceGroupId3Test
VpcName:
Fn::Join:
- '-'
- - Test-StackId
- Ref: ALIYUN::StackId
Metadata:
ALIYUN::ROS::Designer:
id: 6b185598-0614-49f2-8ac6-76c4552592d0
EcsSecurityGroup3Test:
Type: ALIYUN::ECS::SecurityGroup
Properties:
VpcId:
Ref: EcsVpc3Test
SecurityGroupIngress:
- IpProtocol: icmp
NicType: internet
PortRange: -1/-1
Priority: 1
SourceCidrIp: 0.0.0.0/0
- IpProtocol: tcp
NicType: internet
PortRange: 80/80
Priority: 1
SourceCidrIp: 0.0.0.0/0
- IpProtocol: tcp
NicType: internet
PortRange: 443/443
Priority: 1
SourceCidrIp: 0.0.0.0/0
- IpProtocol: tcp
NicType: internet
PortRange: 22/22
Priority: 1
SourceCidrIp: 0.0.0.0/0
SecurityGroupName:
Fn::Join:
- '-'
- - Test-StackId
- Ref: ALIYUN::StackId
Tags:
- Key: best_practice
Value: '051'
Metadata:
ALIYUN::ROS::Designer:
id: a032374f-7bf5-4eab-8665-7e29f3ab9ff6
EcsVSwitch3Test:
Type: ALIYUN::ECS::VSwitch
Properties:
ZoneId:
Ref: VSwitchZoneId
VpcId:
Ref: EcsVpc3Test
CidrBlock:
Ref: VSwitchCidrBlockTest
VSwitchName:
Fn::Join:
- '-'
- - Test-VSwitch-StackId
- Ref: ALIYUN::StackId
Metadata:
ALIYUN::ROS::Designer:
id: 8b6fcb8c-8354-42b5-bf9a-162f248ebb37
EcsInstance3Test:
Type: ALIYUN::ECS::Instance
Properties:
VpcId:
Ref: EcsVpc3Test
VSwitchId:
Ref: EcsVSwitch3Test
SecurityGroupId:
Ref: EcsSecurityGroup3Test
ImageId:
Ref: EcsImageId
AllocatePublicIP: false
InstanceChargeType: PostPaid
InstanceType:
Ref: EcsInstanceType
InternetMaxBandwidthOut: 0
IoOptimized: optimized
Password:
Ref: EcsPassword
ResourceGroupId:
Ref: ResourceGroupId3Test
SystemDiskCategory:
Ref: EcsSystemDiskCategory
SystemDiskSize:
Ref: EcsGroupSystemDiskSize
Tags:
- Key: best_practice
Value: '051'
Metadata:
ALIYUN::ROS::Designer:
id: b0500ea3-d883-4eb4-97f0-3d72f7a946f0
OssBucket1Dev:
Type: ALIYUN::OSS::Bucket
Properties:
AccessControl:
Ref: BucketAccessControl
BucketName:
Ref: BucketName1Dev
DeletionForce: true
StorageClass:
Ref: BucketStorageClass
Tags:
Key: best_practice
Value: '051'
Metadata:
ALIYUN::ROS::Designer:
id: fcc2906e-1b34-4746-9c99-979112a0961a
OssBucket2Prod:
Type: ALIYUN::OSS::Bucket
Properties:
AccessControl:
Ref: BucketAccessControl
BucketName:
Ref: BucketName2Prod
DeletionForce: true
StorageClass:
Ref: BucketStorageClass
Tags:
Key: best_practice
Value: '051'
Metadata:
ALIYUN::ROS::Designer:
id: f8d2aa33-0494-4a8d-9d45-3af90273961d
OssBucket3Test:
Type: ALIYUN::OSS::Bucket
Properties:
AccessControl:
Ref: BucketAccessControl
BucketName:
Ref: BucketName3Test
DeletionForce: true
StorageClass:
Ref: BucketStorageClass
Tags:
Key: best_practice
Value: '051'
Metadata:
ALIYUN::ROS::Designer:
id: d4085be3-0c4d-42f0-b85f-437bdf0eeb6c
OssBucket4Code:
Type: ALIYUN::OSS::Bucket
Properties:
AccessControl:
Ref: BucketAccessControl
BucketName:
Ref: BucketName4Code
DeletionForce: true
StorageClass:
Ref: BucketStorageClass
Tags:
Key: best_practice
Value: '051'
Metadata:
ALIYUN::ROS::Designer:
id: 2d40b6f2-2d64-445a-b442-f1da03b1dc19
OssBucket5Other:
Type: ALIYUN::OSS::Bucket
Properties:
AccessControl:
Ref: BucketAccessControl
BucketName:
Ref: BucketName5Other
DeletionForce: true
StorageClass:
Ref: BucketStorageClass
Tags:
Key: best_practice
Value: '051'
DependsOn:
- EcsInstance3Test
Metadata:
ALIYUN::ROS::Designer:
id: d9fb59df-e552-4fa1-a5d8-bff3c30303fa
RamRole2Prod:
Type: ALIYUN::RAM::Role
Properties:
AssumeRolePolicyDocument:
Statement:
- Action: sts:AssumeRole
Effect: Allow
Principal:
Service:
- actiontrail.aliyuncs.com
Version: '1'
Description: projects-prod读写角色
RoleName:
Fn::Join:
- '-'
- - projects-prod-rw
- StackId
- Ref: ALIYUN::StackId
Metadata:
ALIYUN::ROS::Designer:
id: 3c816a38-a719-44d7-bd58-fd6712f2767e
RamUser2Prod:
Type: ALIYUN::RAM::User
Properties:
DisplayName: 生产STSToken