Last modified: 2013-10-10 00:02:20 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T57499, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 55499 - Support some form of "AutoSettings.php" like our "mw-config/overrides.php" to hook in after DefaultSettings but before LocalSettings.
Support some form of "AutoSettings.php" like our "mw-config/overrides.php" to...
Status: NEW
Product: MediaWiki
Classification: Unclassified
General/Unknown (Other open bugs)
1.22.0
All All
: Low enhancement (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2013-10-09 06:19 UTC by Daniel Friesen
Modified: 2013-10-10 00:02 UTC (History)
0 users

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Daniel Friesen 2013-10-09 06:19:56 UTC
Reading over Google App Engine's PHP environment, how things like the Memcache(d) libraries are setup so configuration is automatically injected under-the-hood, and looking at our mw-config/overrides.php for distributors hosts. I thought it might be useful to have some sort of AutoSettings for hosts that give explicit support for MediaWiki.

AutoSettings.php would be loaded after DefaultSettings.php but before LocalSettings.php. The file itself – like mw-config/overrides.php – would be a mere stub and explicitly declared as something it's ok for 3rd parties to modify.

Hosts could include documentation like 'Replace .../AutoSettings.php with the contents <?php require_once( "/node/path/to/some/common/AutoSettings.php" );' – and perhaps do that for mw-config/overrides.php too – which would contain some extra code added by the host.

The file would allow the defaults in DefaultSettings.php to be overridden with defaults that work better in the hosting environment.
For some examples of what a hosting environment could do inside of an AutoSettings.php:
- Auto configure caching to use a series of Memcached servers they offer.
- Change the defaults for $wgUseImageMagick $wgImageMagickConvertCommand $wgImageMagickIdentifyCommand to automatically point to the system installed ImageMagick instead of using gd by default.
- Change the defaults for $wgJpegTran, $wgExiv2Command, $wgSVGConverters, the tidy executable, $wgDiff3, $wgDiff, $wgGitBin, and $wgPhpCli to use the correct paths.
- Set $wgDirectoryMode to a default value that's more secure in the hosting environment.
- Auto-configure $wgSMTP to send emails in a way that works efficiently for the hosting environment.
- Auto-configure database settings for things like database host/port/type so only minimal config is required. Or auto-config DBservers or the load-balancer if they offer a standard cluster of replicated SQL servers.
- Auto-configure squid if they offer it on behalf of the users.

I suppose rather than simple AutoSettings.php another possibility might be for  a host to use auto_prepend_file, a custom php extension, etc... and for us to provide an API the host can have it's PHP environment automatically hook into.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links