File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -50,11 +50,23 @@ AWSClient.elbv2.register_targets({
5050 targets : new_targets
5151} )
5252
53- AWSClient . elbv2 . wait_until (
54- :target_in_service ,
55- target_group_arn : tg . target_group_arn ,
56- targets : new_targets
57- )
53+ begin
54+ AWSClient . elbv2 . wait_until (
55+ :target_in_service ,
56+ target_group_arn : tg . target_group_arn ,
57+ targets : new_targets ,
58+ )
59+ rescue
60+ puts "The new containers are failing the elb health check"
61+
62+ AWSClient . elbv2 . deregister_targets ( {
63+ target_group_arn : tg . target_group_arn ,
64+ targets : new_targets
65+ } )
66+
67+ raise "The new containers are failing the elb health check"
68+ end
69+
5870
5971puts "\n #{ color . capitalize } target in service"
6072
Original file line number Diff line number Diff line change 11Gem ::Specification . new do |s |
22 s . name = 'deploy-tools'
3- s . version = '0.1.2 '
3+ s . version = '0.1.4 '
44 s . date = '2022-06-28'
55 s . summary = "Deploy tools"
66 s . description = "A set of script used for deployment"
You can’t perform that action at this time.
0 commit comments