-
Notifications
You must be signed in to change notification settings - Fork 5
Configuration
#Configuration
In this section I'll describe in short the configuration file's location and the properties of both the End point and the Entry host which can be configured.
##Configuration files
The extension of the configuration files is *.conf
. There are three configuration files:
endpoint-config.conf
entryhost-config.conf
endpoints.conf
The configuration files can be located in a relative to the main.pl
file directory conf/.*conf
or at /etc/plainvm/*.conf
.
First plainvm reads the relative directory if it don't find any configuration files there, it reads them from the /etc/plainvm
directory. If no configuration files are found then the program exits with an error message.
##End point
The End point has few properties which can be configured. They are as follows:
-
PORT
- a port on which the end point should listen for connections. Default value5000
. -
ADDRESS
- an address on which the end point should listen. Default value0.0.0.0
. -
SCREENSHOT_UPDATE_INTERVAL
- an interval on which the end point should make screenshots of it's virtual machines. Default value2
. -
UPDATE_INTERVAL
- an interval on which the end point should check for updated virtual machines. Default value1
. -
ISO_DIR
- directory where will be saved the ISO files which are uploaded during the installation. -
GUACAMOLE_USERS
- directory where is located the Guacamole's user mapping file. -
VMS_LOCATION
- directory where will be located the hard drives of the machines created during the installation process.
Default:
PORT = 5000
ADDRESS = 0.0.0.0
SCREENSHOT_UPDATE_INTERVAL = 2
UPDATE_INTERVAL = 1
ISO_DIR = /home/user/Downloads
GUACAMOLE_USERS = /etc/guacamole/user-mapping.xml
VMS_LOCATION = /home/user/VirtualBox VMs
##Entry host
In this sub-section I'll describe the configuration properties of the Entry host.
-
HTTP_PORT
- port on which should be started the web server. Default value5001
. -
ADDRESS
- an address on which the entry host should listen for client connections. Default value0.0.0.0
. -
ENDPOINT_PORT
- port on which the entry host should connect to the end points. Default value5000
. -
POLL_INTERVAL
- an interval on which the entry host should poll the end points for updates. Default value1
. -
SCREENSHOT_POLL_INTERVAL
- an interval on which the entry host should poll the end points for updates of the VM's screenshots. Default value1
. -
REQUEST_TIMEOUT
- the amount of seconds which the entry host will wait until send error response to the client if the end point haven't returned any response (only forneed-response
requests)
Default:
HTTP_PORT = 5001
ADDRESS = 0.0.0.0
ENDPOINT_PORT = 5000
POLL_INTERVAL = 1
SCREENSHOT_POLL_INTERVAL = 1
REQUEST_TIMEOUT = 30
The entry host has one more configuration file. It's name is endpoints.conf
. It contains all end points associated with the current entry host.
It's value is comma separated list of values of the host names of the end points plus optional port.
Example:
192.168.1.201:4444,192.168.1.206,192.168.1.208:5566
If a port is not provided then the default one, configured in entryhost-config.conf
, will be used.
by Minko Gechev, http://blog.mgechev.com/