From 71c4ba479d6395e566a3517afdd4baafd5a3acb1 Mon Sep 17 00:00:00 2001 From: Michael DeHaan Date: Tue, 28 Aug 2007 14:01:34 -0400 Subject: Fix reposync if using rsync as a source and paths don't contain an arch --- cobbler/action_reposync.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'cobbler/action_reposync.py') diff --git a/cobbler/action_reposync.py b/cobbler/action_reposync.py index 53cf4a3..8c7e242 100644 --- a/cobbler/action_reposync.py +++ b/cobbler/action_reposync.py @@ -240,8 +240,7 @@ class RepoSync: """ Used to run createrepo on a copied mirror. """ - target_dir = os.path.dirname(dirname).split("/")[-1] - if target_dir.lower() in [ "i386", "x86_64", "ia64" ] or not repo.is_rsync_mirror(): + if os.path.exists(os.path.join(dirname,"RPMS")) or not repo.is_rsync_mirror(): utils.remove_yum_olddata(dirname) try: cmd = "createrepo %s %s" % (repo.createrepo_flags, dirname) -- cgit