This repository has been archived by the owner on Jul 19, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 7
/
make_jira-dc_parent-EFS-ELBv1.tmplt.json
619 lines (619 loc) · 18.4 KB
/
make_jira-dc_parent-EFS-ELBv1.tmplt.json
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
{
"AWSTemplateFormatVersion": "2010-09-09",
"Description": "This template coordinates the running of the Jira Security-group, EFS, RDS, S3, IAM and EC2 templates.",
"Metadata": {
"AWS::CloudFormation::Interface": {
"ParameterGroups": [
{
"Label": {
"default": "Child Template URLs"
},
"Parameters": [
"SgTemplateUri",
"EfsTemplateUri",
"S3TemplateUri",
"RdsTemplateUri",
"IamTemplateUri",
"Ec2TemplateUri",
"ElbTemplateUri"
]
},
{
"Label": {
"default": "EC2 Parameters"
},
"Parameters": [
"InstanceType",
"AmiId",
"Ec2Subnet",
"Ec2Hostname",
"Ec2Domain",
"ProvisionUser",
"Ec2ProvKey",
"AdminPubkeyURL"
]
},
{
"Label": {
"default": "RDS Parameters"
},
"Parameters": [
"DbInstanceType",
"DbDataSize",
"PgsqlVersion",
"DbNodeName",
"DbInstanceName",
"DbAdminName",
"DbAdminPass"
]
},
{
"Label": {
"default": "Jira Parameters"
},
"Parameters": [
"JiraBinaryInstallerUrl",
"JiraAppPrepUrl",
"JiraPluginUrl",
"JiraProxyFqdn",
"JiraHomeSharePath",
"JiraHomeShareType",
"BackupVolumeDevice",
"BackupVolumeMountPath",
"BackupVolumeSize",
"BackupVolumeType"
]
},
{
"Label": {
"default": "ELB Parameters"
},
"Parameters": [
"ProxyPrettyName",
"JiraListenerCert",
"JiraListenPort",
"JiraServicePort",
"PubElbSubnets"
]
},
{
"Label": {
"default": "Miscellaneous Parameters"
},
"Parameters": [
"ServiceTld",
"TargetVPC",
"HaSubnets",
"RolePrefix",
"EpelRepo",
"PyStache",
"PipRpm",
"PipIndexFips"
]
}
],
"ParameterLabels": {
"Ec2TemplateUri": {
"default": "EC2 Instance"
},
"EfsTemplateUri": {
"default": "EFS Shares"
},
"IamTemplateUri": {
"default": "IAM Roles"
},
"RdsTemplateUri": {
"default": "RDS Database"
},
"S3TemplateUri": {
"default": "S3 Buckets"
},
"SgTemplateUri": {
"default": "Security Groups"
}
}
}
},
"Outputs": {},
"Parameters": {
"AdminPubkeyURL": {
"AllowedPattern": "^$|^http://.*$|^https://.*$",
"Description": "URL the file containing the admin users' SSH public keys.",
"Type": "String"
},
"AmiId": {
"AllowedPattern": "^ami-[0-9a-z]{8}$|^ami-[0-9a-z]{17}$",
"Description": "ID of the AMI to launch",
"Type": "String"
},
"BackupVolumeDevice": {
"AllowedValues": [
"true",
"false"
],
"Default": "false",
"Description": "Whether to mount an EBS volume as a backup-staging location. Leave as default (\"false\") to launch without a backup-staging volume",
"Type": "String"
},
"BackupVolumeMountPath": {
"AllowedPattern": "/.*",
"Default": "/var/backups",
"Description": "Filesystem path to mount the backup-stageing volume. Ignored if \"BackupVolumeDevice\" is blank",
"Type": "String"
},
"BackupVolumeSize": {
"ConstraintDescription": "Must be between 1GB and 16384GB.",
"Default": "10",
"Description": "Size in GB of the EBS volume to create. Ignored if \"BackupVolumeDevice\" is blank",
"MaxValue": "16384",
"MinValue": "10",
"Type": "Number"
},
"BackupVolumeType": {
"AllowedValues": [
"gp2",
"io1",
"sc1",
"st1",
"standard"
],
"Default": "gp2",
"Description": "Type of EBS volume to create. Ignored if \"BackupVolumeDevice\" is blank",
"Type": "String"
},
"DbAdminName": {
"AllowedPattern": "^[a-z][a-z0-9-]*[a-z0-9]",
"Description": "Name of the Jira master database-user.",
"Type": "String"
},
"DbAdminPass": {
"Description": "Password of the Jira master database-user.",
"NoEcho": "True",
"Type": "String"
},
"DbDataSize": {
"ConstraintDescription": "Must be between 5GB and 16384GB.",
"Default": "5",
"Description": "Size in GiB of the RDS table-space to create.",
"MaxValue": "16384",
"MinValue": "5",
"Type": "Number"
},
"DbInstanceName": {
"AllowedPattern": "^[a-z][a-z0-9-]*[a-z0-9]",
"Description": "Instance-name of the Jira database.",
"Type": "String"
},
"DbInstanceType": {
"AllowedValues": [
"db.t2.micro",
"db.t2.small",
"db.t2.medium",
"db.t2.large",
"db.t2.xlarge",
"db.t2.2xlarge",
"db.m4.large",
"db.m4.xlarge",
"db.m4.2xlarge",
"db.m4.4xlarge",
"db.m3.medium",
"db.m3.large",
"db.m3.xlarge",
"db.m3.2xlarge",
"db.r4.large",
"db.r4.xlarge",
"db.r4.2xlarge",
"db.r4.4xlarge",
"db.r4.8xlarge",
"db.r3.large",
"db.r3.xlarge",
"db.r3.2xlarge",
"db.r3.4xlarge",
"db.r3.8xlarge"
],
"Default": "db.t2.small",
"Description": "Amazon RDS instance type",
"Type": "String"
},
"DbNodeName": {
"Description": "NodeName of the Jira database.",
"Type": "String"
},
"Ec2Domain": {
"ConstraintDescription": "An alphanumeric string to complete the domain portion of the instance's FQDN.",
"Description": "Suffix for Jira's hostname and DNS record",
"Type": "String"
},
"Ec2Hostname": {
"ConstraintDescription": "An alphanumeric string to complete the hostname portion of the instance's FQDN.",
"Description": "Node-name for Jira's hostname and DNS record",
"Type": "String"
},
"Ec2ProvKey": {
"Description": "Public/private key pairs allowing the provisioning-user to securely connect to the instance after it launches.",
"Type": "AWS::EC2::KeyPair::KeyName"
},
"Ec2Subnet": {
"Description": "Subnet to associate to the Instance",
"Type": "AWS::EC2::Subnet::Id"
},
"Ec2TemplateUri": {
"AllowedPattern": "^$|^http://.*$|^https://.*$",
"Description": "URI for the template that creates the Jira-hosting EC2 instance.",
"Type": "String"
},
"EfsTemplateUri": {
"AllowedPattern": "^$|^http://.*$|^https://.*$",
"Description": "URI for the template that creates Jira's EFS shares.",
"Type": "String"
},
"ElbTemplateUri": {
"AllowedPattern": "^$|^http://.*$|^https://.*$",
"Description": "URI for the template that creates the user-facing web-proxy for the Jira service.",
"Type": "String"
},
"EpelRepo": {
"AllowedPattern": "^[a-z][a-z0-9-]*$",
"ConstraintDescription": "An alphanumeric string that represents the EPEL yum repo's label.",
"Default": "epel",
"Description": "Name of network's EPEL repo.",
"Type": "String"
},
"HaSubnets": {
"Description": "Select three subnets - each from different Availability Zones.",
"Type": "List<AWS::EC2::Subnet::Id>"
},
"IamTemplateUri": {
"AllowedPattern": "^$|^http://.*$|^https://.*$",
"Description": "URI for the template that creates Jira's IAM role(s).",
"Type": "String"
},
"InstanceType": {
"AllowedValues": [
"t2.micro",
"t2.small",
"t2.medium",
"t2.large",
"t2.xlarge",
"t2.2xlarge",
"m5.large",
"m5.xlarge",
"m5.2xlarge",
"m5.4xlarge",
"m4.large",
"m4.xlarge",
"m4.2xlarge",
"m4.4xlarge",
"m3.medium",
"m3.large",
"m3.xlarge",
"m3.2xlarge",
"m3.4xlarge",
"c5.large",
"c5.xlarge",
"c5.2xlarge",
"c5.4xlarge",
"c4.large",
"c4.xlarge",
"c4.2xlarge",
"c4.4xlarge",
"c3.large",
"c3.xlarge",
"c3.2xlarge",
"c3.4xlarge"
],
"Default": "t2.large",
"Description": "Amazon EC2 instance type",
"Type": "String"
},
"JiraAppPrepUrl": {
"AllowedPattern": "^$|^http://.*$|^https://.*$",
"Default": "",
"Description": "URL to the Jira Datacenter EC2 application installer/configuration script.",
"Type": "String"
},
"JiraBinaryInstallerUrl": {
"AllowedPattern": "^$|^http://.*$|^https://.*$",
"Default": "",
"Description": "URL to the Jira Datacenter binary-installer file.",
"Type": "String"
},
"JiraHomeSharePath": {
"Default": "",
"Description": "Share-path of shared Jira-home.",
"Type": "String"
},
"JiraHomeShareType": {
"AllowedValues": [
"glusterfs",
"nfs"
],
"Description": "Type of network share hosting persisted Jira-home content.",
"Type": "String"
},
"JiraListenPort": {
"Default": "443",
"Description": "TCP Port number on which the Jira ELB listens for requests.",
"MaxValue": "65535",
"MinValue": "1",
"Type": "Number"
},
"JiraListenerCert": {
"Default": "",
"Description": "Name/ID of the ACM-managed SSL Certificate to protect public listener.",
"Type": "String"
},
"JiraOsPrepUrl": {
"AllowedPattern": "^$|^http://.*$|^https://.*$",
"Default": "",
"Description": "URL to the Jira Datacenter EC2 OS-preparationscript.",
"Type": "String"
},
"JiraPluginUrl": {
"AllowedPattern": "^$|^http://.*$|^https://.*$",
"Default": "",
"Description": "URL to the Jira Datacenter Plugin installation script.",
"Type": "String"
},
"JiraProxyFqdn": {
"Description": "FQDN of the front-end proxy host/service for Jira.",
"Type": "String"
},
"JiraServicePort": {
"Default": "80",
"Description": "TCP Port number that the Jira host listens to.",
"MaxValue": "65535",
"Type": "Number"
},
"PgsqlVersion": {
"AllowedValues": [
"9.6.6",
"9.6.5",
"9.6.3",
"9.6.2",
"9.6.1",
"9.5.10",
"9.5.9",
"9.5.7",
"9.5.6",
"9.5.4",
"9.5.2"
],
"Default": "9.5.10",
"Description": "The X.Y.Z version of the PostGreSQL database to deploy.",
"Type": "String"
},
"PipIndexFips": {
"AllowedPattern": "^$|^http://.*$|^https://.*$",
"Default": "https://pypi.org/simple/",
"Description": "URL of pip index that is compatible with FIPS 140-2 requirements.",
"Type": "String"
},
"PipRpm": {
"Default": "python2-pip",
"Description": "Name of preferred pip RPM.",
"Type": "String"
},
"ProvisionUser": {
"AllowedPattern": "[a-z0-9]{6,12}+",
"ConstraintDescription": "Alphanumeric string between 6 and 12 characters.",
"Default": "jirabuild",
"Description": "Default login user account name.",
"Type": "String"
},
"ProxyPrettyName": {
"Description": "A short, human-friendly label to assign to the ELB (no capital letters).",
"Type": "String"
},
"PubElbSubnets": {
"Description": "Select three subnets - each from different, user-facing Availability Zones.",
"Type": "List<AWS::EC2::Subnet::Id>"
},
"PyStache": {
"Default": "pystache",
"Description": "Name of preferred pystache RPM.",
"Type": "String"
},
"RdsTemplateUri": {
"AllowedPattern": "^$|^http://.*$|^https://.*$",
"Description": "URI for the template that creates Jira's RDS database.",
"Type": "String"
},
"S3TemplateUri": {
"AllowedPattern": "^$|^http://.*$|^https://.*$",
"Description": "URI for the template that creates Jira's S3 buckets.",
"Type": "String"
},
"RolePrefix": {
"Description": "Prefix to apply to IAM role to make things a bit prettier (optional).",
"Type": "String"
},
"ServiceTld": {
"Default": "amazonaws.com",
"Description": "TLD of the created EFS-endpoint.",
"Type": "String"
},
"SgTemplateUri": {
"AllowedPattern": "^$|^http://.*$|^https://.*$",
"Description": "URI for the template that creates Jira's SGs.",
"Type": "String"
},
"TargetVPC": {
"AllowedPattern": "^vpc-[0-9a-f]*$",
"Description": "ID of the VPC to deploy cluster nodes into.",
"Type": "AWS::EC2::VPC::Id"
}
},
"Resources": {
"Ec2Res": {
"Properties": {
"Parameters": {
"AdminPubkeyURL": { "Ref": "AdminPubkeyURL" },
"AmiId": { "Ref": "AmiId" },
"BackupVolumeDevice": { "Ref": "BackupVolumeDevice" },
"BackupVolumeMountPath": { "Ref": "BackupVolumeMountPath" },
"BackupVolumeSize": { "Ref": "BackupVolumeSize" },
"BackupVolumeType": { "Ref": "BackupVolumeType" },
"CfnEndpointUrl": {
"Fn::Join": [
".",
[
"https://cloudformation",
{ "Ref": "AWS::Region" },
{ "Ref": "ServiceTld" }
]
]
},
"Domainname": { "Ref": "Ec2Domain" },
"EpelRepo": { "Ref": "EpelRepo" },
"Hostname": { "Ref": "Ec2Hostname" },
"InstanceRole": {
"Fn::GetAtt": [ "IamRes", "Outputs.InstanceRoleProfile" ]
},
"InstanceType": { "Ref": "InstanceType" },
"JiraAppPrepUrl": { "Ref": "JiraAppPrepUrl" },
"JiraBinaryInstallerUrl": { "Ref": "JiraBinaryInstallerUrl" },
"JiraHomeSharePath": {
"Fn::Join": [
":",
[
{ "Fn::GetAtt": [ "EfsRes", "Outputs.EfsEndpoint" ] },
{ "Ref": "JiraHomeSharePath" }
]
]
},
"JiraHomeShareType": { "Ref": "JiraHomeShareType" },
"JiraOsPrepUrl": { "Ref": "JiraOsPrepUrl" },
"JiraPluginUrl": { "Ref": "JiraPluginUrl" },
"JiraPgsqlHost": {
"Fn::GetAtt": [ "RdsRes", "Outputs.RdsEndpointAddress" ]
},
"JiraPgsqlInst": { "Ref": "DbInstanceName" },
"JiraPgsqlManager": { "Ref": "DbAdminName" },
"JiraPgsqlPassword": { "Ref": "DbAdminPass" },
"JiraProxyFqdn": { "Ref": "JiraProxyFqdn" },
"KeyPairName": { "Ref": "Ec2ProvKey" },
"NoPublicIp": "true",
"NoReboot": "false",
"PipIndexFips": { "Ref": "PipIndexFips" },
"PipRpm": { "Ref": "PipRpm" },
"ProvisionUser": { "Ref": "ProvisionUser" },
"PyStache": { "Ref": "PyStache" },
"SecurityGroupIds": {
"Fn::Join": [
",",
[
{ "Fn::GetAtt": [ "SgRes", "Outputs.AppSg" ] },
{ "Fn::GetAtt": [ "SgRes", "Outputs.NasSg" ] },
{ "Fn::GetAtt": [ "SgRes", "Outputs.RdsSg" ] }
]
]
},
"SubnetId": { "Ref": "Ec2Subnet" }
},
"TemplateURL": { "Ref": "Ec2TemplateUri" }
},
"Type": "AWS::CloudFormation::Stack"
},
"EfsRes": {
"Properties": {
"Parameters": {
"EfsSg": { "Fn::GetAtt": [ "SgRes", "Outputs.NasSg" ] },
"EfsSubnet": {
"Fn::Join": [
",",
{ "Ref": "HaSubnets" }
]
},
"ServiceTld": { "Ref": "ServiceTld" }
},
"TemplateURL": { "Ref": "EfsTemplateUri" }
},
"Type": "AWS::CloudFormation::Stack"
},
"ElbRes": {
"Properties": {
"Parameters": {
"JiraListenerCert": { "Ref": "JiraListenerCert" },
"JiraListenPort": { "Ref": "JiraListenPort" },
"JiraServicePort": { "Ref": "JiraServicePort" },
"HaSubnets": {
"Fn::Join": [
",",
{ "Ref": "PubElbSubnets" }
]
},
"JiraInstanceId": {
"Fn::GetAtt": [ "Ec2Res", "Outputs.JiraInstanceId" ]
},
"ProxyPrettyName": { "Ref": "ProxyPrettyName" },
"SecurityGroupIds": {
"Fn::Join": [
",",
[
{ "Fn::GetAtt": [ "SgRes", "Outputs.AppSg" ] }
]
]
},
"TargetVPC": { "Ref": "TargetVPC" }
},
"TemplateURL": { "Ref": "ElbTemplateUri" }
},
"Type": "AWS::CloudFormation::Stack"
},
"IamRes": {
"Properties": {
"Parameters": {
"BackupBucketArn": { "Fn::GetAtt": [ "S3Res", "Outputs.BucketArn" ] },
"RolePrefix": { "Ref": "RolePrefix" },
"ServiceTld": { "Ref": "ServiceTld" }
},
"TemplateURL": { "Ref": "IamTemplateUri" },
"TimeoutInMinutes": 10
},
"Type": "AWS::CloudFormation::Stack"
},
"RdsRes": {
"Properties": {
"Parameters": {
"DbAdminName": { "Ref": "DbAdminName" },
"DbAdminPass": { "Ref": "DbAdminPass" },
"DbDataSize": { "Ref": "DbDataSize" },
"DbInstanceName": { "Ref": "DbInstanceName" },
"DbInstanceType": { "Ref": "DbInstanceType" },
"DbIsMultiAz": "true",
"DbNodeName": { "Ref": "DbNodeName" },
"DbSecurityGroup": { "Fn::GetAtt": [ "SgRes", "Outputs.RdsSg" ] },
"DbSubnets": {
"Fn::Join": [
",",
{ "Ref": "HaSubnets" }
]
},
"PgsqlVersion": { "Ref": "PgsqlVersion" },
"TargetVPC": { "Ref": "TargetVPC" }
},
"TemplateURL": { "Ref": "RdsTemplateUri" }
},
"Type": "AWS::CloudFormation::Stack"
},
"S3Res": {
"Properties": {
"Parameters": {},
"TemplateURL": { "Ref": "S3TemplateUri" },
"TimeoutInMinutes": 10
},
"Type": "AWS::CloudFormation::Stack"
},
"SgRes": {
"Properties": {
"Parameters": {
"TargetVPC": { "Ref": "TargetVPC" }
},
"TemplateURL": { "Ref": "SgTemplateUri" },
"TimeoutInMinutes": 10
},
"Type": "AWS::CloudFormation::Stack"
}
}
}