Manual:Huggle/Deploying/zh

在自定义安装的MediaWiki上安装huggle
huggle3可以被用于任何MediaWiki，但要记住它原本是为维基媒体基金会的维基网站制作的，而那可以认为是一个巨大的维基农场. 所以huggle主要是为大型维基农场设计的，因而要想让它在简单的小型维基上运行，你可能要稍作调整. 这篇向导介绍了在所有wiki上的安装.

Huggle首頁
这是huggle里一个叫做huggle首页的特殊文件夹. 此文件夹在启动时由日志中的huggle显示，例如：

Wed Feb 11 10:01:47 2015  Home: /home/petanb/.local/share/data/Wikimedia/Huggle/

此文件夹包含huggle的所有配置文件，我们将在本手册中将其称为$huggle_home. 可以有多个房屋，以便通过传递参数--chroot创建一些彼此隔离的单独的huggle安装. 如果你想使用维基媒体基金会wiki和你自己的wiki农场huggle，建议为它创建2个根目录. 如果您只想对1个wiki服务器场使用huggle，则可以忽略它.

全域wiki
Since huggle is designed to run on wiki farms, it requires 1 wiki that is called "global wiki" this wiki contains global configuration file that has the information about individual wikis. In case you have only 1 wiki, you will need to make it a global wiki as well, so that you will have both global and local configuration file there.

配置文件
参见

huggle按以下顺序使用4个配置文件：


 * $huggle_home/Configuration/huggle3.xml Local configuration on pc where it is installed - this file contains URL of global wiki
 * Huggle/Config Global configuration on global wiki which contains information about local wikis
 * Project:Huggle/Config Local configuration on wiki to which you login
 * User:$NAME/huggle3.css User configuration on local wiki

Step by step deployment on 3rd wiki farm
In this scenario we have a wiki farm with 4 wikis on domains:


 * meta.testfarm.wmflabs.org
 * wiki1.testfarm.wmflabs.org
 * wiki2.testfarm.wmflabs.org
 * wiki3.testfarm.wmflabs.org

On meta.testfarm.wmflabs.org/wiki/Huggle/Configuration we need to have following content:

enable-all:true

version:3.1.0 min-version:3.1.0

config:Project:Huggle/Config documentation:https://www.mediawiki.org/wiki/Manual:Huggle feedback:https://en.wikipedia.org/wiki/Wikipedia:Huggle/Feedback // Only if you have irc recent change stream for your wikis - this is optional // irc-server:irc.wikimedia.org // irc-server-name:irc.wikimedia.org

user-agent:Huggle/$1 https://en.wikipedia.org/wiki/Wikipedia:Huggle user-config:Special:Mypage/huggle.css user-config-hg3:Special:Mypage/huggle3.css

// URL of your whitelist server, if you don't have any, keep this commented out // whitelist-server:http://huggle.wmflabs.org/data/

In Project:Huggle/List put

Important xmlrcs_name is name of your wiki as seen by XmlRcs provider, if you don't have this provider, you can remove it from XML entry. Same applies for wl (whitelist id).

Now on each of these 3 wikis, you put this in Project:Huggle/Config.yaml

Now all you need is update the huggle local configuration, open $huggle_home/Configuration/huggle3.xml and change



to



Now you can start huggle and hit reload button. It should load a list of local wikis. Since now you should be able to use huggle on your wikis.