|
|
This section deals with editing the configuration of the installed instance of Squore. For more information about how to edit analysis models and wizards, refer to the Squore Configuration Guide.
The initial contents of <SQUORE_HOME>/config.xml
are as follows:
<?xml version="1.0" encoding="utf-8" standalone="yes"?> <squore type="server" version="1.3"> <paths> <path name="perl.dir" path="C:\Squoring\squore-server\tools\perl\perl"/> <path name="tclsh.dir" path="C:\Squoring\squore-server\tools\tclsh"/> </paths> <database> <postgresql directory="C:\Squoring\squore-server\tools\pgsql"/> <cluster directory="C:\Squoring\squore-data\cluster"/> <backup directory="C:\Squoring\squore-data\backup"/> <security> <user-name>postgres</user-name> </security> </database> <phantomjs> <socket-binding port="3003"/> </phantomjs> <configuration> <path directory="C:\Squoring\squore-server\configuration"/> </configuration> <addons> <path directory="C:\Squoring\squore-server\addons"/> </addons> <tmp directory="C:\Squoring\squore-data\temp"/> <projects directory="C:\Squoring\squore-data\projects"/> <workspace directory="C:\Squoring\squore-data\workspace"/> </squore>
You can find the XML schema for <SQUORE_HOME>/config.xml
in config-1.3.xsd.
Here is a description of each element:
paths/path name="perl.dir" (mandatory) is the path to the perl installation used by Squore. It is detected automatically on Linux and set to <SQUORE_HOME>/tools/perl/perl on Windows.
paths/path name="tclsh.dir" (mandatory) is the path to the tcl installation used by Squore. It is detected automatically on Linux and set to <SQUORE_HOME>/tools/tclsh on Windows.
database/postgresql directory="..." (for installations using PostgreSQL only) is the path to the PostgreSQL installation used by Squore It is detected automatically on Linux (or passed as a parameter to ./install) and set to <SQUORE_HOME>/tools/pgsql on Windows.
database/cluster directory="..." (for installations using a local PostgreSQL cluster only) is the path to the PostgreSQL cluster defined at installation to hold the Squore Database.
database/backup directory="..." (mandatory) is the path to the folder used by Squore by default to store backups. It can be overridden by passing a path to the backup script.
phantomjs (optional) allows you to specify the port used by Squore Server to communicate with the local instance of PhantomJS.
configurations/path directory="..." (mandatory): Paths to one or more configuration folders. The first path listed in the list takes precedence over the next one.
addons/path directory="..." (mandatory): Paths to one or more addons folders. The first path listed in the list takes precedence over the next one.
tmp directory="..." (mandatory) is the path to the temporary folder used to hold temporary analysis and user session data created while the server is running (this folder is emptied at startup).
projects directory="..." (mandatory) is the path to the project folder that holds analysis results. Files in this folder are included in a backup, along with the contents of the database.
workspace directory="..." (new in 18.0) (mandatory) is the path to the folder where any configuration changes carried out in the user interface are saved (for example charts and dashboards modified in the Dashboard Editor).
In order to add a custom addons or configuration folder, simply add a path
element in the configuration file:
<?xml version="1.0" encoding="utf-8" standalone="yes"?> <squore type="server" version="1.3"> <paths> ... </paths> <database> ... </database> <configuration> <path directory="C:\MyModels\configuration"/> <path directory="C:\Squoring\squore-server\configuration"/> </configuration> <addons> <path directory="C:\MyModels\addons"/> <path directory="C:\Squoring\squore-server\addons"/> </addons> <tmp directory="C:\Squoring\squore-data\temp"/> <projects directory="C:\Squoring\squore-data\projects"/> <workspace directory="C:\Squoring\squore-data\workspace"/> </squore>
By adding your own custom configuration and addons folder on top of the standard configuration, you ensure that the modifications you make override the definitions from the standard configuration and are not overwritten when upgrading your Squore version.
The workspace folder (which contains modifications to the configuration made via the web interface) always takes precedence over the configuration folders when loading the configuration.
Inside of Squore's tmp folder is a folder called sources which is used to store source code that users are viewing in the web interface, and to store source code uploaded in zip files for analyses.
The tmp folder is deleted whenever Squore Server is restarted, causing the sources
folder to be deleted in the process. If you need to keep the files created in the sources folder, you can move it
outside the temp folder by editing your <SQUORE_HOME>/config.xml
as follows:
<?xml version="1.0" encoding="utf-8" standalone="yes"?> <squore type="server" version="1.3"> <paths> ... </paths> <database> ... </database> <configuration> ... </configuration> <addons> ... </addons> ... <tmp directory="..."/> <project directory="..."/> <sources directory="..."/> <workspace directory="..."/> </squore>
By adding a sources
element, you can specify a directory
where source files are stored.
When several users run analyses using the command line on the server machine,
it is good practice for each user to work with their own tmp
, sources
and
data
folders. This can be done by adding a client
node in the server
configuration file.
<?xml version="1.0" encoding="utf-8" standalone="yes"?> <squore type="server" version="1.3"> <paths> ... </paths> <database> ... </database> <configuration> ... </configuration> <addons> ... </addons> <client> <!-- java system properties are supported under the client node only --> <tmp directory="${java.io.tmpdir}/squore-${user.name}"/> <projects directory="${user.home}/.squore/projects"/> </client> <tmp directory="..."/> <projects directory="..."/> <workspace directory="..."/> </squore>
As stated in the example, java system properties are supported in this section of <SQUORE_HOME>/config.xml.
All three elements are optional, and their default value if missing are the ones described in the XML snippet above.