summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--service/container.go3
1 files changed, 2 insertions, 1 deletions
diff --git a/service/container.go b/service/container.go
index 98b24a11..bf5f6089 100644
--- a/service/container.go
+++ b/service/container.go
@@ -125,7 +125,6 @@ func (c *container) Serve() error {
numServing int
done = make(chan interface{}, len(c.services))
)
- defer close(done)
for _, e := range c.services {
if e.hasStatus(StatusConfigured) {
@@ -142,6 +141,8 @@ func (c *container) Serve() error {
if err := e.svc.Serve(); err != nil {
c.log.Errorf("[%s]: %s", e.name, err)
done <- errors.Wrap(err, fmt.Sprintf("[%s]", e.name))
+ } else {
+ done <- nil
}
}(e)
}