def _start_chronos_job(self, job_resource): if CONF.update: LOG.info('Bootstrap tasks for upgrade are not implemented yet!') else: try: return self.chronos_client.add_job(job_resource) except exception.ChronosRollback as e: cleanup.cleanup() self.write_to_zookeeper() raise e
def _start_marathon_app(self, app_resource): if CONF.update: LOG.info('Applications upgrade is not implemented yet!') else: try: return self.marathon_client.add_app(app_resource) except exception.MarathonRollback as e: cleanup.cleanup() self.write_to_zookeeper() raise e
def take_action(self, parsed_args): cleanup.cleanup()
def main(): CONF(sys.argv[1:], project='kolla-mesos') logging.setup(CONF, 'kolla-mesos') cleanup.cleanup()