diff options
author | Michael DeHaan <mdehaan@redhat.com> | 2006-10-12 18:04:08 -0400 |
---|---|---|
committer | Jim Meyering <jim@meyering.net> | 2006-10-12 18:04:08 -0400 |
commit | 6e84895b828b4fa5e3c45464dd08949fa382dfa5 (patch) | |
tree | d8a23136fc4a777eafe5e84260a1d7cf00005aeb /cobbler/api.py | |
parent | 456770c8daa2f3f74d4158a6038e28fcc6cd911f (diff) | |
download | third_party-cobbler-6e84895b828b4fa5e3c45464dd08949fa382dfa5.tar.gz third_party-cobbler-6e84895b828b4fa5e3c45464dd08949fa382dfa5.tar.xz third_party-cobbler-6e84895b828b4fa5e3c45464dd08949fa382dfa5.zip |
Initial code behind an import feature for directory trees, i.e. to transform something like
/mnt/redhat (containing a lot of OS builds with trees) into distributions and profiles directly.
Diffstat (limited to 'cobbler/api.py')
-rw-r--r-- | cobbler/api.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/cobbler/api.py b/cobbler/api.py index 186eca6..f4387eb 100644 --- a/cobbler/api.py +++ b/cobbler/api.py @@ -19,6 +19,7 @@ import utils import action_sync import action_check import action_enchant +import action_import import cexceptions class BootAPI: @@ -115,12 +116,12 @@ class BootAPI: enchant = action_enchant.Enchant(self._config,sysname,password) return enchant.run() - def import_distros(self,tree_path): + def import_tree(self,tree_path): """ Automatically import a directory tree full of distribution files. """ - print "STUB: NOT IMPLEMENTED YET" - return False + importer = action_import.Importer(self._config, tree_path) + return importer.run() def serialize(self): """ |