--- ./base/univention-updater/python/univention-repository-create.orig 2018-11-14 15:56:59.446220332 +0100 +++ ./base/univention-updater/python/univention-repository-create 2018-11-15 10:23:24.174253283 +0100 @@ -66,18 +66,23 @@ print >> sys.stderr, 'Aborted.' sys.exit(1) - # install univention-debmirror - print 'Installing univention-debmirror' - ret = subprocess.call(['univention-install', '--yes', 'univention-debmirror']) - if ret != 0: - print >> sys.stderr, 'Error: Failed to install univention-debmirror' - sys.exit(1) - + # check whether univention-debmirror is installed and install it if needed ret, msg = urepo.is_debmirror_installed() if not ret: print >> sys.stderr, msg sys.exit(1) + if ret != True: + print 'Installing univention-debmirror' + ret = subprocess.call(['univention-install', '--yes', 'univention-debmirror']) + if ret != 0: + print >> sys.stderr, 'Error: Failed to install univention-debmirror' + sys.exit(1) + ret, msg = urepo.is_debmirror_installed() + if not ret: + print >> sys.stderr, msg + sys.exit(1) + def prepare(options): """ Set local/repository and create directory structure """