Bug 40842 - Docker Apps register their WebInterfacePortHTTP for /ucs-overview
Docker Apps register their WebInterfacePortHTTP for /ucs-overview
Product: UCS
Classification: Unclassified
Component: App Center
UCS 4.1
Other Linux
: P2 normal (vote)
: UCS 4.1-2-errata
Assigned To: Dirk Wiesenthal
Eduard Mai
Depends on:
  Show dependency treegraph
Reported: 2016-03-04 11:47 CET by Dirk Wiesenthal
Modified: 2016-06-02 13:15 CEST (History)
1 user (show)

See Also:
What kind of report is it?: ---
What type of bug is this?: ---
Who will be affected by this bug?: ---
How will those affected feel about the bug?: ---
User Pain:
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:


Note You need to log in before you can comment on or make changes to this bug.
Description Dirk Wiesenthal univentionstaff 2016-03-04 11:47:07 CET
... which leads to problems as the port is not open on the host. Instead a WebInterfacePortHTTP=8080 is mapped to, say, 40001, and this port is used for mod_proxy. In fact, the correct port for an App with auto_mod_proxy=True (default) and port 8080 in the ini file is 80 (and 443).

Currently, the link generated is:

  https://IP:8080/jenkins/ instead of https://IP/jenkins/

UCSOverviewCategory=False and setting the ucs/web/overview/entries/service/jenkins/... in the joinscript (and unsetting in unjoin).
Comment 1 Dirk Wiesenthal univentionstaff 2016-04-19 13:55:51 CEST
The correct check is:
  if app.auto_mod_proxy:
somewhere in register.py #_register_overview_variables

This is always False for None-Docker Apps and True by default for Docker Apps (see app.py)
Comment 2 Dirk Wiesenthal univentionstaff 2016-04-19 14:00:00 CEST
This _should_ also be fixed in App.js. Instead of "if (this.isDocker && port)" in getWebInterfaceURL, one should use (this.autoModProxy && port) (which needs to be initialized in constructor similar to isDocker).

Currently, every Docker App also has AutoModProxy, so this is just a minor issue, but still buggy.
Comment 3 Dirk Wiesenthal univentionstaff 2016-05-13 09:54:12 CEST

  univention-app install jenkins=1.651.1
  vim /var/cache/univention-appcenter/jenkins_20160426.ini
    -> #UCSOverviewCategory=False
  univention-app register jenkins
  ucr get ucs/web/overview/service/jenkins/port_http

With and without errata update installed.
Comment 4 Dirk Wiesenthal univentionstaff 2016-05-30 23:18:14 CEST
If have added tests/80_docker/74_app_ports_webinterface in
  ucs-test 6.0.33-66.1482.201605302314

FYI: It is easier to test with jira. This App suffers from this bug without the need to edit the ini file.
Comment 5 Eduard Mai univentionstaff 2016-05-31 13:36:13 CEST
Reproduced the problem by installing Jira. Fix works as expected.

Changes: OK.
Yaml: OK.

Comment 6 Janek Walkenhorst univentionstaff 2016-06-02 13:15:46 CEST