diff options
author | Michael DeHaan <mdehaan@redhat.com> | 2008-05-29 12:09:29 -0400 |
---|---|---|
committer | Michael DeHaan <mdehaan@redhat.com> | 2008-05-29 12:09:29 -0400 |
commit | 59ecc2ebecdf10d46db2b8606b25a16c46c74e64 (patch) | |
tree | 115e17fa66283388cad8fb34c2af032945e92ca3 /cobbler | |
parent | e785e654cdc413d4366ec857b7400b266403a1f3 (diff) | |
download | third_party-cobbler-59ecc2ebecdf10d46db2b8606b25a16c46c74e64.tar.gz third_party-cobbler-59ecc2ebecdf10d46db2b8606b25a16c46c74e64.tar.xz third_party-cobbler-59ecc2ebecdf10d46db2b8606b25a16c46c74e64.zip |
Do not own tftpboot, but create subdirs as needed automatically.
Diffstat (limited to 'cobbler')
-rw-r--r-- | cobbler/action_sync.py | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/cobbler/action_sync.py b/cobbler/action_sync.py index 55cdad5..fab96a6 100644 --- a/cobbler/action_sync.py +++ b/cobbler/action_sync.py @@ -129,7 +129,14 @@ class BootSync: if x in ["kickstarts","kickstarts_sys","images","systems","distros","profiles","repo_profile","repo_system"]: # clean out directory contents utils.rmtree_contents(path) + pxelinux_dir = os.path.join(self.bootloc, "pxelinux.cfg") + images_dir = os.path.join(self.bootloc, "images") + if not os.path.exists(pxelinux_dir): + utils.makedir(pxelinux_dir) + if not os.path.exists(images_dir): + utils.makedir(images_dir) utils.rmtree_contents(os.path.join(self.bootloc, "pxelinux.cfg")) utils.rmtree_contents(os.path.join(self.bootloc, "images")) + |