logo
20.2
search
No matching documents found.
list
search
No matching documents found.
logo
Please be aware that there is newer version of documentation available for Webswing. Documentation 24.2

Starting on Linux

Startup properties

You can define the following properties in webswing.properties file:

Property Description Default value
webswing.connection.secret Secret string for securing user sessions and websocket connections used by Webswing server. Should be a 128 characters long string. If you are using admin console, use the same secret in webswing-admin.properties.
webswing.logsDir Directory where Webswing server log files should be stored. logs/
webswing.server.websocketUrl Provide this property only if you are going to deploy webswing-server.war on your own server, without using embedded Jetty. This property should contain the websocket URL of this Webswing server, e.g. ws://localhost:8080.

SSL configuration

You can configure the SSL with embedded jetty (described below) or with Reverse Proxy.

There is a special configuration file for the built-in jetty called jetty.properties. It is used to configure connection options of the server like ports, protocols, SSL certificates and CORS origins (for embedded Webswing). Command-line options have higher priority than this file. Location of this file can be specified by option -j. You can configure following options in this file:

org.webswing.server.host=localhost

org.webswing.server.http=true
org.webswing.server.http.port=8080

org.webswing.server.https=true
org.webswing.server.https.port=8443
org.webswing.server.https.truststore=ssl/truststore.jks
org.webswing.server.https.truststore.password=OBF:18xp18xr18xt18xp18xr18xt
org.webswing.server.https.keystore=ssl/keystore.jks
org.webswing.server.https.keystore.password=OBF:18xp18xr18xt18xp18xr18xt

Tomcat Deployment

Even though Webswing comes with an embedded Jetty server, it is still possible to deploy it to an external servlet container like Tomcat. Other J2EE servers should work as well, as far as they support Servlet 3.0 spec and JSR-356 Websocket spec (but only Tomcat 8 is tested). Previous experience with Tomcat configuration is expected.

To deploy Webswing to Tomcat, follow the following steps:

IBM WAS 9.0 Deployment

To deploy Webswing to WAS 9.0, follow these steps:

  1. Unzip Webswing distribution to a temporary folder
  2. In webswing.properties set property webswing.server.websocketUrl to ws://localhost:<port>, port should be the same as application server port
  3. Go to IBM WAS Console http://localhost:9060/ibm/console
  4. Navigate in the menu to Applications>New Application>New Enterprise Application
  5. Click Choose File (select webswing-server.war from the temporary folder created before)
  6. Next>Next>Next>Next>Next
  7. Configure Webswing JVM Properties in location: Servers>Server Types>WebSphere application servers>server1>Server Infrastructure, Java and Process Management, Process Definition>Java Virtual Machine>Custom Properties similarly to following:
webswing.warLocation=webapps/webswing-server.war
webswing.configFile=webswing/webswing.config
webswing.tempDirBase=webswing/tmp
webswing.rootDir=webswing

Properties 01 Properties 02

Please note that the locations in demo webswing.config are pointing to relative paths, so in order to make the demo applications run in WAS you will need to change the paths accordingly.

In case of issues analyze the logfiles.