个人工具

“UbuntuHelp:MediaWiki”的版本间的差异

来自Ubuntu中文

跳转至: 导航, 搜索
第1行: 第1行:
 
{{From|https://help.ubuntu.com/community/MediaWiki}}
 
{{From|https://help.ubuntu.com/community/MediaWiki}}
 
{{Languages|UbuntuHelp:MediaWiki}}
 
{{Languages|UbuntuHelp:MediaWiki}}
MediaWiki is the engine that is used for Wikipedia. See [http://www.mediawiki.org/ MediaWiki] for more information
+
MediaWiki is the engine that is used for Wikipedia, but you can also use it to set up your own wiki server with information of your own. See [http://www.mediawiki.org/ MediaWiki] for more information.
 +
=== Quick shortcut ===
 +
If you would rather not setup MediaWiki by hand, then one of the easiest ways to get up and running with MediaWiki is the [[UbuntuHelp: http://www.turnkeylinux.org/appliances/mediawiki | TurnKey MediaWiki ]] installable live CD appliance, which is based on Ubuntu 8.04.1 (Hardy).
 
=== Install ===
 
=== Install ===
To install on your [U|K|Edu]buntu server (with Apache and MySQL - [[UbuntuHelp:ApacheMySQLPHP|ApacheMySQLPHP]] or another web server already installed): <pre><nowiki>
+
To install on your Ubuntu (or Kubuntu, etc) server (with [[UbuntuHelp:ApacheMySQLPHP|Apache and MySQL]] already installed): <pre><nowiki>
 
  sudo apt-get install mediawiki imagemagick mediawiki-math mysql-server
 
  sudo apt-get install mediawiki imagemagick mediawiki-math mysql-server
 
</nowiki></pre>
 
</nowiki></pre>
第12行: 第14行:
 
  sudo /etc/init.d/apache2 restart
 
  sudo /etc/init.d/apache2 restart
 
</nowiki></pre>
 
</nowiki></pre>
The next step is to visit the website. Since you will be entering passwords, you don't want to make an unsecured connection. Either set up a  ssl server] ( see [[UbuntuHelp:forum/server/apache2/SSL|forum/server/apache2/SSL]]) and connect with https://your.site.net/mediawiki, or visit from the server itself (using [lynx] or [links], two excellent text-based web browsers): <pre><nowiki>
+
The next step is to visit the website. Since you will be entering passwords, you don't want to make an unsecured connection. Either set up a  ssl server] ( see [[UbuntuHelp:forum/server/apache2/SSL|forum/server/apache2/SSL]]) and connect with https://your.site.net/mediawiki, or visit from the server itself (using [[UbuntuHelp:elinks|elinks]] or lynx, two excellent text-based web browsers): <pre><nowiki>
  lynx localhost/mediawiki
+
  elinks localhost/mediawiki
 
</nowiki></pre>
 
</nowiki></pre>
 
fill out the forms, noting that the final form is NOT your root or user password, but the password for the root mysql account (blank by default)
 
fill out the forms, noting that the final form is NOT your root or user password, but the password for the root mysql account (blank by default)
第25行: 第27行:
 
You are done!  you should see a wiki page at: http://your.site.net/mediawiki
 
You are done!  you should see a wiki page at: http://your.site.net/mediawiki
 
===  Customize ===
 
===  Customize ===
The Apache config files reside at /etc/apache2/conf.d/mediawiki.conf
+
The Apache2 config files reside at /etc/apache2/conf.d/mediawiki.conf
 
You might want to customize the look of your wiki.   
 
You might want to customize the look of your wiki.   
 
To change the icon make a 135x135 pixel logo in PNG format and move it to the right place: <pre><nowiki>
 
To change the icon make a 135x135 pixel logo in PNG format and move it to the right place: <pre><nowiki>
第34行: 第36行:
 
to  
 
to  
 
background: #f9f9f9;
 
background: #f9f9f9;
see http://prevolution.org/mediawikifarm for running multiple wikis on a server
+
It is possible to run multiple parallel instances on Mediawiki on a single server:
 +
* http://www.jirp.nl/2008/04/11/mediawiki-farm-multiple-wiki/
 +
=== See also ===
 +
* [http://www.mediawiki.org/wiki/Manual:Running_MediaWiki_on_Ubuntu]
  
 
[[category:UbuntuHelp]]
 
[[category:UbuntuHelp]]

2008年12月16日 (二) 19:23的版本

MediaWiki is the engine that is used for Wikipedia, but you can also use it to set up your own wiki server with information of your own. See MediaWiki for more information.

Quick shortcut

If you would rather not setup MediaWiki by hand, then one of the easiest ways to get up and running with MediaWiki is the TurnKey MediaWiki installable live CD appliance, which is based on Ubuntu 8.04.1 (Hardy).

Install

To install on your Ubuntu (or Kubuntu, etc) server (with Apache and MySQL already installed):
 sudo apt-get install mediawiki imagemagick mediawiki-math mysql-server
To enable MediaWiki edit the following file and remove the '#' from the third line so that it reads 'Alias /mediawiki /var/lib/mediawiki':
sudo gedit /etc/apache2/conf.d/mediawiki.conf
Then restart apache:
 sudo /etc/init.d/apache2 restart
The next step is to visit the website. Since you will be entering passwords, you don't want to make an unsecured connection. Either set up a ssl server] ( see forum/server/apache2/SSL) and connect with https://your.site.net/mediawiki, or visit from the server itself (using elinks or lynx, two excellent text-based web browsers):
 elinks localhost/mediawiki

fill out the forms, noting that the final form is NOT your root or user password, but the password for the root mysql account (blank by default) Lastly, move the config files as requested to prevent anyone else from changing these settings: NOTE: Check the output in your web browser if it's instructions differ from below follow them.

 sudo mv /var/lib/mediawiki/config/LocalSettings.php /etc/mediawiki/LocalSettings.php
 sudo chmod 600 /etc/mediawiki/LocalSettings.php
 sudo rm -Rf /var/lib/mediawiki/config

You are done! you should see a wiki page at: http://your.site.net/mediawiki

Customize

The Apache2 config files reside at /etc/apache2/conf.d/mediawiki.conf You might want to customize the look of your wiki.

To change the icon make a 135x135 pixel logo in PNG format and move it to the right place:
 sudo cp my_new_logo.png /var/lib/mediawiki/skins/common/images/wiki.png

To get rid of the Mac-like sunburst in the background, edit /var/lib/mediawiki/skins/monobook/main.css and change: background: #f9f9f9 url(headbg.jpg) 0 0 no-repeat; to background: #f9f9f9; It is possible to run multiple parallel instances on Mediawiki on a single server:

See also