From 2926a00e92a6278cb18e681ece69b0ca8fe8c2d1 Mon Sep 17 00:00:00 2001 From: Ampera Date: Mon, 24 Oct 2022 15:57:58 +0000 Subject: [PATCH] Update 'README.md' --- README.md | 54 +++++++++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 53 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 844a952a..2ad3841a 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,55 @@ # openwiki-mtmw -System Theta's implementation of multitenancy within MediaWiki. \ No newline at end of file +This is MultiTenant MediaWiki, created by Ampera and Soveia of System Theta. + +MultiTenant MediaWiki solves a distinct problem when hosting multiple instances of MediaWiki on a single server, as is intended for The OpenWiki Project. Instead of having to run several complete installations of MediaWiki, most of the code and configuration options can be shared. This drastically reduces hosting complexity, and allows managing of dozens of mediawiki instances at once. + +MTMW was created to be as simple as possible. It's really just a loose collection of scripts, and some conveniently named directories. MediaWiki has its own support for multitenancy, which it calls a wiki-family or wiki farm. A lot of those ideas are represented on [this article](https://www.mediawiki.org/wiki/Manual:Wiki_family), of which similarities are accidental or inevitable. + +This is because MTMW was created in a vacuum, as well as before experimental multi-config support was integrated into MW 1.38. While this resulted in a proprietary solution, it's still a clean and reasonable one. + +This repository also serves to host our light fork of MediaWiki, kept largely up to date with upstream, but with the potential for minor changes needed to facilitate cache purges, or to fix environmental problems. As such, MTMW shares mediawiki's license. + +## Structure + +MTMW is split up into four main directories: wikiconf wikiroot wikidata and wikiutil +When implementing, these directories should all live in the same directory. + +### wikiconf + +wikiconf is the core of MTMW. Configs are split up into shared/global and site-specific configs. +For global configs, there are the following files: + +MTSettings.php - Primarily contains the load order for each file, and also contains any code which may need to execute for all sites, such as setting the entire stack to read-only in the event of maintenance + +GlobalSettings.php - This file contains any general settings to which load order is not important. Only settings present within MediaWiki or MTMW itself should go here. + +GlobalMaintenance.php - Any values like db suffix, read-only, and read-only message which are useful during site upgrades/maintenance should go here. + +LoadableSettings.php - Where extensions get loaded, and where any extension-specific global settings should go. + +Site specific configs are stored in wikiconf/sites in a directory like openwikiproject.org.d, which is the site domain followed by '.d'. The following files exist here: + +settings.php - Site-specific general MediaWiki settings. Only settings present within MediaWiki or MTMW itself should go here. + +maintenance.php - Site-specfific maintenance values, used to set a single site to read-only, or if a per-wiki db/version suffix needs to be set. + +secrets.php - This should contain any secret information, like passwords/keys. This simply keeps them all in one place, to be more easily secured. + +loadables.php - This is where skins and extensions should be loaded, and where the default skin is set + +extvars.php - Any per-site settings that are supposed to apply to extensions should go here. This file is executed after extensions are loaded. + +permissions.php - Any and all permissions settings should go here. This file is executed after extensions are loaded, and should be safe to configure any extension-specific permissions. + +### wikiroot + +Webroots for each mediawiki version. This is a largely off-the-shelf copy of mediawiki, with all non-essential files removed. LocalSettings.php contains a small script to load MTMW based off the HTTP_HOST header. + +### wikidata + +This just holds directories for any per-site data, particularly that which may have to changes + +### wikiutils + +A collection of maintenance scripts \ No newline at end of file