КакНастраивать

Конфигурирование вики

Данная страница должна помочь в процессе конфигурирования уже установленной вики на базе МойнМойн.

Кодировка

МойнМойн использует Юникод для внутреннего представления строк и кодировку UTF-8 для ввода/вывода, в который входят хранение страниц, генерация HTML-страниц и файлы с переводами. Кодировка, используемая для чтения и записи внешних ресурсов, задана в параметре config.charset как utf-8. Данное значение подходит для любого языка, так как любой символ может быть закодирован в UTF-8. Не рекомендуется менять значение данного параметра, не смотря на то, что технически это возможно.

<!> Для использования в значениях параметров строк с символами, не входящими в набор символов ASCII (коды символов 32—127), необходимо указать корректную кодировку у файла конфигурации. Также рекомендуется проверить, что параметры консоли и редактора относительно используемых корректны.

Ряд параметров обязан использовать в значениях строки Юникод. Например, имя сайта может содержать немецкие умляуты, или французские диакритические символы, или быть на русском или иврите. В связи с этим необходимо использовать строки Юникод для задания подобных значений. Строки Юникод задаются путём предварения их символом «u». Примеры использования:

   1    # Site name, used by default for wiki name-logo [Unicode]
   2    sitename = u"Jürgen's Wiki"
   3    # Ещё один пример:
   4    sitename = u'Вики-сайт'

Рекомендуется читать комментарии в конфигурационном файле, так как в ни обычно указано, какие параметры обязаны использовать Юникод.

Примечания:

==== Использование различных кодировок в файле конфигурации ==

Конфигурационный файл по умолчанию в составе дистрибутива МойнМойн использует кодировку ISO 8859-1. Это не вызывает проблем в случае использования западноевропейских языков, таких как английский или немецкий, но непригодно для использования способов письма, не использующих латиницу. Необходимо использовать кодировку UTF-8 при использовании в файле конфигурации символов, отличных от латиницы.

Для этого достаточно указать следующую строку первой во всех конфигурационных файлах:

# -*- coding: utf-8 -*-

/!\ Для редактирования конфигурационных файлов в кодировке UTF-8 необходим текстовый редактор, который корректно обрабатывает данную кодировку и действительно её использует.

Параметры, значения которых являются строками Юникод, могут быть распознаны по значениям по умолчанию с префиксом «u"..."» или «ur"..."» (префиксный символ «u» означает «unicode» — Юникод) или в случае ,когда в описании явно указано сие.

Для готовых конфигураций для различных языков см. ConfigMarket. Также см. Раздел, касающийся переменных Юникод.

Конфигурирование возможностей настройки учётной записи

Администратор может жёстко задать, отключить или запретить отдеьные параметры настройки учётной записи, см. КакНастраивать/НастройкиУчётнойЗаписи.

Конфигурирование единичного экземпляра вики

В случае, если на сервере запускается единичный экземпляр вики, нет необходимости копировать файл farmconfig.py в каталог с конфигурационными файлами (удалите этот файл и одноимённый файл с расширением .pyc в случае, если они там есть). Если файл конфигурации фермы отсутствует, МойнМойн использует файл wikiconfig.py.

Файл wikiconfig.py может находиться где угодно, необходима лишь возможность импортирования его МойнМойн — для этого рекомендуется добавить каталог, в котором он находится, первым элементом в sys.path (это список путей, в которых Python ищет импортируемые файлы). Задание sys.path происходит на раннем этапе запуска сервера, обычно в скрипте-адаптере (например, moin.cgi или moin.wsgi) — см. комментарии к соответствующему скрипту для подробностей.

Основные замечания по структуре файла конфигурации вики или фермы:

   1 # -*- coding: utf-8 -*-
   2 
   3 from MoinMoin.config.multiconfig import DefaultConfig
   4 
   5 class Config(DefaultConfig):
   6 
   7    sitename = u'МояВики'   # префикс «u» означает, что строка будет сконфертирована в юникод 
   8    interwikiname = 'MyWiki'
   9    data_dir = '/путь/к/каталогу/data/'
  10    underlay_dir = '/путь/к/каталогу/underlay/'
  11    
  12    # Другие параметры конфигурации располагаются ниже

Конфигурация вики-фермы

Вики-сервер МойнМойн позволяет иметь несколько экземпляров вики, использующие одну установку сервера, один набор конфигурационных файлов и один серверный процесс. Это особенно важно для таких запускаемых на постоянной основе (а не на время обработки одного запроса, как в случае с CGI) серверных окружений, как Twisted, так как сервер на базе Twisted постоянно занимает TCP-порт на определённом IP-адресе. Поэтому для виртуального хостинга нескольких вики на одном и том же IP и порту необходим сервер, могущий иметь загруженными несколько конфигураций одновременно и использовать нужную при обработке запроса по определённому URL.

Для выбора нужной конфигурации среди имеющихся МойнМойн переменную конфигурации wikis, находящуюся в файле farmconfig.py — она содержит список пар вида (имя вики, префикс URL). Для имени вики необходимо использовать только строковые литералы, являющиеся идентификаторами Python (то есть, идентификатор ::= (буква | "_") (буква | цифра | "_")*, буква ::= ("A".."Z" | "a".."z"), цифра ::= "0".."9"; если данный набор правил непонятен, рекомендуется использовать слово, набранное латиницей). При обработке запроса по некоему URL МойнМойн выполняет поиск по данному списку и пытается последовательно применить шаблон префикс URL к имеющемуся URL. Если шаблон применяется успешно, то МойнМойн использует конфигурацию из файла имя_вики.py (находящегося обычно в том же каталоге; реально используется первое совпадение из sys.path).

Файл farmconfig.py в составе дистрибутива содержит ряд примеров задания параметров для вики-фермы, содержащей несколько вики. Достаточно адаптировать его соответственно нуждам в случае необходимости использования нескольких вики.

/!\ Для простоты изложения далее конфигурация вики в составе вики-фермы будет называться wikiconfig.py. Естественно, на практике нужно использовать имя файла, соответствующее имени вики (имя_вики.py).

После настройки параметра wikis в файле farmconfig.py, как описано выше, необходимо настроить собственно экземпляры вики. Далее даны несколько советов для упрощения процесса администрирования вики-фермы. Рекомендуется предварительно прочитать раздел, относящийся к конфигурированию отдельного экземпляра вики, так как там поясняется механизм наследования.

В МойнМойн используется механизм конфигурирования, основанный на классах Python для возможности задавать общие настройки вики в одном месте — в базовом файле конфигурации (пример конфигурации см. В файле farmconfig.py):

farmconfig.py:

   1 # -*- coding: utf-8 -*-
   2 # farmconfig.py:
   3 from MoinMoin.config.multiconfig import DefaultConfig
   4 class FarmConfig(DefaultConfig):
   5    url_prefix = '/wiki'
   6    show_hosts = True
   7    underlay_dir = '/место/нахождения/общего/underlay'
   8    # ...

Конфигурации экземпляров вики в этом случае будут содержать только те настройки, которые должны быть различными (например, логотип, директория с данными, настройки списков доступа). Всё прочее они унаследуют от базового файла конфигурации, см. moinmaster.py для примера:

moinmaster.py:

   1 # -*- coding: utf-8 -*-
   2 # moinmaster.py:
   3 from farmconfig import FarmConfig
   4 class Config(FarmConfig):
   5    show_hosts = False
   6    sitename = u'МойнМастер'
   7    interwikiname = 'MoinMaster'
   8    data_dir = '/org/de.wikiwikiweb.moinmaster/data/'
   9    # ...

Обзор параметров конфигурации

Представленная далее таблица содержит значения по умолчанию и краткие описания для большинства параметров конфигурации. Для большинства из них нет необходимости переопределять значения по умолчанию, параметры, которые необходимо указывать для каждого экземпляра вики, перечислены в примере файла wikiconfig.py в составе дистрибутива МойнМойн.

(!) Также можно изучить файл MoinMoin/config/multiconfig.py, класс DefaultConfig для дополнительной информации (данный файл содержит конфигурацию по умолчанию).

Access control lists

ACLs control who may do what, see HelpOnAccessControlLists.

Variable name Default Description
acl_hierarchic False True to use hierarchical ACLs
acl_rights_after u'' ACL that is processed after the on-page/default ACL
acl_rights_before u'' ACL that is processed before the on-page/default ACL
acl_rights_default ... ACL used if no ACL is specified on the page
acl_rights_valid ... Valid tokens for right sides of ACL entries.

Mapping of attachment extensions to actions

Variable name Default Description
extensions_mapping ... file extension -> do -> action

Authentication / Authorization / Security settings

Variable name Default Description
DesktopEdition False if True, give all local users special powers - only use this for a local desktop wiki!
SecurityPolicy None Class object hook for implementing security restrictions or relaxations
actions_excluded ... Exclude unwanted actions (list of strings)
actions_superuser ['newaccount'] Restrict actions to superuser only (list of strings)
allow_xslt False if True, enables XSLT processing via 4Suite (Note that this is DANGEROUS. It enables anyone who can edit the wiki to get read/write access to your filesystem as the moin process uid/gid and to insert arbitrary HTML into your wiki pages, which is why this setting defaults to False (XSLT disabled). Do not set it to other values, except if you know what you do and if you have very trusted editors only).
auth [MoinAuth()] list of auth objects, to be called in this order (see HelpOnAuthentication)
auth_methods_trusted ... authentication methods for which users should be included in the special "Trusted" ACL group.
passlib_crypt_context {'schemes': ['sha512_crypt']} passlib CryptContext arguments, see passlib docs
passlib_support True If True (default), import passlib and support password hashes offered by it.
password_checker _default_password_checker checks whether a password is acceptable (default check is length >= 6, at least 4 different chars, no keyboard sequence, not username used somehow (you can switch this off by using `None`)
password_scheme '{PASSLIB}' Either "{PASSLIB}" (default) to use passlib for creating and upgrading password hashes (see also passlib_crypt_context for passlib configuration), or "{SSHA}" (or any other of the builtin password schemes) to not use passlib (not recommended).
recovery_token_lifetime 12 how long the password recovery token is valid [h]
secrets None Either a long shared secret string used for multiple purposes or a dict {"purpose": "longsecretstring", ...} for setting up different shared secrets for different purposes. If you don't setup own secret(s), a secret string will be auto-generated from other config settings.
superuser [] List of trusted user names with wiki system administration super powers (not to be confused with ACL admin rights!). Used for e.g. software installation, language installation via SystemPagesSetup and more. See also HelpOnSuperUser.

Backup settings

These settings control how the backup action works and who is allowed to use it.

Variable name Default Description
backup_compression 'gz' What compression to use for the backup ("gz" or "bz2").
backup_exclude ... Function f(self, filename) that tells whether a file should be excluded from backup. By default, nothing is excluded.
backup_include [] List of pathes to backup.
backup_users [] List of trusted user names who are allowed to get a backup.

Datastruct settings

Variable name Default Description
dicts ... function f(cfg, request) that returns a backend which is used to access dicts definitions.
groups ... function f(cfg, request) that returns a backend which is used to access groups definitions.

Editor related

Variable name Default Description
comment_required False if True, only allow saving if a comment is filled in
edit_locking 'warn 10' Editor locking policy: None, 'warn <timeout in minutes>', or 'lock <timeout in minutes>'
edit_rows 20 Default height of the edit box
edit_ticketing True
editor_default 'text' Editor to use by default, 'text' or 'gui'
editor_force True if True, force using the default editor
editor_ui 'theonepreferred' Editor choice shown on the user interface, 'freechoice' or 'theonepreferred'
page_license_enabled False if True, show a license hint in page editor.
page_license_page u'WikiLicense' Page linked from the license hint. [Unicode]

Mail settings

These settings control outgoing and incoming email from and to the wiki.

Variable name Default Description
mail_from None Used as From: address for generated mail.
mail_import_pagename_envelope u'%s' Use this to add some fixed prefix/postfix to the generated target pagename.
mail_import_pagename_regex '\\[\\[([^\\]]*)\\]\\]' Regular expression used to search for target pagename specification.
mail_import_pagename_search ['subject', 'to'] Where to look for target pagename specification.
mail_import_subpage_template u'$from-$date-$subject' Create subpages using this template when importing mail.
mail_import_wiki_addrs [] Target mail addresses to consider when importing mail
mail_login None 'username userpass' for SMTP server authentication (None = don't use auth).
mail_notify_att_added_intro ... Template for the attachment added notification mail intro text
mail_notify_att_added_subject ... Template for the attachment added notification mail subject header
mail_notify_att_removed_intro ... Template for the attachment removed notification mail intro text
mail_notify_att_removed_subject ... Template for the attachment removed notification mail subject header
mail_notify_page_changed_intro ... Template for the page changed notification mail intro text
mail_notify_page_changed_subject ... Template for the page changed notification mail subject header
mail_notify_page_deleted_intro ... Template for the page deleted notification mail intro text
mail_notify_page_deleted_subject ... Template for the page deleted notification mail subject header
mail_notify_page_renamed_intro ... Template for the page renamed notification mail intro text
mail_notify_page_renamed_subject ... Template for the page renamed notification mail subject header
mail_notify_page_text ... Template for putting together the pieces for the page changed/deleted/renamed notification mail text body
mail_notify_user_created_intro ... Template for the user created notification mail intro text
mail_notify_user_created_subject ... Template for the user created notification mail subject header
mail_sendmail None sendmail command to use for sending mail (None = don't use sendmail)
mail_smarthost None Address of SMTP server to use for sending mail (None = don't use SMTP server).

OpenID Server

These settings control the built-in OpenID Identity Provider (server).

Variable name Default Description
openid_server_enable_user False If True, the OpenIDUser processing instruction is allowed.
openid_server_enabled False True to enable the built-in OpenID server.
openid_server_restricted_users_group None If set to a group name, the group members are allowed to use the wiki as an OpenID provider. (None = allow for all users)

OpenID Relying Party

These settings control the built-in OpenID Relying Party (client).

Variable name Default Description
openidrp_allowed_op [] List of forced providers

Special page names

Variable name Default Description
page_category_regex ... Pagenames exactly matching this regex are regarded as Wiki categories [Unicode]
page_dict_regex u'(?P<all>(?P<key>\\S+)Dict)' Pagenames exactly matching this regex are regarded as pages containing variable dictionary definitions [Unicode]
page_front_page u'LanguageSetup' Name of the front page. We don't expect you to keep the default. Just read LanguageSetup in case you're wondering... [Unicode]
page_group_regex u'(?P<all>(?P<key>\\S+)Group)' Pagenames exactly matching this regex are regarded as pages containing group definitions [Unicode]
page_local_spelling_words u'LocalSpellingWords' Name of the page containing user-provided spellchecker words [Unicode]
page_template_regex ... Pagenames exactly matching this regex are regarded as pages containing templates for new pages [Unicode]

Paths

Variable name Default Description
cache_dir None Directory for caching, by default computed from data_dir/cache.
data_dir './data/' Path to the data directory containing your (locally made) wiki pages.
data_underlay_dir './underlay/' Path to the underlay directory containing distribution system and help pages.
docbook_html_dir ... Path to the directory with the Docbook to HTML XSLT files (optional, used by the docbook parser). The default value is correct for Debian Etch.
plugin_dir None Plugin directory, by default computed to be data_dir/plugin.
plugin_dirs [] Additional plugin directories.
session_dir None Directory for session storage, by default computed to be cache_dir/session.
shared_intermap None Path to a file containing global InterWiki definitions (or a list of such filenames)
user_dir None Directory for user storage, by default computed to be data_dir/user.

RSS settings

These settings control RSS behaviour.

Variable name Default Description
rss_ddiffs 0 If set to 1, links to diff view instead of page itself would be generated by default. Can be changed via ddiffs URL query parameter of rss_rc action.
rss_diffs 0 Add diffs in RSS item descriptions by default. Can be changed via diffs URL query parameter of rss_rc action.
rss_items_default 15 Default maximum items value for RSS feed. Can be changed via items URL query parameter of rss_rc action.
rss_items_limit 100 Limit for item count got via RSS (i. e. user can't get more than items_limit items even via changing items URL query parameter).
rss_lines_default 20 Default line count limit for diffs added as item descriptions for RSS items. Can be changed via lines URL query parameter of rss_rc action.
rss_lines_limit 100 Limit for possible line count for diffs added as item descriptions in RSS.
rss_page_filter_pattern '' Default page filter pattern for RSS feed. Empty pattern matches to any page. Pattern beginning with circumflex is interpreted as regular expression. Pattern ending with slash matches page and all its subpages. Otherwise pattern sets specific pagename. Can be changed via page URL query parameter of rss_rc action.
rss_show_attachment_entries 0 If set to 1, items, related to attachment management, would be added to RSS feed. Can be changed via show_att URL query parameter of rss_rc action.
rss_show_page_history_link True Add link to page change history RSS feed in theme.
rss_unique 0 If set to 1, for each page name only one RSS item would be shown. Can be changed via unique rss_rc action URL query parameter.

Search macro settings

Settings related to behaviour of search macros (such as FullSearch, FullSearchCached, PageList)

Variable name Default Description
search_macro_highlight_pages 1 Add highlight parameter to links in search results generated by search macros by default.
search_macro_highlight_titles 1 Perform title matches highlighting by default in search results generated by macro.
search_macro_parse_args False Do search macro parameter parsing. In previous versions of MoinMoin, whole search macro parameter string had been interpreted as needle. Now, to provide ability to pass additional parameters, this behaviour should be changed.

Session settings

Session-related settings, see HelpOnSessions.

Variable name Default Description
cookie_domain None Domain used in the session cookie. (None = do not specify domain).
cookie_httponly False Use a httponly cookie that can only be used by the server, not by clientside scripts.
cookie_lifetime (0, 12) Session lifetime [h] of (anonymous, logged-in) users (see HelpOnSessions for details).
cookie_name None The variable part of the session cookie name. (None = determine from URL, siteidmagic = use siteid, any other string = use that)
cookie_path None Path used in the session cookie (None = auto-detect). Please only set if you know exactly what you are doing.
cookie_secure None Use secure cookie. (None = auto-enable secure cookie for https, True = ever use secure cookie, False = never use secure cookie).
session_service web.session.FileSessionService() The session service.

Anti-Spam/Leech/DOS

These settings help limiting ressource usage and avoiding abuse.

Variable name Default Description
antispam_master_url ... where antispam security policy fetches spam pattern updates (if it is enabled)
hosts_deny [] List of denied IPs; if an IP ends with a dot, it denies a whole subnet (class A, B or C)
surge_action_limits ... Surge protection tries to deny clients causing too much load/traffic, see HelpOnConfiguration/SurgeProtection.
surge_lockout_time 3600 time [s] someone gets locked out when ignoring the warnings
textchas None Spam protection setup using site-specific questions/answers, see HelpOnSpam.
textchas_disabled_group None Name of a group of trusted users who do not get asked TextCha questions.
textchas_expiry_time 600 Time [s] for a TextCha to expire.
ua_spiders ... A regex of HTTP_USER_AGENTs that should be excluded from logging and are not allowed to use actions.
unzip_attachments_count 101 max. number of files which are extracted from the zip file
unzip_attachments_space 200000000.0 max. total amount of bytes can be used to unzip files [bytes]
unzip_single_file_size 2000000.0 max. size of a single file in the archive which will be extracted [bytes]

Style / Theme / UI related

These settings control how the wiki user interface will look like.

Variable name Default Description
backlink_method _default_backlink_method function determining how the (last part of the) pagename should be rendered in the title area
changed_time_fmt '%H:%M' Time format used on RecentChanges for page edits within the last 24 hours
chart_options None If you have gdchart, use something like chart_options = {'width': 720, 'height': 540}
date_fmt '%Y-%m-%d' System date format, used mostly in RecentChanges
datetime_fmt '%Y-%m-%d %H:%M:%S' Default format for dates and times (when the user has no preferences or chose the "default" date format)
edit_bar ... list of edit bar entries
history_count (100, 200, 5, 10, 25, 50) Number of revisions shown for info/history action (default_count_shown, max_count_shown, [other values shown as page size choices]). At least first two values (default and maximum) should be provided. If additional values are provided, user will be able to change number of items per page in the UI.
history_paging True Enable paging functionality for info action's history display.
html_pagetitle None Allows you to set a specific HTML page title (if None, it defaults to the value of sitename)
interwiki_preferred [] In dialogues, show those wikis at the top of the list.
interwikiname None unique and stable InterWiki name (prefix, moniker) of the site [Unicode], or None
logo_string None The wiki logo top of page, HTML is allowed (<img> is possible as well) [Unicode]
navi_bar ... Most important page names. Users can add more names in their quick links in user preferences. To link to URL, use u"[[url|link title]]", to use a shortened name for long page name, use u"[[LongLongPageName|title]]". [list of Unicode strings]
packagepages_actions_excluded ... list with excluded package actions (e.g. because they are dangerous / questionable)
page_credits ... list with html fragments with logos or strings for crediting.
page_footer1 '' Custom HTML markup sent before the system footer.
page_footer2 '' Custom HTML markup sent after the system footer.
page_header1 '' Custom HTML markup sent before the system header / title area but after the body tag.
page_header2 '' Custom HTML markup sent after the system header / title area (and body tag).
page_iconbar ... list of icons to show in iconbar, valid values are only those in page_icons_table. Available only in classic theme.
page_icons_table ... dict of {'iconname': (url, title, icon-img-key), ...}. Available only in classic theme.
show_highlight_msg False Show message that page has highlighted text and provide link to non-highlighted version.
show_hosts True if True, show host names and IPs. Set to False to hide them.
show_interwiki False if True, let the theme display your interwiki name
show_names True if True, show user names in the revision history and on RecentChanges. Set to False to hide them.
show_rename_redirect False if True, offer creation of redirect pages when renaming wiki pages
show_section_numbers False show section numbers in headings by default
show_timings False show some timing values at bottom of a page
show_version False show moin's version at the bottom of a page
sistersites [] list of tuples ('WikiName', 'sisterpagelist_fetch_url')
sitename u'Untitled Wiki' Short description of your wiki site, displayed below the logo on each page, and used in RSS documents as the channel title [Unicode]
stylesheets [] List of tuples (media, csshref) to insert after theme css, before user css, see HelpOnThemes.
supplementation_page False if True, show a link to the supplementation page in the theme
supplementation_page_name u'Discussion' default name of the supplementation (sub)page [unicode]
supplementation_page_template u'DiscussionTemplate' default template used for creation of the supplementation page [unicode]
theme_default 'modernized' the name of the theme that is used by default (see HelpOnThemes)
theme_force False if True, do not allow to change the theme
trail_size 5 Number of pages in the trail of visited pages

URLs

Variable name Default Description
notification_bot_uri None URI of the Jabber notification bot.
url_mappings {} lookup table to remap URL prefixes (dict of 'prefix': 'replacement'); especially useful in intranets, when whole trees of externally hosted documents move around
url_prefix_action None Use 'action' to enable action URL generation to be compatible with robots.txt. It will generate .../action/info/PageName?action=info then. Recommended for internet wikis.
url_prefix_fckeditor None used as the base URL for FCKeditor - similar to url_prefix_local, but just for FCKeditor.
url_prefix_local None used as the base URL for some Javascript - set this to a URL on same server as the wiki if your url_prefix_static points to a different server.
url_prefix_static '/moin_static1911' used as the base URL for icons, css, etc. - includes the moin version number and changes on every release. This replaces the deprecated and sometimes confusing url_prefix = '/wiki' setting.

User Preferences related

Variable name Default Description
email_subscribed_events_default ...
jabber_subscribed_events_default []
quicklinks_default [] List of preset quicklinks for a newly created user accounts. Existing accounts are not affected by this option whereas changes in navi_bar do always affect existing accounts. Preset quicklinks can be removed by the user in the user preferences menu, navi_bar settings not.
subscribed_pages_default [] List of pagenames used for presetting page subscriptions for newly created user accounts.
tz_offset 0.0 default time zone offset in hours from UTC
userprefs_disabled [] Disable the listed user preferences plugins.

Users / User settings

Variable name Default Description
user_checkbox_defaults ... Defaults for user preferences, see HelpOnConfiguration/UserPreferences.
user_checkbox_disable [] Disable user preferences, see HelpOnConfiguration/UserPreferences.
user_checkbox_fields ... Describes user preferences, see HelpOnConfiguration/UserPreferences.
user_checkbox_remove [] Remove user preferences, see HelpOnConfiguration/UserPreferences.
user_email_unique True if True, check email addresses for uniqueness and don't accept duplicates.
user_form_defaults ...
user_form_disable [] list of field names used to disable user preferences form fields
user_form_fields ...
user_form_remove [] list of field names used to remove user preferences form fields
user_homewiki u'Self' interwiki name of the wiki where the user home pages are located [Unicode] - useful if you have many users. You could even link to nonwiki "user pages" if the wiki username is in the target URL.
user_jid_unique True if True, check Jabber IDs for uniqueness and don't accept duplicates.
user_transient_fields ... User object attributes that are not persisted to permanent storage (internal use).

Various

Variable name Default Description
bang_meta True if True, enable !NoWikiName markup
caching_formats ['text_html'] output formats that are cached; set to [] to turn off caching (useful for development)
config_check_enabled False if True, check configuration for unknown settings.
default_markup 'wiki' Default page parser / format (name of module in MoinMoin.parser)
html_head '' Additional <HEAD> tags, see HelpOnThemes.
html_head_index ... Additional <HEAD> tags for some few index pages.
html_head_normal ... Additional <HEAD> tags for most normal pages.
html_head_posts ... Additional <HEAD> tags for POST requests.
html_head_queries ... Additional <HEAD> tags for requests with query strings, like actions.
language_default 'en' Default language for user interface and page content, see HelpOnLanguages.
language_ignore_browser False if True, ignore user's browser language settings, see HelpOnLanguages.
log_events_format 1 0 = no events logging, 1 = standard format (like <= 1.9.7) [default], 2 = extended format
log_remote_addr True if True, log the remote IP address (and maybe hostname).
log_reverse_dns_lookups False if True, do a reverse DNS lookup on page SAVE.
log_timing False if True, add timing infos to the log output to analyse load conditions
mimetypes_embed ... mimetypes that can be embedded by the EmbedObject macro
mimetypes_xss_protect ... "content-disposition: inline" isn't used for them when a user downloads such attachments
refresh None refresh = (minimum_delay_s, targets_allowed) enables use of #refresh 5 PageName processing instruction, targets_allowed must be either 'internal' or 'external'
rss_cache 60 suggested caching time for RecentChanges RSS, in second
search_results_per_page 25 Number of hits shown per page in the search results
siteid 'default'
xmlrpc_overwrite_user True Overwrite authenticated user at start of xmlrpc code

Xapian search

Configuration of the Xapian based indexed search, see HelpOnXapian.

Variable name Default Description
xapian_index_dir None Directory where the Xapian search index is stored (None = auto-configure wiki local storage)
xapian_index_history False True to enable indexing of non-current page revisions.
xapian_search False True to enable the fast, indexed search (based on the Xapian search library)
xapian_stemming False True to enable Xapian word stemmer usage for indexing / searching.

Некоторые параметры могут быть заданы только в MoinMoin/config/__init__.py (являющемся частью кода сервера и, таким образом, влияющие на поведение всех экземпляров вики, его использующих), и не могут быть заданы в конфигурации отдельных вики — их стоит менять только в случае обоснованной необходимости для таковых действий:

Параметр

Значение по умолчанию

Описание

charset

'utf-8'

Кодировка, используемая вики
<!> Настоятельно не рекомендуется менять параметр config.charset. Это не тестировалось и ни коим образом не поддерживается.

lowerletters

ucs-2 lowercase letters

Символы, считающиеся строчными буквами, используются для определения ВикиИмени.

smileys

[...]

Список графических иконок, поддерживаемых МойнМойн — изображения и их размеры задаются в коде темы.

umask

0770

umask, используемая МойнМойн. Значение по умолчанию предоставляет права владельцу и группе, но не другим.

upperletters

ucs-2 uppercase letters

Символы, считающиеся заглавными буквами, используются для определения ВикиИмени.

url_schemas

['http', 'ftp', ...]

Протоколы URL, которые должны распознаваться в ссылках.

Ссылки