Mediawiki: Difference between revisions
(New page: ==Useful functionality== Category Attributes. Meta tags. ==Installation== yum -y install php-eaccelerator php-mysql ==Useful links.== Which version and which extensions. http://www...) |
|||
(3 intermediate revisions by the same user not shown) | |||
Line 20: | Line 20: | ||
Grant permission. | Grant permission. | ||
http://anden.ongame.com/wiki/index.php/Special:UserRights | http://anden.ongame.com/wiki/index.php/Special:UserRights | ||
Change starting page. | |||
http://www.halfface.se/wiki/index.php/MediaWiki:Mainpage | |||
==Enable uploads.== | ==Enable uploads.== | ||
Line 48: | Line 51: | ||
lsearch-global.conf | lsearch-global.conf | ||
Edit lsearch-global.conf file. Each of these sections needs to be updated to use the correct host name and database. | Edit lsearch-global.conf file. Each of these sections needs to be updated to use the correct host name and database. | ||
[Database] | [Database] | ||
mediawiki : (single) (language,en) (warmup,10) | mediawiki : (single) (language,en) (warmup,10) | ||
[Search-Group] | [Search-Group] | ||
anden.ongame.com : mediawiki | anden.ongame.com : mediawiki | ||
[Index] | [Index] | ||
anden.ongame.com : mediawiki | anden.ongame.com : mediawiki | ||
[Index-Path] | [Index-Path] | ||
<default> : /mwsearch | <default> : /mwsearch | ||
Line 59: | Line 62: | ||
[Properties] | [Properties] | ||
KeywordScoring.suffix=wiki wikilucene wikidev | KeywordScoring.suffix=wiki wikilucene wikidev | ||
ExactCase.suffix=wiktionary wikilucene | ExactCase.suffix=wiktionary wikilucene | ||
[Namespace-Prefix] | [Namespace-Prefix] | ||
Line 78: | Line 81: | ||
Update index regulary. (cron) | Update index regulary. (cron) | ||
# Update index for Lucene search engine. | # Update index for Lucene search engine. | ||
0,15,30,45 * * * * | 0,15,30,45 * * * * /opt/ls2/cron | ||
Integrate to mediawiki | Integrate to mediawiki | ||
download the following extension: | download the following extension: http://www.mediawiki.org/wiki/Extension:MWSearch | ||
Add the following to your: | Add the following to your: | ||
Add the following to your LocalSettings.php: | Add the following to your LocalSettings.php: | ||
Line 92: | Line 95: | ||
==LDAP login== | ==LDAP login== | ||
Download extension: | Download extension: http://www.mediawiki.org/wiki/Extension:LDAP_Authentication | ||
# Enable LDAP authentification. | # Enable LDAP authentification. | ||
Line 101: | Line 104: | ||
$wgLDAPSearchStrings = array( "ONGAME"=>"USER-NAME@ongame.com" ); | $wgLDAPSearchStrings = array( "ONGAME"=>"USER-NAME@ongame.com" ); | ||
$wgLDAPEncryptionType = array("ONGAME"=>"clear"); | $wgLDAPEncryptionType = array("ONGAME"=>"clear"); | ||
$wgLDAPUseSSL = false; | |||
$wgLDAPUseLocal = false; | |||
$wgMinimalPasswordLength = 1; | |||
# Multiple AD domains | |||
require_once 'extensions/LdapAuthentication.php'; | |||
$wgAuth = new LdapAuthenticationPlugin(); | |||
$wgLDAPDomainNames = array( 'ONGAME', 'BAW' ); | |||
$wgLDAPServerNames = array( 'ONGAME' => 'ad.ongame.com', 'BAW' => '10.10.1.13' ); | |||
$wgLDAPSearchStrings = array( 'ONGAME' => 'ONGAME\\USER-NAME', 'BAW' => 'BAW\\USER-NAME' ); | |||
$wgLDAPEncryptionType = array( 'ONGAME' => 'clear', 'BAW' => 'clear' ); | |||
$wgLDAPUseSSL = false; | $wgLDAPUseSSL = false; | ||
$wgLDAPUseLocal = false; | $wgLDAPUseLocal = false; | ||
Line 135: | Line 149: | ||
Change the following array to contain the files you want. | Change the following array to contain the files you want. | ||
$wgFileExtensions = array( 'png', 'gif', 'jpg', 'jpeg', 'pdf', 'txt' ); | $wgFileExtensions = array( 'png', 'gif', 'jpg', 'jpeg', 'pdf', 'txt' ); | ||
$wgFileExtensions = array( 'png', 'gif', 'jpg', 'jpeg', 'pdf', 'txt' ); | |||
==Change favicon.ico== | ==Change favicon.ico== | ||
==Search suggestion== | |||
# Suggestion in search. | |||
$wgEnableMWSuggest = true; | |||
[[Category:Applications]] | |||
[[Category:Unix]] |
Latest revision as of 07:58, 21 October 2008
Useful functionality
Category Attributes. Meta tags.
Installation
yum -y install php-eaccelerator php-mysql
Useful links.
Which version and which extensions.
http://www.mediawiki.org/wiki/Special:Version
Frequently Asked Questions.
http://www.mediawiki.org/wiki/Manual:FAQ
Create templates.
http://www.mediawiki.org/wiki/Help:Templates
Grant permission.
http://anden.ongame.com/wiki/index.php/Special:UserRights
Change starting page.
http://www.halfface.se/wiki/index.php/MediaWiki:Mainpage
Enable uploads.
# Enable uploads $wgEnableUploads = true;
Installation Lucene.
Download binaries from: http://www.mediawiki.org/wiki/Extension:Lucene-search Put it in some directory and configure the following options.
Edit lsearch.conf file:
* MWConfig.global - put here the URL of global configuration file (see below), e.g. file:///etc/lsearch-global.conf * MWConfig.lib - put here the local path to lib directory, e.g. /usr/local/search/ls2/lib * Indexes.path - base path where you want the deamon to store the indexes, e.g. /usr/local/search/indexes * Localization.url - url to MediaWiki message files, e.g. file:///var/www/html/wiki/phase3/languages/messages * Logging.logconfig - local path to log4j configuration file, e.g. /etc/lsearch.log4j
lsearch.conf
MWConfig.global=file:///opt/ls2/lsearch-global.conf MWConfig.lib=/opt/ls2/lib Indexes.path=/opt/ls2/indexes Localization.url=file:///var/www/html/wiki/languages/messages Logging.logconfig=/opt/ls2/mwsearch.log4j
lsearch-global.conf
Edit lsearch-global.conf file. Each of these sections needs to be updated to use the correct host name and database. [Database] mediawiki : (single) (language,en) (warmup,10) [Search-Group] anden.ongame.com : mediawiki [Index] anden.ongame.com : mediawiki [Index-Path] <default> : /mwsearch [OAI] [Properties] KeywordScoring.suffix=wiki wikilucene wikidev ExactCase.suffix=wiktionary wikilucene [Namespace-Prefix] all : <all>
Build the index. To be able to use dumpBackup.php you need to configure AdminSettings.php.
#!/bin/bash LUCENEPATH=/opt/ls2/ WIKIPATH="/var/www/html/wiki/" WIKIdumpBackup="/opt/ls2/mediawiki.xml" #exec 1> /dev/null #exec 2> /dev/null php ${WIKIPATH}/maintenance/dumpBackup.php --current --quiet > $WIKIdumpBackup java -cp ${LUCENEPATH}/LuceneSearch.jar org.wikimedia.lsearch.importer.Importer -s $WIKIdumpBackup mediawiki
Update index regulary. (cron)
# Update index for Lucene search engine. 0,15,30,45 * * * * /opt/ls2/cron
Integrate to mediawiki
download the following extension: http://www.mediawiki.org/wiki/Extension:MWSearch
Add the following to your: Add the following to your LocalSettings.php:
$wgSearchType = 'LuceneSearch'; $wgLuceneHost = 'localhost'; $wgLucenePort = 8123; require_once("extensions/MWSearch/MWSearch.php");
LDAP login
Download extension: http://www.mediawiki.org/wiki/Extension:LDAP_Authentication
# Enable LDAP authentification. require_once( "extensions/LdapAuthentication.php" ); $wgAuth = new LdapAuthenticationPlugin(); $wgLDAPDomainNames = array( "ONGAME" ); $wgLDAPServerNames = array( "ONGAME"=>"ad.ongame.com" ); $wgLDAPSearchStrings = array( "ONGAME"=>"USER-NAME@ongame.com" ); $wgLDAPEncryptionType = array("ONGAME"=>"clear"); $wgLDAPUseSSL = false; $wgLDAPUseLocal = false; $wgMinimalPasswordLength = 1;
# Multiple AD domains require_once 'extensions/LdapAuthentication.php'; $wgAuth = new LdapAuthenticationPlugin(); $wgLDAPDomainNames = array( 'ONGAME', 'BAW' ); $wgLDAPServerNames = array( 'ONGAME' => 'ad.ongame.com', 'BAW' => '10.10.1.13' ); $wgLDAPSearchStrings = array( 'ONGAME' => 'ONGAME\\USER-NAME', 'BAW' => 'BAW\\USER-NAME' ); $wgLDAPEncryptionType = array( 'ONGAME' => 'clear', 'BAW' => 'clear' ); $wgLDAPUseSSL = false; $wgLDAPUseLocal = false; $wgMinimalPasswordLength = 1;
wiked installation
Download and put under extensions.
http://www.mediawiki.org/wiki/Extension:Gadgets
Update your own Gadget-wikEd.js.
http://anden.ongame.com/wiki/index.php/MediaWiki:Gadget-wikEd.js
Description of gadget.
http://anden.ongame.com/wiki/index.php/MediaWiki:Gadget-wikEd
Which gadgets should be installed
http://anden.ongame.com/wiki/index.php/MediaWiki:Gadgets-definition * wikEd|wikEd.js
Terminology
http://www.mediawiki.org/wiki/Extension:Terminology
Create extensions/Terminology/Terminology.php
# Enable Terminology. require_once( "extensions/Terminology/Terminology.php" );
Update the following side with explained words. http://anden.ongame.com/wiki/index.php/Terminology
Support single line definitions ;ITOG:IT Operation Games And multi-line definitions ;HTTP :HyperText Transfer Protocol
Allow other file types.
Change the following array to contain the files you want.
$wgFileExtensions = array( 'png', 'gif', 'jpg', 'jpeg', 'pdf', 'txt' );
$wgFileExtensions = array( 'png', 'gif', 'jpg', 'jpeg', 'pdf', 'txt' );
Change favicon.ico
Search suggestion
- Suggestion in search.
$wgEnableMWSuggest = true;