Bug 44994 - provide static UCR binary
provide static UCR binary
Status: RESOLVED WONTFIX
Product: UCS
Classification: Unclassified
Component: UCR
UCS 4.2
Other Linux
: P5 normal (vote)
: ---
Assigned To: UCS maintainers
UCS maintainers
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2017-07-13 08:26 CEST by Daniel Tröder
Modified: 2020-07-03 20:54 CEST (History)
2 users (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?: 3: Will affect average number of installed domains
How will those affected feel about the bug?: 1: Nuisance – not a big deal but noticeable
User Pain: 0.034
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

Note You need to log in before you can comment on or make changes to this bug.
Description Daniel Tröder univentionstaff 2017-07-13 08:26:10 CEST
A static UCR binary could be copied into a non-UCS docker image, and be used to configure it. No Python installation should be required.
Comment 1 Daniel Tröder univentionstaff 2017-07-13 08:40:38 CEST
I created a working UCR binary using the Apache licensed nuitka project (http://www.nuitka.net/):

I ran this in a UCS 4.2:

# wget http://nuitka.net/releases/nuitka_0.5.26.4+ds-1_all.deb
# dpkg -i nuitka_0.5.26.4+ds-1_all.deb
# apt-get install -f

# nuitka --standalone --recurse-directory /etc/univention/templates/modules --show-progress --show-memory --show-modules /usr/sbin/ucr

This will create a directory ucr.dist which contains the executable ucr.exe (the .exe can be removed from the name) and all needed Python and C library files.

ucr.dist  : 46 MB
ucr.tar.bz: 15 MB

I created a tarball, copied and extracted it in a Gentoo system and could run the binary without problems. Try for yourself:

https://billy.knut.univention.de/~dtroeder/ucr.tar.bz

The ucr modules that were in /etc/univention/templates/modules at that time are inside ucr.exe. That does probably make no sense, as they were meant for the system it was compiled in. I don't know if new ucr modules can just be put into the target systems /etc/univention/templates/modules and will be loaded, but I guess it will work. So... the "--recurse-directory /etc/univention/templates/modules" should be removed from the command above.
Comment 2 Ingo Steuwer univentionstaff 2020-07-03 20:54:51 CEST
This issue has been filed against UCS 4.2.

UCS 4.2 is out of maintenance and many UCS components have changed in later releases. Thus, this issue is now being closed.

If this issue still occurs in newer UCS versions, please use "Clone this bug" or reopen it and update the UCS version. In this case please provide detailed information on how this issue is affecting you.