Jump to content


From mediawiki.org
Wiki farm: $wgWikiFarmSettingsDirectory
A directory that contains site-specific configuration files.
Introduced in version:1.38.0 (Gerrit change 776195; git #84cb4ae0)
Removed in version:still in use
Allowed values:A directory that is readable by PHP but not accessible from the browser
Default value:null
Warning Warning: EXPERIMENTAL!



A directory that contains site-specific settings files. Setting this will enable multi-tenant ("Wiki family") mode, causing site-specific settings to be loaded based on information from the web request.

The MW_WIKI_NAME environment variable will be used to determine which wiki's settings should be loaed for the current request. The environment variable should be set by the web server based on the requested domain or path that identifies the wiki. The settings file is expected to be located in the directory specified by the $wgWikiFarmSettingsDirectory setting and use the file extension specified by $wgWikiFarmSettingsExtension, which may be "yaml" or "json". The file must use the YAML settings file format. Settings loaded from this file will be combined with settings found in LocalSettings.php.



Assume there are three wikis with the IDs apples, bananas, and cherries. If $wgWikiFarmSettingsDirectory is set to '/var/opt/mw/farmsettings', then the following YAML files should exist for each wiki in the /var/opt/mw/farmsettings directory:

  • apples.yaml
  • bananas.yaml
  • cherries.yaml