Advertisement
Krenair

working CA wgConf setup (without SUL2)

Jul 30th, 2013
127
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.53 KB | None | 0 0
  1. require_once( "$IP/../extensions/CentralAuth/CentralAuth.php" );
  2. $wgCentralAuthDatabase = 'mediawiki_test_centralauth';
  3. $host = 'localhost';
  4. $wgConf->settings = array (
  5. 'wgServer' => array (
  6. 'default' => '//' . $host,
  7. 'mediawiki_test_git' => '//' . $host,
  8. 'mediawiki_test_globalfeatures' => '' . $host,
  9. ),
  10.  
  11. 'wgCanonicalServer' => array (
  12. 'default' => 'http://' . $host,
  13. 'mediawiki_test_git' => 'http://' . $host,
  14. 'mediawiki_test_globalfeatures' => 'http://' . $host,
  15. ),
  16.  
  17. 'wgScriptPath' => array (
  18. 'mediawiki_test_git' => '/MediaWiki/Git/core',
  19. 'mediawiki_test_globalfeatures' => '/MediaWiki/Git/GlobalFeaturesTest'
  20. ),
  21.  
  22. 'wgArticlePath' => array (
  23. 'mediawiki_test_git' => '/MediaWiki/Git/core/index.php/$1',
  24. 'mediawiki_test_globalfeatures' => '/MediaWiki/Git/GlobalFeaturesTest/index.php/$1'
  25. ),
  26.  
  27. 'wgSitename' => array (
  28. 'default' => 'GitTest'
  29. ),
  30.  
  31. 'wgLanguageCode' => array (
  32. 'default' => 'en'
  33. ),
  34.  
  35. 'wgLocalInterwiki' => array(
  36. 'default' => 'en'
  37. ),
  38. );
  39.  
  40. $wgConf->wikis = $wgLocalDatabases;
  41. $wgConf->suffixes = $wgLocalDatabases;
  42. $wgConf->localVHosts = array( 'localhost' );
  43.  
  44. function efGetSiteParams( $conf, $wiki ) {
  45. return array(
  46. 'suffix' => 'wiki',
  47. 'lang' => 'en',
  48. 'params' => array(
  49. 'lang' => 'en',
  50. 'site' => 'wiki',
  51. 'wiki' => $wiki,
  52. ),
  53. 'tags' => array(),
  54. );
  55. }
  56.  
  57. $wgConf->siteParamsCallback = 'efGetSiteParams';
  58. $wgConf->extractAllGlobals( $wgDBname );
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement