Difference between revisions of "Integration with UCS/Web interface"

From Univention Wiki

Jump to: navigation, search
(Link to new documentation)
 
Line 1: Line 1:
[[Category:App Center Developer Guide]]
+
#REDIRECT [[App Center Developer Guide]]
 
 
A web interface can be specified in the ini file:
 
 
 
<pre>
 
WebInterface=/myapp
 
</pre>
 
 
 
This will add a link on the overview page https://FQDN/ucs-overview to https://FQDN/myapp. The same link will appear in the App Center module of the Univention Management Console.
 
 
 
;''Important'': The ini file parameters are shown here, but the [[Provider Portal/Apps|Provider Portal]] hides the actual files and presents a web form where you can upload images, set parameters and so on.
 
 
 
This link can be customized further:
 
 
 
<pre>
 
WebInterface=/myapp
 
WebInterfacePortHTTP=8080
 
WebInterfacePortHTTPS=0
 
</pre>
 
 
 
will add a link http://FQDN:8080/myapp. HTTPS links will not be created.
 
 
 
<pre>
 
UCSOverviewCategory=False
 
</pre>
 
 
 
will hide this link completely on https://FQDN/ucs-overview.
 
 
 
= Docker Apps =
 
 
 
For Docker Apps, the behaviour differs a bit:
 
 
 
<pre>
 
WebInterface=/myapp
 
WebInterfacePortHTTP=8080
 
WebInterfacePortHTTPS=8080
 
WebInterfaceProxyScheme=http
 
</pre>
 
 
 
will support http://FQDN/myapp and https://FQDN/myapp!
 
 
 
There is a mod_proxy integration in the App Center. It will route the Container's port 8080 to some port in the range of 40000 to 41000 on the Docker Host. This port is then used in the mod_proxy configuration on the Host to proxy /myapp on the Host to /myapp in the Container for the Host's ports 80 and 443. As WebInterfaceProxyScheme=http, even for 443 a HTTP connection is used between the Container and the Host.
 
 
 
;''Important'': The "entry point" then needs to be /myapp. You cannot use /, as this would try to proxy / to /. This cannot be configured further as all links your application generates need to take /myapp into account.
 
 
 
= Without help of the App Center =
 
 
 
If your App runs on /, you cannot use the web interface integration of the App Center:
 
 
 
<pre>
 
WebInterface=/
 
WebInterfacePortHTTP=8080
 
WebInterfacePortHTTPS=0
 
AutoModProxy=False
 
PortsExclusive=8080
 
</pre>
 
 
 
(See also [[Integration with UCS/Firewall]])
 
 
 
You can set a link on the overview in the [[Integration with UCS/Join|join script]]:
 
 
 
<pre>
 
P="ucs/web/overview/entries/service"
 
APP_PORT=8080
 
eval "$(ucr shell hostname domainname)"
 
ucr set \
 
"$P/$APP"/description/de="Description of link to $APP (German)" \
 
"$P/$APP"/description="Description of link to $APP (English)" \
 
"$P/$APP"/icon="/url/to/icon/$APP.png" \
 
"$P/$APP"/label/de="Headline of link to $APP (German)" \
 
"$P/$APP"/label="Headline of link to $APP (English)" \
 
"$P/$APP"/link="https://$hostname.$domainname:$APP_PORT/myapp"
 
</pre>
 
 
 
Do not forget to unset these variables in the unjoin script!
 

Latest revision as of 12:42, 15 October 2018

Personal tools