Skip to content

Commit

Permalink
Merge branch 'master' of github.com:zalando/spilo
Browse files Browse the repository at this point in the history
  • Loading branch information
feikesteenbergen committed Sep 9, 2015
2 parents 22c920e + dbba063 commit f7c99ec
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions etcd-cluster-appliance/etcd.py
Original file line number Diff line number Diff line change
Expand Up @@ -388,8 +388,9 @@ def members_changed(self):
return changed

def cluster_unhealthy(self):
process = subprocess.Popen([self.manager.ETCD_BINARY + 'ctl', 'cluster-health'], stdout=subprocess.PIPE)
ret = any([True for line in process.stdout if 'is unhealthy' in str(line)])
process = subprocess.Popen([self.manager.ETCD_BINARY + 'ctl', 'cluster-health'],
stdout=subprocess.PIPE, stderr=subprocess.STDOUT)
ret = any([True for line in process.stdout if 'is unhealthy' in str(line) or 'is unreachable' in str(line)])
process.wait()
return ret

Expand Down

0 comments on commit f7c99ec

Please sign in to comment.