diff --git a/LocalSettings.php b/LocalSettings.php new file mode 100644 index 00000000000..757af5ced28 --- /dev/null +++ b/LocalSettings.php @@ -0,0 +1,241 @@ +/dev/null;echo +$wgSecretKey = ""; + +# Site upgrade key. Must be set to a string (default provided) to turn on the +# web installer while LocalSettings.php is in place +# tr -c -d '0123456789abcdef' /dev/null;echo +$wgUpgradeKey = ""; + +# Changing this will log out all existing sessions. +$wgAuthenticationTokenVersion = "1"; + +$wgUsePrivateIPs = true; +$wgUseSquid = true; +$wgSquidServers = array(); +$wgSquidServers[] = "127.0.0.1"; + +#$wgSquidServers = array( '127.0.0.1', '5.79.113.102' ); + +$wgUseCdn = true; +$wgCdnServers = array(); +$wgCdnServers[] = "127.0.0.1"; + +## PART FOR DEBUGGING, ALSO SET $wgUseSquid = false; when enabling this ## +#$wgShowExceptionDetails = true; +#$wgShowSQLErrors = true; +#$wgDebugComments = true; +#$wgLogQueries = true; +#$wgDebugDumpSql = true; +#$wgDevelopmentWarnings = true; +#$wgDebugProfiling = true; +#$wgDebugTimestamps = true; +#$wgResourceLoaderDebug = true; +#$wgDebugToolbar = true; + +$wgFileExtensions = array('png','gif','jpg','jpeg','doc','xls','mpp','ppt','tiff','bmp','docx', 'xlsx','pptx','ps','odt','ods','odp','odg','svg','svgz','tar','gz','bzip','bz2','7z','ogg','mp3','wav','md','css','html','dxf','txt','pdf','dia'); + +$wgSVGConverter = 'ImagickExt'; +$wgSVGNativeRendering = true; + +$wgDefaultSkin = "vector"; +$wgSkipSkins = array( "vector-2022" ); +wfLoadSkin( 'Vector' ); + +######################## END OF CUSTOMIZABLE AREA ############################# +# +################ THESE VALUES SHOULD NOT HAVE TO BE CHANGED ################### +$wgScriptPath = ""; +$wgArticlePath = "/$1"; +$wgUsePathInfo = true; +$wgScriptExtension = ".php"; +$wgResourceBasePath = $wgScriptPath; + +## UPO means: this is also a user preference option +$wgEnableEmail = true; +$wgEnableUserEmail = true; # UPO +$wgEnotifUserTalk = false; # UPO +$wgEnotifWatchlist = false; # UPO +$wgEmailAuthentication = true; + +# MySQL table options to use during installation or update +$wgDBTableOptions = "ENGINE=InnoDB, DEFAULT CHARSET=utf8"; + +# Experimental charset support for MySQL 5.0. +$wgDBmysql5 = false; + +/////////////////////////////////// CACHING /////////////////////////////////// + +$wgMainCacheType = 'redis'; +$wgSessionCacheType = 'redis'; // same as WMF prod + +// Not widely tested: +$wgMessageCacheType = 'redis'; +$wgParserCacheType = 'redis'; +$wgLanguageConverterCacheType = 'redis'; + + +/** @see RedisBagOStuff for a full explanation of these options. **/ +$wgObjectCaches['redis'] = array( + 'class' => 'RedisBagOStuff', + 'servers' => array( '127.0.0.1:6379' ), + // 'connectTimeout' => 1, + // 'persistent' => false, + // 'password' => 'secret', + // 'automaticFailOver' => true, +); + +$wgJobTypeConf['default'] = [ + 'class' => 'JobQueueRedis', + 'redisServer' => '127.0.0.1:6379', + 'redisConfig' => [], + 'claimTTL' => 3600, + 'daemonized' => true +]; + +$smwgCacheType = 'redis'; +$smwgQueryResultCacheType = 'redis'; + +//////////////////////////////// END OF CACHING /////////////////////////////// + +$wgEnableUploads = true; +$wgUseImageMagick = true; +$wgImageMagickConvertCommand = "/usr/bin/convert"; +$wgShellLocale = "en_US.utf8"; + +$wgUseInstantCommons = false; +$wgPingback = false; +$wgCacheDirectory = "$IP/cache"; +$wgLanguageCode = "en"; + +$wgRightsPage = ""; # Set to the title of a wiki page that describes your license/copyright +$wgRightsUrl = ""; +$wgRightsText = ""; +$wgRightsIcon = ""; + +$wgDiff3 = "/usr/bin/diff3"; + +########################## SETTINGS FOR EXTENSIONS ############################ + +wfLoadExtension( 'AdminLinks' ); +#require_once( "$IP/extensions/Arrays/Arrays.php" ); + +## ConfirmEdit / QuestyCaptcha settings +wfLoadExtension( 'ConfirmEdit' ); +wfLoadExtension( 'ConfirmEdit/QuestyCaptcha' ); + +## Start QuestyCaptcha block +$wgCaptchaClass = 'QuestyCaptcha'; + +/// CHANGE THIS TO SOMETHING REAL +#$wgCaptchaQuestions[] = array( 'question' => 'Which animal is displayed here? ', 'answer' => 'dog' ); +$wgCaptchaQuestions[] = array( 'question' => 'Which city is the hackerspace located in?', 'answer' => 'Amsterdam' ); +## End QuestyCaptcha block + +$wgGroupPermissions['*' ]['skipcaptcha'] = false; +$wgGroupPermissions['user' ]['skipcaptcha'] = false; +$wgGroupPermissions['autoconfirmed']['skipcaptcha'] = false; +$wgGroupPermissions['bot' ]['skipcaptcha'] = true; // registered bots +$wgGroupPermissions['sysop' ]['skipcaptcha'] = true; + +$wgCaptchaTriggers['edit'] = false; +$wgCaptchaTriggers['create'] = false; +$wgCaptchaTriggers['addurl'] = false; +$wgCaptchaTriggers['createaccount'] = true; +$wgCaptchaTriggers['badlogin'] = true; + +wfLoadExtension( 'Nuke' ); +wfLoadExtension( 'ParserFunctions' ); +wfLoadExtension( 'TextExtracts' ); +wfLoadExtension( 'WikiEditor' ); + +wfLoadExtension( 'PageForms' ); + +wfLoadExtension( 'SemanticMediaWiki' ); +wfLoadExtension( 'SemanticResultFormats' ); + +$wgPFEnableStringFunctions = true; +$wgGroupPermissions['*']['edit'] = false; + +$wgEnableDnsBlacklist = false; +#$wgDnsBlacklistUrls = array( 'xbl.spamhaus.org', 'dnsbl.tornevall.org' ); + +// optional: default is array( 'sysop' ) +//$wgUserMergeProtectedGroups = array( 'groupname' ); + +// Semantic Media Wiki +enableSemantics( 'techinc.nl' ); +$smwgPageSpecialProperties = array( '_MDAT', '_CDAT', '_NEWP', '_LEDT'); +$smwgCategoryFeatures = ( $smwgCategoryFeatures & ~SMW_CAT_REDIRECT ); +$srfgFirstDayOfWeek = 'Monday'; +#$smwgShowFactbox = SMW_FACTBOX_NONEMPTY; + +$wgPageForms24HourTime = true; +$wgGroupPermissions['*']['viewedittab'] = false; + +#$wgPopupsBetaFeature = true; +$wgPopupsOptInDefaultState = '1'; + +$wgDefaultUserOptions['usebetatoolbar'] = 1; +$wgDefaultUserOptions['usebetatoolbar-cgd'] = 1; +$wgDefaultUserOptions['wikieditor-preview'] = 1; +$wgDefaultUserOptions['wikieditor-publish'] = 1; + + +$wgMSU_showAutoCat = true; // Files uploaded while editing a category page will be added to that category +$wgMSU_checkAutoCat = true; // Whether the checkbox for adding a category to a page is checked by default + +#Disable for everyone. +$wgGroupPermissions['*']['edit'] = false; +# Disable for users, too: by default 'user' is allowed to edit, even if '*' is not. +$wgGroupPermissions['user']['edit'] = false; +# Make it so users with confirmed email addresses are in the group. +$wgAutopromote['emailconfirmed'] = APCOND_EMAILCONFIRMED; +# Hide group from user list. +$wgImplicitGroups[] = 'emailconfirmed'; +# Finally, set it to true for the desired group. +$wgGroupPermissions['emailconfirmed']['edit'] = true; + +#$wgReadOnly = 'A backup of the TechInc wiki is currently being made. The side is therefore in read-only mode. Check back in a bit.'; +#$wgMessageCacheType = $wgMainCacheType = $wgParserCacheType = $wgSessionCacheType = CACHE_NONE; +#$wgLocalisationCacheConf['storeClass'] = 'LCStoreNull'; +#$wgIgnoreImageErrors = true; + +$wgMemoryLimit = "64M"; diff --git a/composer.local.json b/composer.local.json new file mode 100644 index 00000000000..15ea5cc9851 --- /dev/null +++ b/composer.local.json @@ -0,0 +1,41 @@ +{ + "config": { + "allow-plugins": { + "wikimedia/composer-merge-plugin": true + } + }, + "require": { + "mediawiki/semantic-media-wiki": "dev-master#649b261378a419a1951e84b7d417b3e5f6cc027a", + "mediawiki/semantic-result-formats": "dev-master#616fd091cdce78d706d13e8b10bf70087615bcd4", + "mediawiki/admin-links": "dev-master#4cec145ad82dbea4e0155bf9abc0ae566547da7b", + "mediawiki/page-forms": "dev-master#d8109745866f0860f66aecd31e009b68e5bedaf1", + "x-mediawiki/confirm-edit": "^1.43" + }, + "repositories": [ + { + "type": "vcs", + "url": "https://gerrit.wikimedia.org/r/mediawiki/extensions/AdminLinks.git" + }, + { + "type": "package", + "package": { + "name": "x-mediawiki/confirm-edit", + "type": "mediawiki-extension", + "version": "1.43.0", + "source": { + "type": "git", + "url": "https://gerrit.wikimedia.org/r/mediawiki/extensions/ConfirmEdit.git", + "reference": "REL1_43" + } + } + } + ], + "extra": { + "merge-plugin": { + "include": [ + "extensions/Nuke/composer.json", + "skins/*/composer.json" + ] + } + } +}