Move the cleaner for nova into a tools dir

This commit is contained in:
Joshua Harlow
2012-11-16 19:42:46 -08:00
parent 552ea53335
commit 5642e66cc0
2 changed files with 6 additions and 3 deletions

View File

@@ -95,7 +95,7 @@ class NovaUninstaller(comp.PythonUninstallComponent):
self._clean_it()
def _clean_it(self):
cleaner_fn = sh.joinpths(self.get_option('app_dir'), BIN_DIR, CLEANER_DATA_CONF)
cleaner_fn = sh.joinpths(self.get_option('component_dir'), 'tools', CLEANER_DATA_CONF)
if sh.isfile(cleaner_fn):
LOG.info("Cleaning up your system by running nova cleaner script: %s", colorizer.quote(cleaner_fn))
# These environment additions are important
@@ -161,8 +161,10 @@ class NovaInstaller(comp.PythonInstallComponent):
def _setup_cleaner(self):
LOG.info("Configuring cleaner template: %s", colorizer.quote(CLEANER_DATA_CONF))
(_fn, contents) = utils.load_template(self.name, CLEANER_DATA_CONF)
# FIXME(harlowja), stop placing in checkout dir...
cleaner_fn = sh.joinpths(sh.joinpths(self.get_option('app_dir'), BIN_DIR), CLEANER_DATA_CONF)
cleaner_fn = sh.joinpths(self.get_option('component_dir'), 'tools', CLEANER_DATA_CONF)
if not sh.isdir(sh.dirname(cleaner_fn)):
dirs_made = sh.mkdirslist(sh.dirname(cleaner_fn))
self.tracewriter.dirs_made(*dirs_made)
sh.write_file(cleaner_fn, contents)
sh.chmod(cleaner_fn, 0755)
self.tracewriter.file_touched(cleaner_fn)

View File

@@ -249,6 +249,7 @@ components:
- name: nosehtmloutput
- name: openstack.nose_plugin
- name: pep8 # The rhel version appears to not be new enough...
version: "1.2"
- name: prettytable
version: "0.6.1"
- name: pycrypto