Class: Shipitron::Client::ForceDeploy
- Inherits:
-
Object
- Object
- Shipitron::Client::ForceDeploy
- Includes:
- Interactor::Organizer, Metaractor, EcsClient
- Defined in:
- lib/shipitron/client/force_deploy.rb
Instance Method Summary collapse
Methods included from EcsClient
#ecs_client, #generate_ecs_client
Instance Method Details
#call ⇒ Object
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 |
# File 'lib/shipitron/client/force_deploy.rb', line 23 def call Logger.info "==> Force deploying #{application}" super context.clusters ||= [] context.ecs_services ||= [] begin context.clusters.each do |cluster| context.ecs_services.each do |service| ecs_client(region: cluster.region).update_service( cluster: cluster.name, service: service, force_new_deployment: true ) end end rescue Aws::ECS::Errors::ServiceError => e fail_with_errors!(messages: [ "Error: #{e.}", e.backtrace.join("\n") ]) end Logger.info "==> Done" end |