Merge pull request #87 from orchardup/stop-projects-in-reverse-order-to-starting

Stop projects in reverse order to starting
This commit is contained in:
Aanand Prasad 2014-02-09 16:22:05 -08:00
commit 7faba11245
1 changed files with 3 additions and 3 deletions

View File

@ -116,11 +116,11 @@ class Project(object):
service.start(**options) service.start(**options)
def stop(self, service_names=None, **options): def stop(self, service_names=None, **options):
for service in self.get_services(service_names): for service in reversed(self.get_services(service_names)):
service.stop(**options) service.stop(**options)
def kill(self, service_names=None, **options): def kill(self, service_names=None, **options):
for service in self.get_services(service_names): for service in reversed(self.get_services(service_names)):
service.kill(**options) service.kill(**options)
def build(self, service_names=None, **options): def build(self, service_names=None, **options):
@ -156,4 +156,4 @@ class DependencyError(Exception):
self.msg = msg self.msg = msg
def __str__(self): def __str__(self):
return self.msg return self.msg