prima-twig 0.39.30 → 0.39.31
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/bin/twig-feature +38 -37
- data/lib/prima_aws_client.rb +43 -25
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 4d0be84cebd8e31644095686e6cfb353e74e0abe3304a6f614e4874aa475a835
|
|
4
|
+
data.tar.gz: fa04a5b80f53481137eb41272d5aa464cacc3fe3cb0ee7783a485edd208e05cb
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: e0c41ff96e9a1656b9137dca815712181c9ec56e4b3dea695797f77f256473317a706b46adbd65c6a3f17d0db7908abcfae07068adbca77bc5cd8074d5a8f441
|
|
7
|
+
data.tar.gz: 8af33680b07202b83bb1fbfd9fc393a36094b193dd07c3234a37cdc0efb1e3be619d703765416243279d842b9be2ee29d81af638a99bfe65db225d0ea58ce486
|
data/bin/twig-feature
CHANGED
|
@@ -27,6 +27,7 @@ class Release
|
|
|
27
27
|
@s3_bucket = 'prima-artifacts'
|
|
28
28
|
@artifact_path = '/tmp/prima-artifact.zip'
|
|
29
29
|
@import_db_task = 'arn:aws:ecs:eu-west-1:001575623345:task-definition/ecs-task-db-restore2-TaskDefinitionDbRestore-QL7O8B9LPNAU:1'
|
|
30
|
+
@cf_role = 'arn:aws:iam::001575623345:role/qainit-service-role-cloudformat-CloudformationRole-18KBZQIS148R9'
|
|
30
31
|
@dns_record_identifier = nil
|
|
31
32
|
@ecs_cluster_name = nil
|
|
32
33
|
@deploy_update = false
|
|
@@ -742,7 +743,7 @@ class Release
|
|
|
742
743
|
}
|
|
743
744
|
]
|
|
744
745
|
|
|
745
|
-
create_stack(stack_name_route53, stack_body, parameters, tags) unless stack_exists?(stack_name_route53)
|
|
746
|
+
create_stack(stack_name_route53, stack_body, parameters, tags, @cf_role) unless stack_exists?(stack_name_route53)
|
|
746
747
|
wait_for_stack_ready(stack_name_route53) unless stack_ready?(stack_name_route53)
|
|
747
748
|
|
|
748
749
|
case project
|
|
@@ -794,9 +795,9 @@ class Release
|
|
|
794
795
|
]
|
|
795
796
|
if stack_exists?(stack_name_web)
|
|
796
797
|
cur_version = get_currently_deployed_version(stack_name_web)
|
|
797
|
-
update_stack(stack_name_web, stack_body, parameters, tags) unless cur_version.include?(@projects["prima"][:revision])
|
|
798
|
+
update_stack(stack_name_web, stack_body, parameters, tags, @cf_role) unless cur_version.include?(@projects["prima"][:revision])
|
|
798
799
|
else
|
|
799
|
-
create_stack(stack_name_web, stack_body, parameters, tags)
|
|
800
|
+
create_stack(stack_name_web, stack_body, parameters, tags, @cf_role)
|
|
800
801
|
end
|
|
801
802
|
wait_for_stack_ready(stack_name_web) unless stack_ready?(stack_name_web)
|
|
802
803
|
update_service_defaults(stack_name_web)
|
|
@@ -847,9 +848,9 @@ class Release
|
|
|
847
848
|
]
|
|
848
849
|
if stack_exists?(stack_name_crash)
|
|
849
850
|
cur_version = get_currently_deployed_version(stack_name_crash)
|
|
850
|
-
update_stack(stack_name_crash, stack_body, parameters, tags) unless cur_version.include?(@projects["crash"][:revision])
|
|
851
|
+
update_stack(stack_name_crash, stack_body, parameters, tags, @cf_role) unless cur_version.include?(@projects["crash"][:revision])
|
|
851
852
|
else
|
|
852
|
-
create_stack(stack_name_crash, stack_body, parameters, tags)
|
|
853
|
+
create_stack(stack_name_crash, stack_body, parameters, tags, @cf_role)
|
|
853
854
|
end
|
|
854
855
|
wait_for_stack_ready(stack_name_crash) unless stack_ready?(stack_name_crash)
|
|
855
856
|
update_service_defaults(stack_name_crash)
|
|
@@ -969,7 +970,7 @@ class Release
|
|
|
969
970
|
parameter_value: @ecs_cluster_name
|
|
970
971
|
}
|
|
971
972
|
]
|
|
972
|
-
create_stack(stack_name_db, stack_body, parameters, tags) unless stack_exists?(stack_name_db)
|
|
973
|
+
create_stack(stack_name_db, stack_body, parameters, tags, @cf_role) unless stack_exists?(stack_name_db)
|
|
973
974
|
|
|
974
975
|
create_prima_artifact(@projects["prima"][:revision], @projects["prima"][:name], deploy_id) unless artifact_exists?('prima-artifacts-encrypted', "prima/#{@projects["prima"][:revision]}-#{deploy_id}.tar.gz")
|
|
975
976
|
create_crash_artifact(@projects['crash'][:revision], deploy_id) unless !deploy_crash? || artifact_exists?('prima-artifacts-encrypted', "microservices/crash/#{@projects['crash'][:revision]}-#{deploy_id}-qa.tar.gz")
|
|
@@ -1054,7 +1055,7 @@ class Release
|
|
|
1054
1055
|
}
|
|
1055
1056
|
]
|
|
1056
1057
|
|
|
1057
|
-
create_stack(stack_name_route53, stack_body, parameters, tags) unless stack_exists?(stack_name_route53)
|
|
1058
|
+
create_stack(stack_name_route53, stack_body, parameters, tags, @cf_role) unless stack_exists?(stack_name_route53)
|
|
1058
1059
|
wait_for_stack_ready(stack_name_route53) unless stack_ready?(stack_name_route53)
|
|
1059
1060
|
|
|
1060
1061
|
stack_name_urania = "ecs-task-urania-qa-#{deploy_id}"
|
|
@@ -1088,9 +1089,9 @@ class Release
|
|
|
1088
1089
|
]
|
|
1089
1090
|
if stack_exists?(stack_name_urania)
|
|
1090
1091
|
cur_version = get_currently_deployed_version(stack_name_urania)
|
|
1091
|
-
update_stack(stack_name_urania, stack_body, parameters, tags) unless cur_version.include?(@projects["urania"][:revision])
|
|
1092
|
+
update_stack(stack_name_urania, stack_body, parameters, tags, @cf_role) unless cur_version.include?(@projects["urania"][:revision])
|
|
1092
1093
|
else
|
|
1093
|
-
create_stack(stack_name_urania, stack_body, parameters, tags)
|
|
1094
|
+
create_stack(stack_name_urania, stack_body, parameters, tags, @cf_role)
|
|
1094
1095
|
end
|
|
1095
1096
|
|
|
1096
1097
|
stack_name_ermes = "ecs-task-ermes-qa-#{deploy_id}"
|
|
@@ -1124,9 +1125,9 @@ class Release
|
|
|
1124
1125
|
]
|
|
1125
1126
|
if stack_exists?(stack_name_ermes)
|
|
1126
1127
|
cur_version = get_currently_deployed_version(stack_name_ermes)
|
|
1127
|
-
update_stack(stack_name_ermes, stack_body, parameters, tags) unless cur_version.include?(@projects["ermes"][:revision])
|
|
1128
|
+
update_stack(stack_name_ermes, stack_body, parameters, tags, @cf_role) unless cur_version.include?(@projects["ermes"][:revision])
|
|
1128
1129
|
else
|
|
1129
|
-
create_stack(stack_name_ermes, stack_body, parameters, tags)
|
|
1130
|
+
create_stack(stack_name_ermes, stack_body, parameters, tags, @cf_role)
|
|
1130
1131
|
end
|
|
1131
1132
|
|
|
1132
1133
|
stack_name_bburago = "ecs-task-bburago-qa-#{deploy_id}"
|
|
@@ -1160,9 +1161,9 @@ class Release
|
|
|
1160
1161
|
]
|
|
1161
1162
|
if stack_exists?(stack_name_bburago)
|
|
1162
1163
|
cur_version = get_currently_deployed_version(stack_name_bburago)
|
|
1163
|
-
update_stack(stack_name_bburago, stack_body, parameters, tags) unless cur_version.include?(@projects["bburago"][:revision])
|
|
1164
|
+
update_stack(stack_name_bburago, stack_body, parameters, tags, @cf_role) unless cur_version.include?(@projects["bburago"][:revision])
|
|
1164
1165
|
else
|
|
1165
|
-
create_stack(stack_name_bburago, stack_body, parameters, tags)
|
|
1166
|
+
create_stack(stack_name_bburago, stack_body, parameters, tags, @cf_role)
|
|
1166
1167
|
end
|
|
1167
1168
|
|
|
1168
1169
|
stack_name_hal9000 = "ecs-task-hal9000-qa-#{deploy_id}"
|
|
@@ -1196,9 +1197,9 @@ class Release
|
|
|
1196
1197
|
]
|
|
1197
1198
|
if stack_exists?(stack_name_hal9000)
|
|
1198
1199
|
cur_version = get_currently_deployed_version(stack_name_hal9000)
|
|
1199
|
-
update_stack(stack_name_hal9000, stack_body, parameters, tags) unless cur_version.include?(@projects["hal9000"][:revision])
|
|
1200
|
+
update_stack(stack_name_hal9000, stack_body, parameters, tags, @cf_role) unless cur_version.include?(@projects["hal9000"][:revision])
|
|
1200
1201
|
else
|
|
1201
|
-
create_stack(stack_name_hal9000, stack_body, parameters, tags)
|
|
1202
|
+
create_stack(stack_name_hal9000, stack_body, parameters, tags, @cf_role)
|
|
1202
1203
|
end
|
|
1203
1204
|
|
|
1204
1205
|
stack_name_fidaty = "ecs-task-fidaty-qa-#{deploy_id}"
|
|
@@ -1232,9 +1233,9 @@ class Release
|
|
|
1232
1233
|
]
|
|
1233
1234
|
if stack_exists?(stack_name_fidaty)
|
|
1234
1235
|
cur_version = get_currently_deployed_version(stack_name_fidaty)
|
|
1235
|
-
update_stack(stack_name_fidaty, stack_body, parameters, tags) unless cur_version.include?(@projects["fidaty"][:revision])
|
|
1236
|
+
update_stack(stack_name_fidaty, stack_body, parameters, tags, @cf_role) unless cur_version.include?(@projects["fidaty"][:revision])
|
|
1236
1237
|
else
|
|
1237
|
-
create_stack(stack_name_fidaty, stack_body, parameters, tags)
|
|
1238
|
+
create_stack(stack_name_fidaty, stack_body, parameters, tags, @cf_role)
|
|
1238
1239
|
end
|
|
1239
1240
|
|
|
1240
1241
|
stack_name_peano = "ecs-task-peano-qa-#{deploy_id}"
|
|
@@ -1268,9 +1269,9 @@ class Release
|
|
|
1268
1269
|
]
|
|
1269
1270
|
if stack_exists?(stack_name_peano)
|
|
1270
1271
|
cur_version = get_currently_deployed_version(stack_name_peano)
|
|
1271
|
-
update_stack(stack_name_peano, stack_body, parameters, tags) unless cur_version.include?(@projects["peano"][:revision])
|
|
1272
|
+
update_stack(stack_name_peano, stack_body, parameters, tags, @cf_role) unless cur_version.include?(@projects["peano"][:revision])
|
|
1272
1273
|
else
|
|
1273
|
-
create_stack(stack_name_peano, stack_body, parameters, tags)
|
|
1274
|
+
create_stack(stack_name_peano, stack_body, parameters, tags, @cf_role)
|
|
1274
1275
|
end
|
|
1275
1276
|
|
|
1276
1277
|
stack_name_rogoreport = "ecs-task-rogoreport-qa-#{deploy_id}"
|
|
@@ -1296,9 +1297,9 @@ class Release
|
|
|
1296
1297
|
]
|
|
1297
1298
|
if stack_exists?(stack_name_rogoreport)
|
|
1298
1299
|
cur_version = get_currently_deployed_version(stack_name_rogoreport)
|
|
1299
|
-
update_stack(stack_name_rogoreport, stack_body, parameters, tags) unless cur_version.include?(@projects["rogoreport"][:revision])
|
|
1300
|
+
update_stack(stack_name_rogoreport, stack_body, parameters, tags, @cf_role) unless cur_version.include?(@projects["rogoreport"][:revision])
|
|
1300
1301
|
else
|
|
1301
|
-
create_stack(stack_name_rogoreport, stack_body, parameters, tags)
|
|
1302
|
+
create_stack(stack_name_rogoreport, stack_body, parameters, tags, @cf_role)
|
|
1302
1303
|
end
|
|
1303
1304
|
|
|
1304
1305
|
stack_name_assange = "ecs-task-assange-qa-#{deploy_id}"
|
|
@@ -1340,9 +1341,9 @@ class Release
|
|
|
1340
1341
|
]
|
|
1341
1342
|
if stack_exists?(stack_name_assange)
|
|
1342
1343
|
cur_version = get_currently_deployed_version(stack_name_assange)
|
|
1343
|
-
update_stack(stack_name_assange, stack_body, parameters, tags) unless cur_version.include?(@projects["assange"][:revision])
|
|
1344
|
+
update_stack(stack_name_assange, stack_body, parameters, tags, @cf_role) unless cur_version.include?(@projects["assange"][:revision])
|
|
1344
1345
|
else
|
|
1345
|
-
create_stack(stack_name_assange, stack_body, parameters, tags)
|
|
1346
|
+
create_stack(stack_name_assange, stack_body, parameters, tags, @cf_role)
|
|
1346
1347
|
end
|
|
1347
1348
|
|
|
1348
1349
|
stack_name_borat = "ecs-task-borat-qa-#{deploy_id}"
|
|
@@ -1384,9 +1385,9 @@ class Release
|
|
|
1384
1385
|
]
|
|
1385
1386
|
if stack_exists?(stack_name_borat)
|
|
1386
1387
|
cur_version = get_currently_deployed_version(stack_name_borat)
|
|
1387
|
-
update_stack(stack_name_borat, stack_body, parameters, tags) unless cur_version.include?(@projects["borat"][:revision])
|
|
1388
|
+
update_stack(stack_name_borat, stack_body, parameters, tags, @cf_role) unless cur_version.include?(@projects["borat"][:revision])
|
|
1388
1389
|
else
|
|
1389
|
-
create_stack(stack_name_borat, stack_body, parameters, tags)
|
|
1390
|
+
create_stack(stack_name_borat, stack_body, parameters, tags, @cf_role)
|
|
1390
1391
|
end
|
|
1391
1392
|
|
|
1392
1393
|
git_checkout_version('backoffice', @projects["backoffice"][:revision])
|
|
@@ -1428,9 +1429,9 @@ class Release
|
|
|
1428
1429
|
]
|
|
1429
1430
|
if stack_exists?(stack_name_backoffice)
|
|
1430
1431
|
cur_version = get_currently_deployed_version(stack_name_backoffice)
|
|
1431
|
-
update_stack(stack_name_backoffice, stack_body, parameters, tags) unless cur_version.include?(@projects["backoffice"][:revision])
|
|
1432
|
+
update_stack(stack_name_backoffice, stack_body, parameters, tags, @cf_role) unless cur_version.include?(@projects["backoffice"][:revision])
|
|
1432
1433
|
else
|
|
1433
|
-
create_stack(stack_name_backoffice, stack_body, parameters, tags)
|
|
1434
|
+
create_stack(stack_name_backoffice, stack_body, parameters, tags, @cf_role)
|
|
1434
1435
|
end
|
|
1435
1436
|
|
|
1436
1437
|
if deploy_crash?
|
|
@@ -1473,9 +1474,9 @@ class Release
|
|
|
1473
1474
|
]
|
|
1474
1475
|
if stack_exists?(stack_name_crash)
|
|
1475
1476
|
cur_version = get_currently_deployed_version(stack_name_crash)
|
|
1476
|
-
update_stack(stack_name_crash, stack_body, parameters, tags) unless cur_version.include?(@projects["crash"][:revision])
|
|
1477
|
+
update_stack(stack_name_crash, stack_body, parameters, tags, @cf_role) unless cur_version.include?(@projects["crash"][:revision])
|
|
1477
1478
|
else
|
|
1478
|
-
create_stack(stack_name_crash, stack_body, parameters, tags)
|
|
1479
|
+
create_stack(stack_name_crash, stack_body, parameters, tags, @cf_role)
|
|
1479
1480
|
end
|
|
1480
1481
|
end
|
|
1481
1482
|
|
|
@@ -1510,9 +1511,9 @@ class Release
|
|
|
1510
1511
|
]
|
|
1511
1512
|
if stack_exists?(stack_name_activia)
|
|
1512
1513
|
cur_version = get_currently_deployed_version(stack_name_activia)
|
|
1513
|
-
update_stack(stack_name_activia, stack_body, parameters, tags) unless cur_version.include?(@projects["activia"][:revision])
|
|
1514
|
+
update_stack(stack_name_activia, stack_body, parameters, tags, @cf_role) unless cur_version.include?(@projects["activia"][:revision])
|
|
1514
1515
|
else
|
|
1515
|
-
create_stack(stack_name_activia, stack_body, parameters, tags)
|
|
1516
|
+
create_stack(stack_name_activia, stack_body, parameters, tags, @cf_role)
|
|
1516
1517
|
end
|
|
1517
1518
|
|
|
1518
1519
|
# Waiting for prima healtcheck dependencies
|
|
@@ -1569,9 +1570,9 @@ class Release
|
|
|
1569
1570
|
]
|
|
1570
1571
|
if stack_exists?(stack_name_web)
|
|
1571
1572
|
cur_version = get_currently_deployed_version(stack_name_web)
|
|
1572
|
-
update_stack(stack_name_web, stack_body, parameters, tags) unless cur_version.include?(@projects["prima"][:revision])
|
|
1573
|
+
update_stack(stack_name_web, stack_body, parameters, tags, @cf_role) unless cur_version.include?(@projects["prima"][:revision])
|
|
1573
1574
|
else
|
|
1574
|
-
create_stack(stack_name_web, stack_body, parameters, tags)
|
|
1575
|
+
create_stack(stack_name_web, stack_body, parameters, tags, @cf_role)
|
|
1575
1576
|
end
|
|
1576
1577
|
|
|
1577
1578
|
stack_name_consumer = "ecs-task-consumer-qa-#{deploy_id}"
|
|
@@ -1593,9 +1594,9 @@ class Release
|
|
|
1593
1594
|
]
|
|
1594
1595
|
if stack_exists?(stack_name_consumer)
|
|
1595
1596
|
cur_version = get_currently_deployed_version(stack_name_consumer)
|
|
1596
|
-
update_stack(stack_name_consumer, stack_body, parameters, tags) unless cur_version.include?(@projects["prima"][:revision])
|
|
1597
|
+
update_stack(stack_name_consumer, stack_body, parameters, tags, @cf_role) unless cur_version.include?(@projects["prima"][:revision])
|
|
1597
1598
|
else
|
|
1598
|
-
create_stack(stack_name_consumer, stack_body, parameters, tags)
|
|
1599
|
+
create_stack(stack_name_consumer, stack_body, parameters, tags, @cf_role)
|
|
1599
1600
|
end
|
|
1600
1601
|
|
|
1601
1602
|
wait_for_stack_ready(stack_name_web) unless stack_ready?(stack_name_web)
|
|
@@ -2603,7 +2604,7 @@ class Release
|
|
|
2603
2604
|
parameter_value: @ecs_cluster_name
|
|
2604
2605
|
}
|
|
2605
2606
|
]
|
|
2606
|
-
create_stack(stack_name, stack_body, parameters, tags)
|
|
2607
|
+
create_stack(stack_name, stack_body, parameters, tags, @cf_role)
|
|
2607
2608
|
end
|
|
2608
2609
|
|
|
2609
2610
|
def create_cluster_stack(stack_name, tags = [])
|
|
@@ -2632,7 +2633,7 @@ class Release
|
|
|
2632
2633
|
parameter_value: hash
|
|
2633
2634
|
}
|
|
2634
2635
|
]
|
|
2635
|
-
create_stack(stack_name, stack_body, parameters)
|
|
2636
|
+
create_stack(stack_name, stack_body, parameters, @cf_role)
|
|
2636
2637
|
end
|
|
2637
2638
|
|
|
2638
2639
|
def import_redis_crash(qa_ip_address)
|
data/lib/prima_aws_client.rb
CHANGED
|
@@ -40,16 +40,22 @@ module PrimaAwsClient
|
|
|
40
40
|
stacks
|
|
41
41
|
end
|
|
42
42
|
|
|
43
|
-
def create_stack(stack_name, stack_body, parameters = [], tags = [])
|
|
43
|
+
def create_stack(stack_name, stack_body, parameters = [], tags = [], role = nil)
|
|
44
|
+
cf_args = {
|
|
45
|
+
stack_name: stack_name,
|
|
46
|
+
template_body: stack_body,
|
|
47
|
+
parameters: parameters,
|
|
48
|
+
tags: tags,
|
|
49
|
+
capabilities: ['CAPABILITY_IAM'],
|
|
50
|
+
on_failure: 'ROLLBACK'
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
if role != nil then
|
|
54
|
+
cf_args.merge!(role_arn: role)
|
|
55
|
+
end
|
|
56
|
+
|
|
44
57
|
begin
|
|
45
|
-
cf_client.create_stack(
|
|
46
|
-
stack_name: stack_name,
|
|
47
|
-
template_body: stack_body,
|
|
48
|
-
parameters: parameters,
|
|
49
|
-
tags: tags,
|
|
50
|
-
capabilities: ['CAPABILITY_IAM'],
|
|
51
|
-
on_failure: 'ROLLBACK'
|
|
52
|
-
)
|
|
58
|
+
cf_client.create_stack(cf_args)
|
|
53
59
|
rescue Aws::CloudFormation::Errors::Throttling, Aws::CloudFormation::Errors::LimitExcedeedException => e
|
|
54
60
|
output 'Throttling, retrying in 15 seconds'.red
|
|
55
61
|
sleep 15
|
|
@@ -59,15 +65,21 @@ module PrimaAwsClient
|
|
|
59
65
|
end
|
|
60
66
|
end
|
|
61
67
|
|
|
62
|
-
def update_stack(stack_name, template_body, parameters = [], tags = [])
|
|
68
|
+
def update_stack(stack_name, template_body, parameters = [], tags = [], role = nil)
|
|
69
|
+
cf_args = {
|
|
70
|
+
stack_name: stack_name,
|
|
71
|
+
template_body: template_body,
|
|
72
|
+
parameters: parameters,
|
|
73
|
+
tags: tags,
|
|
74
|
+
capabilities: ['CAPABILITY_IAM']
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
if role != nil then
|
|
78
|
+
cf_args.merge!(role_arn: role)
|
|
79
|
+
end
|
|
80
|
+
|
|
63
81
|
begin
|
|
64
|
-
cf_client.update_stack(
|
|
65
|
-
stack_name: stack_name,
|
|
66
|
-
template_body: template_body,
|
|
67
|
-
parameters: parameters,
|
|
68
|
-
tags: tags,
|
|
69
|
-
capabilities: ['CAPABILITY_IAM']
|
|
70
|
-
)
|
|
82
|
+
cf_client.update_stack(cf_args)
|
|
71
83
|
rescue Aws::CloudFormation::Errors::Throttling => e
|
|
72
84
|
output 'Throttling, retrying in 15 seconds'.red
|
|
73
85
|
sleep 15
|
|
@@ -79,15 +91,21 @@ module PrimaAwsClient
|
|
|
79
91
|
end
|
|
80
92
|
end
|
|
81
93
|
|
|
82
|
-
def update_stack_url(stack_name, template_url, parameters = [], tags = [])
|
|
94
|
+
def update_stack_url(stack_name, template_url, parameters = [], tags = [], role = nil)
|
|
95
|
+
cf_args = {
|
|
96
|
+
stack_name: stack_name,
|
|
97
|
+
template_url: template_url,
|
|
98
|
+
parameters: parameters,
|
|
99
|
+
tags: tags,
|
|
100
|
+
capabilities: ['CAPABILITY_IAM']
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
if role != nil then
|
|
104
|
+
cf_args.merge!(role_arn: role)
|
|
105
|
+
end
|
|
106
|
+
|
|
83
107
|
begin
|
|
84
|
-
cf_client.update_stack(
|
|
85
|
-
stack_name: stack_name,
|
|
86
|
-
template_url: template_url,
|
|
87
|
-
parameters: parameters,
|
|
88
|
-
tags: tags,
|
|
89
|
-
capabilities: ['CAPABILITY_IAM']
|
|
90
|
-
)
|
|
108
|
+
cf_client.update_stack(cf_args)
|
|
91
109
|
rescue Aws::CloudFormation::Errors::Throttling => e
|
|
92
110
|
output 'Throttling, retrying in 15 seconds'.red
|
|
93
111
|
sleep 15
|