Univention Bugzilla – Bug 40827
Additional App data for App Appliances
Last modified: 2016-03-09 15:52:17 CET
A ISV will have the possibilty to specify Modules that should be displayed in the Appliance category tab in the umc. For that we need to add an additional property to the app object created from the ini file that contains a list with the wanted modules.
r 67855 univention-appcenter (5.0.20-11): * Bug #40827: added attribute to created app object from ini file
FYI - how to use: ApplianceCategoryModules expects a comma separated list of modules. to display a flavor use --> module:flavor[/flavor] e.g. udm:users/user or appcenter:packages to display a module wihtout a flavor just use the module name e.g. diagnostic A complete example can look like this: ApplianceCategoryModules=udm:users/user, appcenter:packages, diagnostic
r 67868 univention-appcenter (5.0.20-12): * Bug #40827: added primary and secondary color to created app object from ini file YAML: added r 67869
r 67878 univention-appcenter (5.0.20-14): * Bug #40827: added css background property for appliances YAML: r 67879
Could you please add the following properties, as well: ApplianceBootsplashLogo ApplianceUmcHeaderLogo ApplianceWelcomeScreenLogo
(In reply to Alexander Kläser from comment #5) > Could you please add the following properties, as well: > > ApplianceBootsplashLogo > ApplianceUmcHeaderLogo > ApplianceWelcomeScreenLogo Added properties r 67911 univention-appcenter (5.0.20-15): * Bug #40827: added bootSplashLogo UmcHeaderLogo and WelcineScreenLogo properties for app appliances
YAML: r 67912
r 67922 univention-appcenter (5.0.20-16): * Bug #40827: removed the properties for app appliances in univention-appcenter. App appliance specific properties are moved to app-appliance-branding package YAML: r 67923
Changes: OK, this works really nice. For the appliances, the code can now be written as follows :-) ... ---------- 8< ---------- import univention.appcenter.app as app class App(app.App): appliance_category_modules = app.AppListAttribute() appliance_primary_color = app.AppAttribute() appliance_secondary_color = app.AppAttribute() appliance_css_background = app.AppAttribute() appliance_bootsplash_logo = app.AppAttribute() appliance_umc_header_logo = app.AppAttribute() appliance_welcome_screen_logo = app.AppAttribute() appliance_logo = app.AppAttribute() class AppManager(app.AppManager): _AppClass = App ---------- 8< ---------- YAML file: FAIL, please adjust the YAML file accordingly → REOPEN
Created attachment 7520 [details] Patch for pickle files Please keep in mind that the AppManager caches the python objects for performance reasons. You need to use a different pickle_file. Or none at all. class AppManager(app.AppManager): _pickle_file = None _cache = [] otherwise you may end up loading Apps without appliance_* attributes. You also need to use a different cache object. Just in case you mix old AppManager and new AppManager.
(In reply to Dirk Wiesenthal from comment #10) > Created attachment 7520 [details] > Patch for pickle files r 67987 univention-appcenter (5.0.20-20): * Bug #40827: Support the use of no pickle file for app appliances > Please keep in mind that the AppManager caches the python objects for > performance reasons. > > You need to use a different pickle_file. Or none at all. > > class AppManager(app.AppManager): > _pickle_file = None > _cache = [] > > otherwise you may end up loading Apps without appliance_* attributes. You > also need to use a different cache object. Just in case you mix old > AppManager and new AppManager. r 67986 univention-app-appliance-branding (0.2.2-8): * Bug #39465: always load new ini file. ignore possible caches from appcenter YAML: r 67988
Changes: OK, the changes work as expected. YAML: OK, as discussed, I adapted the description (r67991). → VERIFIED
<http://errata.software-univention.de/ucs/4.1/127.html>