Changes

From SME Server
Jump to navigationJump to search
m
Line 88: Line 88:  
Accessing ehour on a TCP port (8000) may look not very professional. You may want to access ehour at a subdomain like 'timesheet.yourdomain.com'. Here's how:
 
Accessing ehour on a TCP port (8000) may look not very professional. You may want to access ehour at a subdomain like 'timesheet.yourdomain.com'. Here's how:
   −
WIP. TBA.
+
The preferred way to create a sub domain is to install the ''smeserver-webapps-common'' contrib from the '''[[Fws|FWS]]''' repository. Please see the '''[[webapps-common]]''' page on how to enable the FWS repo and install the contrib.
 +
 
 +
After installation we need to provide the details of the virtual host to the contrib so it can create the virtual host. In this example we want the virtualhost to serve the sub domain ''https://timesheet.myserver.com'' and only provide access to the login page to valid SME users. This can be done with the following command:
 +
 
 +
db domains set timesheet.collabis.nl domain Description "Timesheet" Content Primary \
 +
Nameservers internet TemplatePath WebAppVirtualHost DocumentRoot /opt/ehour \
 +
RequireSSL enabled ProxyPassTarget http://127.0.0.1:8000/ Authentication Basic
 +
 
 +
 
 +
Followed by:
 +
signal-event webapps-update
 +
Your sub domain has been created but will not yet show eHour. We need to tell the eHour Jetty webserver that it needs to listen to 127.0.0.1. Since the eHour Jetty webserver is not part of SME Server, we need to adjust the jetty config file located at '''/opt/ehour/home/conf/jetty.xml''' to look like this:
 +
<nowiki>
 +
        <Call name="addConnector"> <Arg> <New class="org.eclipse.jetty.server.nio.SelectChannelConnector">                        <Set name="Host">127.0.0.1</Set> </New> </Arg> </Call>
 +
</nowiki>Where only '''<Set name="Host">127.0.0.1</Set>''' is added.
 +
Then eHour needs to be restarted by:service ehour restartAnd give it a minute to restart. Then eHour will be available from https://timesheet.myserver.com.
 +
Once the sub domain is working, you may want to close off the original webaddress myserver.com:8000 by setting the access property to private: config setprop ehour access private
 +
followed by:
 +
signal-event remoteaccess-update
    
==Upgrade==
 
==Upgrade==

Navigation menu