lib/mikoshi/plan/service.rb in mikoshi-0.1.2 vs lib/mikoshi/plan/service.rb in mikoshi-0.1.3
- old
+ new
@@ -24,13 +24,13 @@
@client.update_service(@data.except(:service_name))
end
def deploy_service
resp = @client.describe_services(cluster: @data[:cluster], services: [@data[:service]])
- if resp.services.first.status == 'ACTIVE'
- update_service
- else
+ if resp.services.empty?
create_service
+ else
+ update_service
end
end
def deployed?
resp = @client.describe_services(cluster: @data[:cluster], services: [@data[:service]])