Difference: AppxHTMLClient545 (9 vs. 10)

Revision 102016-11-02 - JeanNeron

Line: 1 to 1
 
META TOPICPARENT name="APPX545Installation"

APPX HTML Client 5.4.5

This page gives installation instructions and an overview of the Appx HTML client.

Changed:
<
<

>
>

 

Overview

The Appx HTML client is designed to allow you to connect to an Appx server and run Appx applications using a browser, either on the desktop, a tablet or a smartphone. When running the client in a browser, no software is required on the desktop, tablet or smart phone. When the user logs on, the necessary code is downloaded to their device as required.

Line: 37 to 37
  The Local Connector only runs on Windows, OS/X or Linux based desktops or tablets.
Changed:
<
<
There is a 'Connectivity' indicator in the lower right corner of the browser window with the words 'Remote' and 'Local'. If 'Local' is in green with a "+", it means the local connector is installed & running. Red means the connector is not installed. You can click the 'Local' sign to manually download and install the connector. If the 'Local' icon is blue, it means the requirement for a local connector has been turned off via <meta name="appx-local-required" content="false"> in the client.html page (see below).
>
>
There is a 'Connectivity' indicator in the lower right corner of the browser window with the words 'Remote' and 'Local'. If 'Local' is in green with a "+", it means the local connector is installed & running. Red means the connector is not installed. You can click the 'Local' sign to manually download and install the connector. If the 'Local' icon is blue, it means the requirement for a local connector has been turned off via metas["appx-local-required"]["value"] = "false"; in the your 'appx-client-settings.js file (see below).
 

Web Browser

The other option is to use the Web Browser's built in ability to handle files. With this option, the APPX Server Connector stores the file in the Mongo database, then passes a URL to the Web Browser. The Web Browser will either display the file in a new tab if it knows how process that file type, or offer to save the file if it does not know how to display it. This is a better choice if you are planning to deploy your applications on non Windows tablets or smartphones.

Line: 63 to 63
  1) Extract the Web Server File (webhost.zip) into the document folder for your web server. Depending on your web site layout, you may want to put this in its own folder within the web server documents, i.e., /var/www/html/appx.
Changed:
<
<
2) Set the name of the host running the Appx Server Connector in the 'client.html' web page:
>
>
2) If this is a new installation, you must rename the appx-client-settingsTemplate.js file to appx-client-settings.js. This file is in the 'js' subdirectory. For example:
 
Changed:
<
<
<meta name="appx-proxy-host" content="HOSTNAME"> <!-- Server Connector hostname or web server if tunneling -->
>
>
[root@localhost]# cd js
[root@localhost js]# mv appx-client-settingsTemplate.js appx-client-settings.js
 
Changed:
<
<
Change HOSTNAME to the name or IP address of the server running the Appx Server Connector. Do not use localhost unless you plan to run the HTML client on the same server as the Appx Server Connector, i.e., a testing/evaluation environment.
>
>
3) If this is a new installation you must set the name of the host running the Appx Server Connector in the 'appx-client-settings.js' file you just renamed:
 
Added:
>
>
metas["appx-proxy-host"]["value"] = "localhost";

Change locahost to the name or IP address of the server running the Appx Server Connector. Do not use localhost unless you plan to run the HTML client on the same server as the Appx Server Connector, i.e., a testing/evaluation environment.

You can also set any other meta tags that are unique to your installation. The 'appx-client-settings.js' file will never be replaced during an update, so the settings will remain until you change them.

 

Installation - APPX Server Connector Component

The APPX Server Connector is the software that connects the HTML clients and the APPX server. This can be installed on the same server as the web server, or the APPX Server, or a completely different machine. If you are not using tunnneling via the web server, then ports 3014/3015 (the default port) needs to be open between the server connector machine and your HTML clients.

Prerequisites

The server that will run the APPX Server Connector requires some additional software:

Changed:
<
<
>
>
  • The 'nodejs' package (https://nodejs.org/).

    For rpm based Linux systems, you can install it via (as root):
    curl --silent --location https://rpm.nodesource.com/setup | bash -yum install nodejs

    To install on Windows, go to https://nodejs.org and download the Windows installer (msi) file and simply run the installer.

 
Line: 94 to 103
 
[root@localhost ~]# cd /opt/appxConnector
[root@localhost appxConnector]# node appxConnector-install.js
Checking for required modules...
Module: crypto - Installed.
Module: fs - Installed.
Module: hexy - Installed.
Module: http - Installed.
Module: https - Installed.
Module: mongodb - Installed.
Module: net - Installed.
Module: node-cryptojs-aes - Installed.
Module: string - Missing, please run 'npm install string' to install.
Module: string_decoder - Installed.
Module: url - Installed.
Module: ws - Installed.

Missing modules. Please install required modules and run again.

Notice in this example the module 'string' is missing and the instructions on how to install it are displayed. If any modules are missing on your system, run the appropriate 'npm' command to install them, then re-run the install script. If all modules are present, the service will be created:

Changed:
<
<
[root@localhost appxConnector]# node appxConnector-install.js  
Checking for required modules...
Module: crypto - Installed.
Module: fs - Installed.
Module: hexy - Installed.
Module: http - Installed.
Module: https - Installed.
Module: mongodb - Installed.
Module: net - Installed.
Module: node-cryptojs-aes - Installed.
Module: string - Installed.
Module: string_decoder - Installed.
Module: url - Installed.
Module: ws - Installed.

Installing appxconnector service...
Using default mode: systemd Installing service on /etc/systemd/system/appxconnector.service
Already installed, restarting appxconnector service...
Running systemctl start appxconnector...
Done
>
>
[root@localhost appxConnector545]# node appxConnector-install.js
Checking for required modules...
No arguments received, using default settings for install Module: crypto - Installed.
Module: fs - Installed.
Module: hexy - Installed.
Module: http - Installed.
Module: https - Installed.
Module: mime - Installed.
Module: mongodb - Installed.
Module: net - Installed.
Module: node-cryptojs-aes - Installed.
Module: string - Installed.
Module: string_decoder - Installed.
Module: url - Installed.
Module: ws - Installed.

Using default mode: systemd
Installing service on /etc/systemd/system/appxconnector.service
Running systemctl daemon-reload...
Installing appxConnector3014 service...
Done... Waiting on service to start...
Running systemctl start appxconnector...
Service appxConnector3014 started
Using default mode: systemd
Installing service on /etc/systemd/system/appxmongoconnector.service
Running systemctl daemon-reload...
Installing appxMongoConnector3015 service...
Done... Waiting on service to start...
Running systemctl start appxmongoconnector...
Service appxMongoConnector3015 started
  4) Confirm the service is running. In Linux/Unix you can use 'ps -ef|grep appx', and in Windows you can use the 'Services' control panel.

Assuming the web server to which we installed the client is 192.168.0.15, and that we installed everything into an 'appx' folder on the web server, then we should be able to get a client login dialog box via:

Changed:
<
<
http://192.168.0.15/appx/client.html
>
>
http://192.168.0.15/appx/client.html
  You must open ports 3014/3015 on the server running the APPX Server Connector for this connection to work. If you do not want to open any new ports on your firewall, see the section on 'Tunneling/Forwarding'.

Post Installation if upgrading an existing HTML client installation

Line: 114 to 124
  There are various reasons why you would want to do this:
  • You have development, model and production installations of APPX all on the same server. In this case, you would install a matching server connector in 3 different folders and configure each one to use a different set of ports. When a new release is available, you could install it in the test folder without affecting the model or production versions.
Changed:
<
<
  • Load balancing. You could configure multiple ports and have different users connect on different ports by setting up different client.html files. For example, all users in a certain department use a client.html file that uses ports 3014/3015, another department might use use a client.html file that uses 3020/3021, etc.
>
>
  • Load balancing. You could install multiple connectors as above and configure multiple ports and have different users connect on different ports by setting up different appx-client-settings.js files. For example, all users in a certain department use a settings file that uses ports 3014/3015, another department might use use a settings file that uses 3020/3021, etc.
  By default the installer will install a server connector on port 3014 and a mongo connector on port 3015. The installer accepts the following arguments:
Added:
>
>
 node appxConnector-install [appx | mongo] [appxport] [mongoport]

Examples:

Line: 130 to 144
  Installs a server connector on 3020 and a mongo connector on 3030.
Changed:
<
<
You can then create different client.html pages using the different ports via setting "appx-proxy-port" and "appx-mongo-port" in each client.html page. If you are using port forwarding, then you'll have to create unique names and use those names in client.html instead (they all would use port 80).
>
>
You can then create different folders to contain the client.html pages using the different ports via setting "appx-proxy-port" and "appx-mongo-port" in each appx-client-settings.js file in each folder. If you are using port forwarding, then you'll have to create unique names and use those names instead (they all would use port 80).
 

Local Connector or Web Browser Configuration

As mentioned above, you have a choice on how the HTML client should handle files sent to/from the browser.

Changed:
<
<
By default, the HTML client will try to use the local connector. You can suppress the requirement for the Local Connector by changing the following line in "client.html":
>
>
By default, the HTML client will try to use the local connector. You can suppress the requirement for the Local Connector by uncommenting the following line in your appx-client-settings.js file:
 
Changed:
<
<
<meta name="appx-local-required" content="true" >
>
>
//metas["appx-local-required"]["value"] = "false";
 
Changed:
<
<
Change the "true" to "false" to supress the requirement.
>
>
Remove the leading // to uncomment the line.
  If you do not turn off the Local Connector requirement as above, then when the 'client.html' page is loaded it will check to see if the local connector is running on the users desktop. If not, they will get a dialog box offering to download the local connector. The actual installation of the local connector varies by the O/S on the user's desktop:
  • Windows: Once the download is complete, run the installer. The local connector will be installed, started and Windows will be configured to automatically start on a reboot. No further action is required.
Line: 151 to 165
 
      • cd $HOME/AppxLocalConnector
      • sh ./start-nw.sh
    • The user has to manually start the local connector every time they log in, or they can add the script to their programs that start automatically when they log in. The steps vary by Linux distribution, consult your documentation.
Changed:
<
<
If you are going to use the Web Browser to handle files instead of the local connector, then turn off the requirement for a Local Connector as above, and change the following line in "client.html":
>
>
If you are going to use the Web Browser to handle files instead of the local connector, then turn off the requirement for a Local Connector as above, and uncomment the following line in your appx-client-settings.js file:
 
Changed:
<
<
<meta name="appx-upload-without-local" content="false" >
>
>
//metas["appx-upload-without-local"]["value"] = "true";
 
Changed:
<
<
Change the "false" to "true" to force the HTML client to use the Web Browser to handle files. The '+Local' connector icon will be blue in this case.
>
>
Remove the leading // to uncomment the line. The '+Local' connector icon will be blue in this case.
  The Application Designer can also control this. Each file chooser widget can be individually set to not use the local connector by using the macro: @FULC=F, however setting "appx-upload-without-local" = true will override this, even if the macro specifies the local connector should be used (@FULC=T).

Tunneling/Forwarding

Line: 163 to 177
 If you do not want to open ports 3014/3015 and would rather use port 80, you can use forwarding instead. For example, to configure Apache 2.4 on Linux you would do the following:
  • In /etc/httpd/conf.modules.d/00-proxy.conf, add (if not already loaded):

    LoadModule proxy_wstunnel_module modules/mod_proxy_wstunnel.so

  • Create the /etc/httpd/conf.d/appx.conf file with the following lines (or just add these to httpd.conf):

    ProxyPass "/appxwss" "wss://localhost:3014"
    ProxyPassReverse "/appxwss" "wss://localhost:3014"
    ProxyPass "/appxws" "ws://localhost:3014"
    ProxyPassReverse "/appxws" "ws://localhost:3014"

    ProxyPass "/appxhttps" "https://localhost:3015"
    ProxyPassReverse "/appxhttps" "https://localhost:3015"
    ProxyPass "/appxhttp" "http://localhost:3015"
    ProxyPassReverse "/appxhttp" "http://localhost:3015"
Changed:
<
<
  • Change 'client.html' settings to:

    appx-proxy-host = hostname of httpd server (i.e., 192.168.1.11)
    appx-proxy-port = “80"
    appx-mongo-port = “80"
    appx-proxy-path = /appxws/

>
>
  • Change the following in your appx-client-settings.js file:

    appx-proxy-host = hostname of httpd server (i.e., 192.168.1.11)
    appx-proxy-port = “80"
    appx-mongo-port = “80"
    appx-proxy-path = /appxws/

 
  • Restart your web server

NOTE: If you are running selinux security on your server, you will have to configure it so that apache can initiate an outgoing network connections to the web socket server port. Use the following command:
Line: 172 to 186
  If you are running a secure web server (https), you can configure the Appx HTML client to use your SSL connection. Your web server must be configured to accept both SSL (https:) and non-SSL (http:) connections.
Changed:
<
<
Change your "client.html" settings as follows (this file is located on your web server):
>
>
Change the following in your appx-client-settings.js file:
  appx-proxy-host = hostname of httpd server (i.e., 192.168.1.11)
appx-proxy-port = “443"
appx-proxy-path = /appxwss/
appx-encryption = “ssl”
Line: 213 to 227
 It is possible to have different CUSTOM.css style sheets. Install the client web server files as normal, then follow these steps:

  • create sub folders for each of the different style sheets you want to use.
Changed:
<
<
  • Edit the client.html file, changing 'appx-client-root' to point to the parent folder, i.e.:
    • <meta name="appx-client-root" content="..">
  • Copy the client.html file to each subfolder.
>
>
  • Edit your appx-client-settings.js file, changing 'appx-client-root' to point to the parent folder, i.e.:
    • metas["appx-client-root"]["value"] = "../";
  • Copy the appx-client-settings.js file to each js folde.
 
  • Create a 'css' folder in each subfolder, and put each unique CUSTOM.css file in that folder

Troubleshooting

  • If you have created your own login page based on 'client.html', make sure you update it with any changes to the standard 'client.html' when upgrading the HTML client.
  • If the client login dialog box does not display, check your web server error logs for any error messages & correct as required.
  • If you are getting "[proxy:error] [pid xxxx] (13)Permission denied:" errors, you might have a selinux security issue that prevents apache from initiating any outgoing network connections to the web socket server port. In that case, try the following command:
    # setsebool -P httpd_can_network_connect 1
Changed:
<
<
  • Some browsers (like IE) will not run the client successfully if you double click the 'client.html' file. You should always access the web page via http://servername/client.html, even if the page is installed on your local system.
>
>
  • Some browsers (like IE) will not run the client successfully if you double click the 'client.html' file. You should always access the web page via http://servername/client.html, even if the page is installed on your local system.
 
  • Check to make sure your Appx Server Connector is still running. If not, restart it.
Changed:
<
<
  • If you can't display table data inside a browser and you are running Windows Server 2008R2, you might try installing this HOTFIX from Microsoft. Windows 2008R2 servers without that HOTFIX will sometimes zero-out the MongoDB data. https://support.microsoft.com/en-us/kb/2731284
>
>
  • If you can't display table data inside a browser and you are running Windows Server 2008R2, you might try installing this HOTFIX from Microsoft. Windows 2008R2 servers without that HOTFIX will sometimes zero-out the MongoDB data. https://support.microsoft.com/en-us/kb/2731284
 
  • If you're having trouble with Remote connections, this page has some tips
  • If the client seems to hang while loading images or tables, that its a very good indicator that MongoDB server has stopped. If MongoDB server needs to be started or restarted then make sure you restart the appxConnector service after MongoDB is running.
Line: 232 to 246
 Read what other users have said about this page or add your own comments.
Changed:
<
<

<--/commentPlugin-->
>
>

<--/commentPlugin-->
  -- JeanNeron - 2015-12-18 \ No newline at end of file
 
This site is powered by the TWiki collaboration platform Powered by PerlCopyright © 2008-2024 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback