Skip to content
Snippets Groups Projects
Commit dedb79f2 authored by Jan Mach's avatar Jan Mach
Browse files

Implemented status check after 'stop' command.

Script will try to determine, if the startup was successfull, or not. It also exits with appropriate exit code.
parent a9402d91
No related branches found
No related tags found
No related merge requests found
......@@ -511,6 +511,15 @@ class MentatControllerScript(pyzenkit.zenscript.ZenScript):
else:
self.logger.info("Module '{}': Module is in weird state, unable to perform automatic shutdown".format(cname))
self.logger.info("Waiting for modules to fully shut down")
time.sleep(1)
status = self._modules_status()
if status['result'][0] == STATUS_NOT_RUNNING:
self.logger.info("System shutdown seems successfull")
else:
self.logger.info("System shutdown seems to have failed")
self.rc = status['result'][0]
return self.RESULT_SUCCESS
def cbk_command_signal_kill(self):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment