Skip to content

Commit 82a0339

Browse files
committed
fix(controller): use new fleetctl semantics
Fleetctl 0.3.2 by default will test for a unit's goal status 10 times, once every tenth of a second, before failing. This is not generous enough, so on starting services we do it async with `-no-block` and then poll for goal status, and on stopping we wait 60 seconds.
1 parent 1c67726 commit 82a0339

1 file changed

Lines changed: 6 additions & 6 deletions

File tree

controller/scheduler/coreos.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -95,17 +95,17 @@ def start(self, name):
9595

9696
def _start_log(self, name, env):
9797
subprocess.check_call(
98-
'fleetctl.sh start {name}-log.service'.format(**locals()),
98+
'fleetctl.sh start -no-block {name}-log.service'.format(**locals()),
9999
shell=True, env=env)
100100

101101
def _start_container(self, name, env):
102102
return subprocess.check_call(
103-
'fleetctl.sh start {name}.service'.format(**locals()),
103+
'fleetctl.sh start -no-block {name}.service'.format(**locals()),
104104
shell=True, env=env)
105105

106106
def _start_announcer(self, name, env):
107107
return subprocess.check_call(
108-
'fleetctl.sh start {name}-announce.service'.format(**locals()),
108+
'fleetctl.sh start -no-block {name}-announce.service'.format(**locals()),
109109
shell=True, env=env)
110110

111111
def _wait_for_announcer(self, name, env):
@@ -132,17 +132,17 @@ def stop(self, name):
132132

133133
def _stop_container(self, name, env):
134134
return subprocess.check_call(
135-
'fleetctl.sh stop {name}.service'.format(**locals()),
135+
'fleetctl.sh stop -block-attempts=600 {name}.service'.format(**locals()),
136136
shell=True, env=env)
137137

138138
def _stop_announcer(self, name, env):
139139
return subprocess.check_call(
140-
'fleetctl.sh stop {name}-announce.service'.format(**locals()),
140+
'fleetctl.sh stop -block-attempts=600 {name}-announce.service'.format(**locals()),
141141
shell=True, env=env)
142142

143143
def _stop_log(self, name, env):
144144
return subprocess.check_call(
145-
'fleetctl.sh stop {name}-announce.service'.format(**locals()),
145+
'fleetctl.sh stop -block-attempts=600 {name}-log.service'.format(**locals()),
146146
shell=True, env=env)
147147

148148
def destroy(self, name):

0 commit comments

Comments
 (0)