Skip to content

ConfigFile

Carlo Barazzetta edited this page Sep 8, 2017 · 4 revisions

The config file

It is called Config.yaml by default, and it is the one mandatory file in a Kitto application. Think of it as the main entry point. Normally the config file mentions a HomeView from which the entire application is served. The config file contains settings regarding database connections, language and localization, user authentication, access control and so on.

List of first-level config nodes (click on node names for details):

Name Type Description
AppTitle String Application title
Databases Subnode Database connections
Auth Subnode User authentication settings
AccessControl Subnode Access control (user privileges) settings
HomeyTinyView
HomeSmallView
HomeView
String/Subnode Specifies the view to display at application startup (or after login if user authentication is enabled) for client devices up to 5", from 6" to 10" and over 10" respectively
ExtJs Subnode ExtJS-related settings
Log Subnode Logging-related settings
LanguageId String Default user interface language (such as en)
Charset String Default charset (normally utf-8)
FOPEnginePath String Default FOP Engine Path
JavaScriptLibraries List Optional libreries to include
UserFormats Subnode Default user settings (such es date and time format)
Email Subnode Default email settings

A Config.yaml example from HelloKitto:

AppTitle: My First Kitto Application

Databases:
  Main: ADO
    Connection:
      ConnectionString: >
        Provider=SQLOLEDB.1;User ID=sa;Password=xxx;
        Initial Catalog=MyDatabase;Data Source=%COMPUTERNAME%

  Other: DBX
    Connection:
      DriverName: DevartSQLServer
      HostName: %COMPUTERNAME%
      DataBase: MyDatabase
      User_Name: sa
      Password: xxx
      GetDriverFunc: getSQLDriverSQLServer
      LibraryName: dbexpsda40.dll
      VendorLib: sqloledb.dll
  
Auth: DB
  IsClearPassword: True
  IsPassepartoutEnabled: True
  PassepartoutPassword: hfjry%%tebd!qywha$£nò
  Defaults:
    UserName: administrator
    Password: hfjry%%tebd!qywha$£nò

AccessControl: Null
    
# Home is also the default.
HomeView: Home

ExtJS:
  Theme: crisp
  AjaxTimeout: 100000

# Default: en
LanguageId: it
Charset: utf-8

Log:
  # 1 = Minimal, 5 = Debug.
  Level: 5
  TextFile:
    # Set this to false to disable this logger without deleting its configuration.
    IsEnabled: True
    FileName: %APP_PATH%log.txt
  IsEnabled: False

FOPEnginePath: %FOP1_1%

JavaScriptLibraries: jquery-2.1.3.min jSignature.min

UserFormats:
  Date: dd/mm/yyyy
  Time: hh:nn

Email:
  SMTP:
    Default:
      HostName: smtp.gmail.com
      UserName: [email protected]
      Password: userpassword
      Port: 465
      UseTLS: True
Clone this wiki locally