User:TiazuGotAutism333/CentralAuth

From Uncyclopedia, the content-free encyclopedia
Jump to navigation Jump to search

wfLoadExtension( "CentralAuth" );

///////////////////////////////////

  1. General CentralAuth configuration

///////////////////////////////////

$wgJobRunRate = 0;

// All the permissions relative to this extension unset( $wgGroupPermissions['*']['centralauth-merge'] ); $wgGroupPermissions['sysop']['centralauth-merge'] = true; $wgGroupPermissions['sysop']['centralauth-unmerge'] = true; $wgGroupPermissions['sysop']['centralauth-lock'] = true; $wgGroupPermissions['sysop']['centralauth-oversight'] = true; $wgGroupPermissions['sysop']['globalgrouppermissions'] = true; $wgGroupPermissions['sysop']['globalgroupmembership'] = true; $wgGroupPermissions['sysop']['centralauth-rename'] = true; $wgGroupPermissions['sysop']['centralauth-usermerge'] = true;


// If true, global session and token cookies will be set alongside the per-wiki session and login tokens when users log in with a global account. // This allows other wikis on the same domain to transparently log them in. $wgCentralAuthCookies = true; $wgCentralAuthDatabase = 'centralauth';

// If true, existing unattached accounts will be automatically migrated if possible at first login. // Any new account creations will be required to attach. // If false, unattached accounts will not be harassed unless the individual account has opted in to migration. $wgCentralAuthAutoMigrate = true;

// If true, existing unattached accounts where no global account exists will be compared to see if a merge can be made based on passwords and emails with no clashes (all accounts merge). $wgCentralAuthAutoMigrateNonGlobalAccounts = true;

$wgCentralAuthCookieDomain = '.esportspedia.com';

// Mapping from domain name to wiki id for other wikis to automatically login into // Do we need 'wiki_login' here? What is meant by 'other'? $wgCentralAuthAutoLoginWikis = array (

       'https://staging.base.esportspedia.com' => 'wiki_base',
       'https://staging.cod.esportspedia.com' => 'wiki_cod',
       'https://staging.collegiate.esportspedia.com' => 'wiki_collegiate',
       'https://staging.demo.esportspedia.com' => 'wiki_demo',
       'https://staging.halo.esportspedia.com' => 'wiki_halo',

// 'https://staging.login.esportspedia.com' => 'wiki_login',

       'https://staging.lol.esportspedia.com' => 'wiki_lol',
       'https://staging.smite.esportspedia.com' => 'wiki_smite'

);

// Create the local account on pageview, set false to require a local login to create it. $wgCentralAuthCreateOnView = true;

// Don't autologin to this wiki if( ( $key = array_search( $wgDBname, $wgCentralAuthAutoLoginWikis ) ) !== false ) { // unset( $wgCentralAuthAutoLoginWikis[$key] ); } // Activates the redirect to the "central login wiki" $wgCentralAuthLoginWiki = 'wiki_login';

  1. Skips the "login success" page
      1. $wgCentralAuthSilentLogin = true;

$wgCentralAuthDryRun = false; $wgConf = new SiteConfiguration;

  1. Read wiki lists

$wgLocalDatabases = array( 'wiki_base', 'wiki_cod', 'wiki_collegiate', 'wiki_demo', 'wiki_halo', 'wiki_login', 'wiki_lol', 'wiki_smite' );

    1. $wgLocalDatabases = array( 'wiki_base', 'wiki_cod', 'wiki_collegiate', 'wiki_demo', 'wiki_halo', 'wiki_lol', 'wiki_smite' );

$wgConf->wikis = $wgLocalDatabases; //$wgConf->suffixes = array( '_wiki' );

$wgConf->settings = array(

   'wgServer' => array(
       'default'    => ( PHP_SAPI == 'cli' )? 'localhost' : '//' . $_SERVER['HTTP_HOST'],
       'wiki_base'       => 'https://staging.base.esportspedia.com',
       'wiki_cod'        => 'https://staging.cod.esportspedia.com',
       'wiki_collegiate' => 'https://staging.collegiate.esportspedia.com',
       'wiki_demo'       => 'https://staging.demo.esportspedia.com',
       'wiki_halo'       => 'https://staging.halo.esportspedia.com',
       'wiki_login'      => 'https://staging.login.esportspedia.com',
       'wiki_lol'        => 'https://staging.lol.esportspedia.com',
       'wiki_smite'      => 'https://staging.smite.esportspedia.com'
   ),
   'wgCanonicalServer' => array(
       'default'    => "$wgServer",
       'wiki_base'       => 'https://staging.base.esportspedia.com',
       'wiki_cod'        => 'https://staging.cod.esportspedia.com',
       'wiki_collegiate' => 'https://staging.collegiate.esportspedia.com',
       'wiki_demo'       => 'https://staging.demo.esportspedia.com',
       'wiki_halo'       => 'https://staging.halo.esportspedia.com',
       'wiki_login'      => 'https://staging.login.esportspedia.com',
       'wiki_lol'        => 'https://staging.lol.esportspedia.com',
       'wiki_smite'      => 'https://staging.smite.esportspedia.com'
   ),
   'wgArticlePath' => array(
       'default'   => '/wiki/$1'
   )

);

$wgConf->extractAllGlobals( $wgDBname );