Bug 48151 - Check if univention-debmirror is already installed in univention-repository-create
Check if univention-debmirror is already installed in univention-repository-c...
Status: CLOSED FIXED
Product: UCS
Classification: Unclassified
Component: Update - Repository administration
UCS 4.3
Other Linux
: P5 normal (vote)
: UCS 4.4
Assigned To: Philipp Hahn
Stefan Gohmann
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2018-11-15 10:26 CET by Valentin Heidelberger
Modified: 2019-03-12 13:41 CET (History)
1 user (show)

See Also:
What kind of report is it?: Bug Report
What type of bug is this?: 2: Improvement: Would be a product improvement
Who will be affected by this bug?: 1: Will affect a very few installed domains
How will those affected feel about the bug?: 2: A Pain – users won’t like this once they notice it
User Pain: 0.023
Enterprise Customer affected?:
School Customer affected?:
ISV affected?:
Waiting Support:
Flags outvoted (downgraded) after PO Review:
Ticket number:
Bug group (optional):
Max CVSS v3 score:


Attachments
Patch for univention-repository-create to check if univention-debmirror is installed before trying to install it (1.27 KB, patch)
2018-11-15 10:26 CET, Valentin Heidelberger
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Valentin Heidelberger univentionstaff 2018-11-15 10:26:12 CET
Created attachment 9744 [details]
Patch for univention-repository-create to check if univention-debmirror is installed before trying to install it

univention-repository-create tries to install univention-debmirror every time it's executed. It's only after that, that it checks whether univention-debmirror is installed. This could create the following problem:

- User has for some reason broken the local repo (deleted something accidentally) and wants to recreate it
- univention-repository-create tries to install univention-debmirror from the local repo and fails
- User would have to switch back to the offical repo to run univention-repository-create successfully

Therefore I think univention-repository-create should check whether univention-debmirror is installed before trying to install it. That would also prevent some unnecessary output and save some time.

Attached is a patch that uses is_debmirror_installed() to do this.
Comment 1 Philipp Hahn univentionstaff 2019-03-10 19:35:55 CET
[4.4-0] 7a3e70fdb9 Bug #48151 up: Check if univention-debmirror is installed
 base/univention-updater/debian/changelog                    | 1 +
 base/univention-updater/python/univention-repository-create | 9 ++++-----
 2 files changed, 5 insertions(+), 5 deletions(-)

Package: univention-updater
Version: 14.0.0-16A~4.4.0.201903101858
Branch: ucs_4.4-0
Comment 2 Stefan Gohmann univentionstaff 2019-03-11 08:21:56 CET
Tests: OK (it still aborts if it can't be installed)

Code review: OK

Changelog: OK
Comment 3 Florian Best univentionstaff 2019-03-12 13:41:13 CET
UCS 4.4 has been released:
 https://docs.software-univention.de/release-notes-4.4-0-en.html
 https://docs.software-univention.de/release-notes-4.4-0-de.html

If this error occurs again, please use "Clone This Bug".