Exemplo n.º 1
0
 def _provision(self):
     if utils.do_exec(self.CONF.job_params.reprovision):
         if (utils.do_exec(self.CONF.job_params.rebuild_test_client) and
            utils.do_exec(self.CONF.job_params.run_tests)):
             test_client_fqdn = self.CONF.job_params.test_client_fqdn
             self.hosts_fqdn.append(test_client_fqdn)
         self.provisioner.provision_hosts(list(set(self.hosts_fqdn)))
     else:
         LOG.info('Reprovisioning disabled, Skipping...')
Exemplo n.º 2
0
 def _install_openstack(self):
     if utils.do_exec(self.CONF.job_params.install_openstack):
         if self.CONF.job_params.openstack_installer == 'packstack':
             controller_host = self.deployer.get_controller_host()
             networker_host = self.deployer.get_networker_host()
             controller_host.open_connection()
             self.deployer.generate_ssh_key(controller_host)
             self.deployer.distribute_public_key_to_openstack_hosts(
                 controller_host)
             self.deployer.configurations.install_rpm(controller_host,
                                                      'openstack-packstack')
             self.deployer.installer.generate_answer_file(controller_host)
             self.deployer.installer.configure_answer_file(controller_host,
                                                           networker_host,
                                                           self.deployer.
                                                           openstack_hosts)
             self.deployer.installer.install_openstack(controller_host)
             LOG.info('Rebooting All nodes due to possible kernel update')
             self.provisioner.reboot_hosts(list(set(self.hosts_fqdn)))
             # Allows host to gracefully reboot
             sleep(consts.SshIntervals.REBOOT_SLEEP)
             self.provisioner._wait_for_reprovision_to_finish(
                 list(set(self.hosts_fqdn)))
     else:
         LOG.info('OpenStack installation set to false, Skipping...')
Exemplo n.º 3
0
 def _configure_repositories(self):
     if utils.do_exec(self.CONF.job_params.repositories):
         self.deployer.config_all_openstack_hosts('remove_all_yum_repos')
         self.deployer.create_yum_repos_all_openstack_hosts(
             self.CONF.job_params.repositories,
             self.CONF.job_params.openstack_build)
     else:
         LOG.info('Repository list is empty, Skipping...')
Exemplo n.º 4
0
 def _run_tests(self):
     # WIP
     if utils.do_exec(self.CONF.job_params.run_tests):
         tests_repository = self.CONF.job_params.tests_repository
         tests = self.CONF.job_params.tests
Exemplo n.º 5
0
 def _postinstall_configs(self):
     if utils.do_exec(self.CONF.job_params.post_install_configs):
         post_confs = self.CONF.job_params.post_install_configs
         self.deployer.config_all_openstack_hosts(post_confs)
     else:
         LOG.info('Post installation configs list is empty, Skipping...')