Loading...
 

System configuration


Introduced in Tiki8


System configuration allows for system administrators to change some preferences from outside Tiki. By providing an INI file, administrators can have a central configuration for all of their Tiki installations.

New in Tiki10: Option to load the modules from a static files ( in profile YAML format like http://profiles.tiki.org/Module+Handler ). Search for "Module file" in the admin panel

New in Tiki11: A file db/preconfiguration.php can contain database credentials which are suggested at first Tiki installation. This allows providers of Virtual Servers to preconfigure mysql with different random passwords and usernames before the customers access the Tiki installer.

New in Tiki15: Due to changes in Zend libraries, it is no longer possible to have hierarchical setting of configurations as before. In addition, configuration names can no longer contain dots. For example, client1.example.com will not work. Use client1 instead. Old configurations may not be usable in Tiki 15 and have to be rewritten.




Possible uses for Tiki Farms and hosting companies

  • Connect to other services, such as BigBlueButton, without intervention from the users
  • Configure advanced settings such as Memcache
  • Disable features that are not part of the support plan
  • Respond to security advisories by globally disabling a feature
  • provide tiki_p_admin but make some features inaccessible
  • Hosting company may want to offer all-in-one hosting, but restrict usage of
    • experimental features
    • feature that can be used to gain server access (which is OK for most setups, but not cool for a WikiFarm)
  • Consulting company wants to make simpler admin panels for a customer
  • Using Tiki as an application builder (framework)


Activate the system configuration

The system configuration must be enabled from the db/local.php file. Installations created from Tiki8 and beyond contain samples in the file created by default.

Sample configuration in db/local.php
$system_configuration_file = '/etc/tiki.ini';
$system_configuration_identifier = 'client1';


Another sample configuration in db/local.php, with a relative path
$system_configuration_file = 'db/tiki.ini';
$system_configuration_identifier = 'client1';

If you do this example, make sure .htaccess is active so the tiki.ini can't be read.

When enabled, Tiki will read additional directives from the configuration file based on the selected identifier. The identifier is arbitrary, but can be used either to specify the site or the plan. In the configuration file, multiple configurations can be defined and inheritance can be used.

INI configuration file


Sample INI file
[global]
preference.feature_wysiwyg = "n"
preference.feature_sefurl = "y"
preference.helpurl = "http://support.example.com/"
; ... more settings ...

[basic : global]
; ... this hierarchical block no longer works from Tiki 15 onwards
preference.feature_wiki = "y"
preference.feature_forums = "n"
preference.feature_trackers = "n"
; ... more settings ...

[pro : global]
; ... this hierarchical block no longer works from Tiki 15 onwards
preference.feature_wiki = "y"
; BBB configured, but user can still toggle on/off
preference.bigbluebutton_server_location = "bbb.example.com"
preference.bigbluebutton_server_salt = "1234abcd1234abcd"
; ... more settings ...

[client1 : pro]
; ... this hierarchical block no longer works from Tiki 15 onwards, but [client1] will
preference.browsertitle = "Client #1 Intranet"
preference.sender_email = client1@example.com


In the example above, the following preferences would be set for using the identifier client1:
  • feature_wysiwyg = n
  • feature_sefurl = y
  • helpurl = http://support.example.com/
  • feature_wiki = y
  • bigbluebutton_server_location = bbb.example.com
  • bigbluebutton_server_salt = 1234abcd1234abcd
  • browsertitle = Client #1 Intranet
  • sender_email = client1 at example.com


; at the beginning indicates comments

Disable classes of preferences

Preferences can be disabled by setting a value to each of them individually. However, this process may be long and will require maintenance with the evolutions of Tiki.

Tiki allows to set multiple rule priorities, each verification priority can allow or deny a preference. Rules can be specified at various levels, just like the preference overrides above.

Various rules
[global]
rules.0 = deny experimental new

[pro : global]
; ... this hierarchical block no longer works from Tiki 15 onwards
rules.5 = allow new
rules.10 = allow feature_wysiwyg


In the previous example, sites using the pro identifier would be allowed to use new features and wysiwyg (which is tagged as experimental), including new experimental features, but still be denied old experimental features. Higher priorities are evaluated first and the lookup stops once there is a match.

A draconian provider could use something like this:

Draconian provider configuration
[global]
rules.0 = deny all
rules.1 = allow basic


The preferences need to be tagged in the definitions using the 'tags' key containing an array. Unless specified otherwise, all preferences are considered 'advanced'.

Important note about arrays

Instead of
preference.flaggedrev_approval_categories.0 = "40;41;97;231"


This is the formula
How to set an array
preference.flaggedrev_approval_categories.0 = "40"
preference.flaggedrev_approval_categories.1 = "41"
preference.flaggedrev_approval_categories.2 = "97"
preference.flaggedrev_approval_categories.3 = "231"


or
How to set an array
preference.flaggedrev_approval_categories[] = "40"
preference.flaggedrev_approval_categories[] = "41"
preference.flaggedrev_approval_categories[] = "97"
preference.flaggedrev_approval_categories[] = "231"




Preconfiguration file


When providing on-demand Virtual Machines with Tiki pre-loaded, hosting companies can provide mysql with a database and connection credentials which are different for each customer.
When accessing stage Set the Database Connection of the installer, these values will be prefilled for the customer. This is more efficient than providing them by mail or other means.
These information can obviously not be contained in db/local.php since local.php does not yet exist.

All there is to do is uncomment the appropriate lines in file db/preconfiguration.php and fill the appropriate values:
db/preconfiguration.php
<?php
// This is Tiki's preconfiguration file.
// This holds values which can provide preconfiguration values in the installer, when local.php does not yet exist
// Uncomment and change values as appropriate
$host_tiki_preconfig='localhost';
$user_tiki_preconfig='tiki';
$pass_tiki_preconfig='password';
$dbs_tiki_preconfig='tiki_db';


Environment variable configuration


Tiki will also read information about the database connection and system configuration through environment variables. These can be set through the web server's configuration.

Sample nginx configuration
fastcgi_pass unix:/var/run/php5-fpm.sock;
fastcgi_index route.php;
include fastcgi_params;
fastcgi_param MYSQLCONNSTR_Tiki "Database=client1;Data Source=localhost;User Id=client1;Password=secret";
fastcgi_param TIKI_INI_FILE "/etc/tiki.ini";
fastcgi_param TIKI_INI_IDENTIFIER "client1";


Related

Tiki.ini File | Tiki.ini | INI

doc.tiki.org


Bootstrap

AdminGuide

UserGuide

  • User selector
  • Static Text Tracker Field
  • Subscription Tracker Field
  • System Tracker Field
  • Textarea Tracker Field
  • URL Tracker Field
  • Adding items to a tracker
  • How to change tracker field types
  • Linking trackers
  • Multilingual trackers
  • Searching tracker items
  • Viewing Tracker Results
  • Export trackers
  • Terms and Conditions
  • Accounting
  • User Preferences
  • Inter-User Messages
  • Gmap User
  • Bookmarks
  • Watch
  • User Page
  • MyTiki Details
  • Score vs Karma
  • User Action log
  • Search User
  • Mobile Tiki User
  • User Wizard
  • Must Reads

  • Keywords

    Keywords serve as "hubs" for navigation within the Tiki documentation. They correspond to development keywords (bug reports and feature requests):

    Accessibility (WAI and 508)
    Accounting (7.x)
    Articles and Submissions
    Backlinks
    Banners
    Batch (6.x)
    BigBlueButton audio/video/chat/screensharing (5.x)
    Blog
    Bookmark
    Browser Compatibility
    Link Cache
    Calendar
    Category
    Chat
    Clean URLs
    Comments
    Communication Center
    Compression (gzip)
    Contacts (Address Book)
    Contact us
    Content Templates
    Contribution (2.x)
    Cookie
    Copyright
    Credit (6.x)
    Custom Home and Group Home Page
    Date and Time
    Debugger Console
    Directory of hyperlinks
    Documentation link from Tiki to doc.tiki.org (Help System)
    Docs 8.x
    Draw 7.x
    Dynamic Content
    Dynamic Variable
    External Authentication
    FAQ
    Featured links
    File Gallery
    Forum
    Friendship Network (Community)
    Gmap Google maps
    Groups
    Hotword
    HTML Page
    i18n (Multilingual, l10n, Babelfish)
    Image Gallery
    Import-Export
    Install
    Integrator
    Interoperability
    Inter-User Messages
    InterTiki
    Kaltura video management (4.x)
    Karma
    Live Support
    Login
    Logs (system & action)
    Look and Feel
    Lost edit protection
    Mail-in
    Map with Mapserver
    Menu
    Meta Tags
    Mobile Tiki and Voice Tiki
    Mods
    Module
    MultiTiki
    MyTiki
    Newsletter
    Notepad
    Payment
    Performance Speed / Load
    Permissions
    Platform independence (Linux-Apache, Windows/IIS, Mac, BSD)
    Polls
    Profiles
    Profile Manager
    Report
    Toolbar
    Quiz
    Rating
    Feeds
    Score
    Search engine optimization
    Search
    Search and Replace
    Security
    Semantic links (3.x)
    Shadowbox
    Shadow Layers
    Share
    Shopping cart
    Shoutbox
    Slideshow
    Smiley
    Social Networks
    Spam protection (Anti-bot CATPCHA)
    Spellcheck
    Spreadsheet
    Stats
    Surveys
    Tags (2.x)
    Task
    Tell a Friend, alert + Social Bookmarking
    TikiTests (2.x)
    Theme CSS & Smarty
    Trackers
    Transitions (5.x)
    TRIM
    User Administration including registration and banning
    User Files
    User Menu
    Watch
    WebHelp
    WebDAV (5.x)
    Webmail
    Web Services
    Wiki 3D
    Wiki History, page rename, etc
    Wiki Page Staging and Approval (2.x)
    Wiki Plugin extends basic syntax
    Wiki Syntax
    Wiki structure (book and table of content)
    Workspace
    WSOD
    WYSIWYCA
    WYSIWYG (2.x)
    XMLRPC


    Tiki Newsletter

    Delivered fresh to your email inbox!
    Newsletter subscribe icon
    Don't miss major announcements and other news!
    Contribute to Tiki