Integration with UCS/Settings
From Univention Wiki
Apps may be configured from within the App Center module. These settings are closely related to Univention Configuration Registry (UCR).
In UCS, UCR holds system wide information that can be accessed by scripts and used to write configuration files. See the Developer Reference for more details.
Apps may ship a .univention-config-registry-Variables file that contains a superset of what can be specified in UCS.
[myapp/verbose] Description[de]=Alles in Log-Dateien schreiben Description[en]=Write everything in log files Type=bool Advanced=yes Categories=apps [myapp/rights/type] Description[de]=Rechtevergabe Description[en]=Access control Type=list Labels[de]="Alle lesen, eigene schreiben" "Alle lesen, alle schreiben" Labels[en]="Read all, write own" "Read all, write all" Values=owner_write authenticated Default=owner_write Categories=apps
The following attributes may be set: TBD
Inside the container, you may use ucr get variable to get the value. Variables that were set during installation are accessible as environment variables, too ([myapp/variable] becomes MYAPP_VARIABLE). Note that these were set during container creation. The environment variables will not change, even after the user changes the UCR variable.
- For the full functionality of UCR (e.g., UCR templates), you would need a UCS based image. If the App Center detects UCR is present (which ucr), it will use it to set the variables (docker exec $appcontainer ucr set variable1=value1 variable2=value2). If this program is not found, the variables still get written in /etc/univention/base.conf. You may parse this file if UCR is not available. The format is rather simple: Each line contains variable: value.