Installation
Client
Deploy the xpharma-client web application on your web server. The server-config.json file contains the configurations required for this application to communicate with the XPharma server:
contextPath
proto
httporhttpshost (server domain name)
port
Server
The XPharma server can be deployed as either a Tomcat application or a standalone Java application. The following steps are required to set it up and get it running.
Database set up
Execute the SQL script create_db.sql to create the database. You can update the script beforehand to set the appropriate database name, username and password.
Server configurations
Server configuration must be updated. This is to properly set the required environment variables.
If you want to deploy the server as a Tomcat application, the configurations should be defined in the file setenv.bat or setenv.sh of Tomcat, depending on your operating system. Please follow this link to read more about this file. An exemple is provided in the folder xpharma-web, containing all the environment variables to be set.
If you want to deploy the server as a standalone application, you can define the configurations directly in the start script, xpharma-server-start.bat (or xpharma-server-start.sh, depending on your operating system). As with the web (Tomcat) version of the server, these configurations are simple environment variables required for the application to work properly.
Running the server
If you choose to deploy the XPharma server as a Tomcat application, simply deploy the file xpharma-api-0.0.1.war to your Tomcat instance. Rename the WAR file as required to create a context path that suits your needs (for example, rename it to xpharma-api).
If you choose to deploy the XPharma server as a standalone Java application, run the relevant script (xpharma-server-start.bat for Windows or xpharma-server-start.sh for Linux-like operating systems) to start the server.
We hope you enjoy your freshly installed application.
Have fun!
Last updated