Editing the Configuration of Your EMS Console Server Manually

From RAD Studio
Jump to: navigation, search

Go Up to Setting Up Your EMS Console Server

You need to edit the EMSServer.ini file to configue the EMS Console Server.

The default location is : C:\Users\Public\Documents\Embarcadero\EMS

Note: If you modify this file, you must terminate and restart the EMS Console Server to reload the emsserver.ini file.

EMS Database Configuration

You can modify the default information of the EMS Database that the EMS Console Server uses. In the EMSServer.ini file, go to the [Data] section:

  • InstanceName. Specifies the InterBase instance that hosts the EMS database.
The format of InstanceName is the following: [[<host>/]<instance>]. Here are the possible combinations:
  • Value is empty string: default database instance running on local host.
  • <instance>: specified instance running on local host.
  • <host>/<instance>: specified instance running on specified host.
  • Database. EMS Database file local or remote directory.
  • UserName. User name to access the EMS Database.
  • Password. Password to access the EMS Database.
  • SEPassword. Password to connect to an encrypted InterBase database.
  • Pooled. Enables FireDAC connection pooling to the EMS Database to reduce latency.
  • PooledMax. Maximum number of pooled connection allowed to the EMS Database.
[Data]
; Interbase connection parameters
InstanceName=EMS
Database=C:\Users\Public\Documents\Embarcadero\EMS\emsserver.ib
UserName=sysdba
Password=masterkey
SEPassword=
;# SEPassword connects to an encrypted database
Pooled=
;# Set Pooled=0 to disable connection pooled, Pooled=1 to enable. Default value is 1.
PooledMax=
;# Set PooledMax=10 to limit maximum pooled connection.  Default value is 50.

EMS Console Login Configuration

You can modify the default credentials to access the EMS console from a regular browser. In the EMSServer.ini file, go to the [Console.Login] section:

  • UserName. Default user to access the EMS console.
  • Password. Password to access the EMS console.
[Console.Login]
UserName=consoleuser
Password=consolepass

EMS Console Connection

You can modify the default information for the connection to your EMS Console Server in a developer environment. In the EMSServer.ini file, go to the [Console.Connection.Dev] section:

  • Port. Defines the connection port for the HTTP request to the EMS Console. Default port for the EMS console server in a development environment is 8081.
  • HTTPS. Enables HTTPS support for the EMS Console. If enabled, you need to install OpenSSL in your system and configure the certification file information.
  • CertFile. Absolute path to the self-signed certification file (.pem file) used by the EMS Console.
  • RootCertFile. Absolute path to the CA certification file (.pem file) Used by the EMS Console. If you use a self-signed certificate, leave this blank.
  • KeyFile. Absolute path to the self-signed key file (.pem file).
  • KeyFilePassword. Password set to use the certification file.
[Console.Connection.Dev]
Port=8081
;# The following options enable HTTPS support.
HTTPS=1
;# Set HTTPS=1 to enable HTTPS, HTTPS=0 to disable.
 CertFile=C:\Users\Public\Documents\Embarcadero\EMS\cacert.pem
; RootCertFile=
;# When using a self-signed certificate, RootCertFile is left blank.
 KeyFile=C:\Users\Public\Documents\Embarcadero\EMS\cakey.pem
 KeyFilePassword=certpassword

EMS Console Browser Settings

You can modify the default settings used to format the data in the tables of the EMS Console in a web browser. In the EMSServer.ini file, go to the [Console.Browser] section:

  • LimitRows. Maximum number of rows of data shown in the tables. Default value is 15.
  • DateFormat. Format used for the displayed dates in the EMS Console date picker. You can modify the order of the date components or the component separators. Default format is Month/Day/Year.
[Console.Browser]
LimitRows=15
DateFormat=mm/dd/yy

EMS Resource Web Files

You can modify the scripts and the resource files to render the EMS Console Server in a web browser. In the EMSServer.ini file, go to the [Console.Paths.Dev] (for development) or to the [Console.Paths.ISAPI] (for production) section:

  • Default configuration on a developer environment:
[Console.Paths.Dev]
ResourcesFiles = C:\Program Files (x86)\Embarcadero\Studio\19.0\ObjRepos\en\EMS //Folder that contains the template folder (\webresources\templates\)
WebFiles= http://localhost/<folder_name> // URL to the WebFiles folder

Notes:
  • Example of configuration for a production environment, using a Microsoft IIS Server:
[Console.Paths.ISAPI]
ResourcesFiles= C:\inetpub\wwwroot\<folder_name>  //Folder that contains the template folder (\webresources\templates\)
WebFiles=  http://localhost/<folder_name> // URL to the WebFiles folder 
Notes:

Hosting Web Files Resources in a Web Server

You can configure the EMS Console Server to retrieve the web files resources that are hosted in a different host (by modifying the WebFile property of the .ini file).

The Web files resources of the EMS Console Server are included in the following folders:

  • /webresources/css/
  • /webresources/fonts/
  • /webresources/ico/
  • /webresources/img/
  • /webresources/js/

To access the Web files resources in a different Web Server, you need to allow cross-domain request on the Web Server that hosts the resources. Cross-domain request allows HTTP request for resources from a different domain (from which the request was done).

You need to include the Access-Control-Allow-Origin option as an HTTP-Response-Header:

  • Access-Control-Allow-Origin: *
  • Access-Control-Allow-Origin: http://domain:8081/ (more restrictive option)

If you are using Microsoft IIS Server to host Web files resources, see configuring Microsoft IIS Server to allow cross-domain requests.

See Also