|
|
4c79b5 |
#!/bin/bash
|
|
|
4c79b5 |
# moinmoin-postinstall.sh
|
|
|
4c79b5 |
# MoinMoin 1.5 wikifarm instance installation script.
|
|
|
4c79b5 |
#
|
|
|
4c79b5 |
# The CentOS Artwork SIG.
|
|
|
4c79b5 |
# http://wiki.centos.org/ArtWork
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# ---------------------------------------------------------
|
|
|
4c79b5 |
# Begin Configuration Section
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# title bar.
|
|
|
4c79b5 |
WIKISITENAME="mywiki"
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
MYDOMAIN="localdomain"
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
WIKIFRONTPAGE="FrontPage"
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
WIKILOCATION=/var/www/
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# Instance Name.
|
|
|
4c79b5 |
WIKIINSTANCE="wikifarm"
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# Alias name used to access wiki static files. This value
|
|
|
4c79b5 |
# should be different from $WIKIALIAS above.
|
|
|
4c79b5 |
WIKIURLPREFIX="staticfiles"
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
WIKISUPERUSER="YourName"
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
#
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
#
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# Login > UserPreferences > Create Profile
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# 3. Add registered user names into EditGroup page.
|
|
|
4c79b5 |
#
|
|
|
4c79b5 |
# At this point those users listed in EditGroup will
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# grant admin rights to other people then create the
|
|
|
4c79b5 |
# AdminGroup page and add register users names into
|
|
|
4c79b5 |
|
|
|
4c79b5 |
#
|
|
|
4c79b5 |
# More info about acl can be found at
|
|
|
4c79b5 |
# http://localhost/wiki/HelpOnAccessControlLists once
|
|
|
4c79b5 |
|
|
|
4c79b5 |
#
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
WIKIRESTRICTEDIT="no"
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# Mail
|
|
|
4c79b5 |
WIKIMAILSMARTHOST=""
|
|
|
4c79b5 |
WIKIMAILFROM=""
|
|
|
4c79b5 |
WIKIMAILLOGIN=""
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# Language.
|
|
|
4c79b5 |
WIKILANGUAGE="en"
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# Basic installation Prefix.
|
|
|
4c79b5 |
PREFIX=/usr
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# Share directory name.
|
|
|
4c79b5 |
SHARE=$PREFIX/share/moin/
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
USER=apache
|
|
|
4c79b5 |
GROUP=$USER
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# End of Configuration section
|
|
|
4c79b5 |
# ---------------------------------------------------------
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# Copy files
|
|
|
4c79b5 |
#
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# instance.
|
|
|
4c79b5 |
#
|
|
|
4c79b5 |
cd $WIKILOCATION
|
|
|
4c79b5 |
mkdir -p ${WIKIINSTANCE}/cgi-bin/
|
|
|
4c79b5 |
mkdir -p ${WIKIINSTANCE}/${WIKISITENAME}.${MYDOMAIN}/
|
|
|
4c79b5 |
cp -r ${SHARE}data/* ${WIKIINSTANCE}/${WIKISITENAME}.${MYDOMAIN}/
|
|
|
4c79b5 |
cp -r ${SHARE}data ${WIKIINSTANCE}/
|
|
|
4c79b5 |
cp -r ${SHARE}htdocs $WIKIINSTANCE
|
|
|
4c79b5 |
cp -r ${SHARE}underlay $WIKIINSTANCE
|
|
|
4c79b5 |
cp ${SHARE}server/moin.cgi ${WIKIINSTANCE}/cgi-bin/
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# Fix PATH in moin.cgi file
|
|
|
4c79b5 |
#
|
|
|
4c79b5 |
sed -i -e "
|
|
|
4c79b5 |
s/\/path\/to\/wikiconfig/\/var\/www\/${WIKIINSTANCE}\/cgi-bin/
|
|
|
4c79b5 |
s/\/path\/to\/farmconfig/\/var\/www\/${WIKIINSTANCE}\/cgi-bin\/farmconfig/
|
|
|
4c79b5 |
" ${WIKILOCATION}${WIKIINSTANCE}/cgi-bin/moin.cgi
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# Apache Configuration
|
|
|
4c79b5 |
#
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# default.
|
|
|
4c79b5 |
cat <<APACHECONF > /etc/httpd/conf.d/${WIKIINSTANCE}.conf
|
|
|
4c79b5 |
# Apache web server configuration for MoinMoin wiki.
|
|
|
4c79b5 |
#
|
|
|
4c79b5 |
# Created by moinmoin-postinstall-wikifarm.sh.
|
|
|
4c79b5 |
|
|
|
4c79b5 |
<VirtualHost *:80>
|
|
|
4c79b5 |
ServerName ${WIKISITENAME}.${MYDOMAIN}/
|
|
|
4c79b5 |
ServerAdmin webmaster@${MYDOMAIN}
|
|
|
4c79b5 |
ErrorLog logs/wiki-${WIKISITENAME}.error_log
|
|
|
4c79b5 |
CustomLog logs/wiki-${WIKISITENAME}.access_log common
|
|
|
4c79b5 |
Alias /${WIKIURLPREFIX} "${WIKILOCATION}${WIKIINSTANCE}/htdocs/"
|
|
|
4c79b5 |
Alias /favicon.ico "${WIKILOCATION}${WIKIINSTANCE}/favicon.ico"
|
|
|
4c79b5 |
ScriptAlias / "${WIKILOCATION}${WIKIINSTANCE}/cgi-bin/moin.cgi/"
|
|
|
4c79b5 |
</VirtualHost>
|
|
|
4c79b5 |
APACHECONF
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# MoinMoin Configuration - farmconfig.py
|
|
|
4c79b5 |
#
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# in the moin-1.5.7-1.el5.rf package. Some additions were
|
|
|
4c79b5 |
# included in the secutiry section to make it configurablen
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# EditGroup, and AdminGroup editable wiki.
|
|
|
4c79b5 |
cat <<WIKICONFIG > ${WIKIINSTANCE}/cgi-bin/farmconfig.py
|
|
|
4c79b5 |
# -*- coding: iso-8859-1 -*-
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
"""
|
|
|
4c79b5 |
MoinMoin - Configuration for a wiki farm
|
|
|
4c79b5 |
|
|
|
4c79b5 |
If you run a single wiki only, you can keep the "wikis" list "as is"
|
|
|
4c79b5 |
(it has a single rule mapping all requests to mywiki.py).
|
|
|
4c79b5 |
|
|
|
4c79b5 |
Note that there are more config options than you'll find in
|
|
|
4c79b5 |
the version of this file that is installed by default; see
|
|
|
4c79b5 |
the module MoinMoin.multiconfig for a full list of names and their
|
|
|
4c79b5 |
default values.
|
|
|
4c79b5 |
|
|
|
4c79b5 |
Also, the URL http:
|
|
|
4c79b5 |
a list of config options.
|
|
|
4c79b5 |
"""
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# Wikis in your farm --------------------------------------------------
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# Then it loads the <wikiname>.py config for handling that request.
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# Important:
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# lower letters "a-z" and "_". Do not use blanks or "-" there!!!
|
|
|
4c79b5 |
# * the right part is the url re, use r"..." for it
|
|
|
4c79b5 |
# * the right part does NOT include "http://" nor "https://" at the beginning
|
|
|
4c79b5 |
# * in the right part ".*" means "everything". Just "*" does not work like
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# * in the right part, "^" means "beginning" and "$" means "end"
|
|
|
4c79b5 |
|
|
|
4c79b5 |
wikis = [
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
#("mywiki", r".*"), # this is ok for a single wiki
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
#("moinmoin", r"^moinmoin.wikiwikiweb.de/.*$"),
|
|
|
4c79b5 |
#("moinmaster", r"^moinmaster.wikiwikiweb.de/.*$"),
|
|
|
4c79b5 |
|
|
|
4c79b5 |
("${WIKISITENAME}", r"^${WIKISITENAME}.${MYDOMAIN}/.*$"),
|
|
|
4c79b5 |
]
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# Common configuration for all wikis ----------------------------------
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# config.
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
#
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
from MoinMoin.multiconfig import DefaultConfig
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# Now we subclass this DefaultConfig. This means that we inherit every setting
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
class FarmConfig(DefaultConfig):
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# If you encounter problems, try to set data_dir and data_underlay_dir
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
data_underlay_dir = '${WIKILOCATION}${WIKIINSTANCE}/underlay/'
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# same for invoking moin.cgi (or, in general, the moin code).
|
|
|
4c79b5 |
# url_prefix must be '/wiki' for Twisted and standalone servers.
|
|
|
4c79b5 |
|
|
|
4c79b5 |
url_prefix = '/${WIKIURLPREFIX}'
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
#superuser = [u"${WIKISUPERUSER}", ]
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
#acl_rights_default = u"All:read"
|
|
|
4c79b5 |
#acl_rights_before = u"${WIKISUPERUSER}:read,write,delete,revert,admin" \\
|
|
|
4c79b5 |
# u"AdminGroup:read,write,delete,revert,admin" \\
|
|
|
4c79b5 |
# u"EditGroup:read,write,delete,revert"
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
#from MoinMoin.util.antispam import SecurityPolicy
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# SMTP server, e.g. "mail.provider.com" (None to disable mail)
|
|
|
4c79b5 |
#mail_smarthost = "${WIKIMAILSMARTHOST}"
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# The return address, e.g u"Jürgen Wiki <noreply@mywiki.org>" [Unicode]
|
|
|
4c79b5 |
#mail_from = u"${WIKIMAILFROM}"
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
#mail_login = "${WIKIMAILLOGIN}"
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
navi_bar = [
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
u'RecentChanges',
|
|
|
4c79b5 |
u'FindPage',
|
|
|
4c79b5 |
u'HelpContents',
|
|
|
4c79b5 |
]
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
page_category_regex = u'^Category[A-Z]'
|
|
|
4c79b5 |
page_dict_regex = u'[a-z]Dict$'
|
|
|
4c79b5 |
page_group_regex = u'[a-z]Group$'
|
|
|
4c79b5 |
page_template_regex = u'[a-z]Template$'
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
show_hosts = 1
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
show_interwiki = 1
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
#chart_options = {'width': 600, 'height': 300}
|
|
|
4c79b5 |
WIKICONFIG
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# Copy First Wiki Configuration file.
|
|
|
4c79b5 |
#
|
|
|
4c79b5 |
cat <<WIKICONFIG > ${WIKIINSTANCE}/cgi-bin/${WIKISITENAME}.py
|
|
|
4c79b5 |
# -*- coding: iso-8859-1 -*-
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
"""
|
|
|
4c79b5 |
This is a sample config for a wiki that is part of a wiki farm and uses
|
|
|
4c79b5 |
farmconfig for common stuff. Here we define what has to be different from
|
|
|
4c79b5 |
the farm's common settings.
|
|
|
4c79b5 |
"""
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# we import the FarmConfig class for common defaults of our wikis:
|
|
|
4c79b5 |
from farmconfig import FarmConfig
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# now we subclass that config (inherit from it) and change what's different:
|
|
|
4c79b5 |
class Config(FarmConfig):
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
sitename = u'${WIKISITENAME}'
|
|
|
4c79b5 |
interwikiname = '${WIKISITENAME}'
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
#page_front_page = u"MyStartingPage"
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# b) if wiki content is maintained in many languages
|
|
|
4c79b5 |
page_front_page = u"${WIKIFRONTPAGE}"
|
|
|
4c79b5 |
|
|
|
4c79b5 |
logo_string = u''
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# The default theme anonymous or new users get
|
|
|
4c79b5 |
theme_default = 'modern'
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# See http://moinmoin.wikiwikiweb.de/ConfigMarket for configuration in
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
language_default = '${WIKILANGUAGE}'
|
|
|
4c79b5 |
|
|
|
4c79b5 |
data_dir = '${WIKILOCATION}${WIKIINSTANCE}/${WIKISITENAME}.${MYDOMAIN}/'
|
|
|
4c79b5 |
WIKICONFIG
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# Uncomment some options in the farmconfig.py file if ...
|
|
|
4c79b5 |
if [ "$WIKISUPERUSER" != "" ]; then
|
|
|
4c79b5 |
|
|
|
4c79b5 |
sed -i -e '
|
|
|
4c79b5 |
/#superuser/s/
|
|
|
4c79b5 |
s/YourName/'$WIKISUPERUSER'/' ${WIKIINSTANCE}/cgi-bin/farmconfig.py
|
|
|
4c79b5 |
|
|
|
4c79b5 |
fi
|
|
|
4c79b5 |
|
|
|
4c79b5 |
if [ "$WIKIRESTRICTEDIT" = "yes" ]; then
|
|
|
4c79b5 |
|
|
|
4c79b5 |
sed -i -r -e '
|
|
|
4c79b5 |
/#acl_rights_before/s/
|
|
|
4c79b5 |
/#acl_rights_default/s/
|
|
|
4c79b5 |
/#[\t ]*u"EditGroup/s/
|
|
|
4c79b5 |
/#[\t ]*u"AdminGroup/s/
|
|
|
4c79b5 |
|
|
|
4c79b5 |
fi
|
|
|
4c79b5 |
|
|
|
4c79b5 |
if [ "$WIKIMAILSMARTHOST" != "" ]; then
|
|
|
4c79b5 |
|
|
|
4c79b5 |
sed -i -e '
|
|
|
4c79b5 |
/#mail_smarthost/s/
|
|
|
4c79b5 |
|
|
|
4c79b5 |
fi
|
|
|
4c79b5 |
|
|
|
4c79b5 |
if [ "$WIKIMAILFROM" != "" ];then
|
|
|
4c79b5 |
|
|
|
4c79b5 |
sed -i -e '
|
|
|
4c79b5 |
/#mail_from/s/
|
|
|
4c79b5 |
|
|
|
4c79b5 |
fi
|
|
|
4c79b5 |
|
|
|
4c79b5 |
if [ "$WIKIMAILLOGIN" != "" ];then
|
|
|
4c79b5 |
|
|
|
4c79b5 |
sed -i -e '
|
|
|
4c79b5 |
/#mail_login/s/
|
|
|
4c79b5 |
|
|
|
4c79b5 |
fi
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# File Permissions
|
|
|
4c79b5 |
#
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# files.
|
|
|
4c79b5 |
#
|
|
|
4c79b5 |
chown -R $USER.$GROUP $WIKIINSTANCE
|
|
|
4c79b5 |
chmod -R ug=rwx $WIKIINSTANCE
|
|
|
4c79b5 |
chmod -R o-rwx $WIKIINSTANCE
|
|
|
4c79b5 |
cd $WIKIINSTANCE
|
|
|
4c79b5 |
chown -R $USER.$GOUP cgi-bin
|
|
|
4c79b5 |
chmod -R ug=rx cgi-bin
|
|
|
4c79b5 |
chmod -R o-rwx cgi-bin
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
# Last Message
|
|
|
4c79b5 |
#
|
|
|
4c79b5 |
less <
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
*** WIKIFARM INSTANCE CREATED ***
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
To finish the installation do the following:
|
|
|
4c79b5 |
|
|
|
4c79b5 |
1. Restart the Web Server (service httpd restart)
|
|
|
4c79b5 |
|
|
|
4c79b5 |
2. Open your browser and try the address:
|
|
|
4c79b5 |
http://${WIKISITENAME}.${MYDOMAIN}/"
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
*** HOWTO CREATE NEW WIKIS ***
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
To create new wikis into the farm check the following
|
|
|
4c79b5 |
steps:
|
|
|
4c79b5 |
|
|
|
4c79b5 |
1. Update your farmconfig.py file adding the new
|
|
|
4c79b5 |
wiki definition. Ex.
|
|
|
4c79b5 |
|
|
|
4c79b5 |
("mywiki2", r"^mywiki2.${MYDOMAIN}/.*$"),
|
|
|
4c79b5 |
|
|
|
4c79b5 |
2. Create a directory to store your new wiki data.
|
|
|
4c79b5 |
Ex.
|
|
|
4c79b5 |
|
|
|
4c79b5 |
mkdir ${WIKILOCATION}${WIKIINSTANCE}/mywiki2.${MYDOMAIN}/
|
|
|
4c79b5 |
|
|
|
4c79b5 |
3. Copy the content of data directory into the
|
|
|
4c79b5 |
recently created directory. Ex.:
|
|
|
4c79b5 |
|
|
|
4c79b5 |
cp -rv ${WIKILOCATION}${WIKIINSTANCE}/data/* \\
|
|
|
4c79b5 |
${WIKILOCATION}${WIKIINSTANCE}/mywiki2.${MYDOMAIN}/
|
|
|
4c79b5 |
|
|
|
4c79b5 |
4. Create a copy of your cgi-bin/mywiki.py into
|
|
|
4c79b5 |
cgi-bin/mywiki2.py. Then modify mywiki2 with the new
|
|
|
4c79b5 |
and specific configuration, related to the second
|
|
|
4c79b5 |
wiki. Ex.:
|
|
|
4c79b5 |
|
|
|
4c79b5 |
sitename = u'mywiki2'
|
|
|
4c79b5 |
interwikiname = 'mywiki2'
|
|
|
4c79b5 |
data_dir = '/var/www/wikifarm/mywiki2.${MYDOMAIN}/'
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
*** GET TROUBLES ? ***
|
|
|
4c79b5 |
|
|
|
4c79b5 |
|
|
|
4c79b5 |
If you get some error when try to reach your wiki through
|
|
|
4c79b5 |
the web browser, check the following:
|
|
|
4c79b5 |
|
|
|
4c79b5 |
1. Add in your DNS or HOSTS file a record to your
|
|
|
4c79b5 |
wiki address. For example, if your domain is
|
|
|
4c79b5 |
${MYDOMAIN} and your wiki is in a host with the ip
|
|
|
4c79b5 |
192.168.0.1, and you want a wiki address like
|
|
|
4c79b5 |
http://${WIKISITENAME}.${MYDOMAIN}/ it is possible
|
|
|
4c79b5 |
that you should add a related CNAME record into your
|
|
|
4c79b5 |
DNS to your new wiki address, something like the
|
|
|
4c79b5 |
following:
|
|
|
4c79b5 |
|
|
|
4c79b5 |
${WIKISITENAME}.${MYDOMAIN}. IN CNAME ${MYDOMAINl}.
|
|
|
4c79b5 |
|
|
|
4c79b5 |
Remeber to do a 'service named restart' after
|
|
|
4c79b5 |
changes.
|
|
|
4c79b5 |
|
|
|
4c79b5 |
2. Check Virtual Domain configuration in your Apache
|
|
|
4c79b5 |
server. It is possible that it is disabled so enable
|
|
|
4c79b5 |
it by uncomenting a line like the following:
|
|
|
4c79b5 |
|
|
|
4c79b5 |
NameVirtualHost *:80
|
|
|
4c79b5 |
|
|
|
4c79b5 |
3. It is possible that you want something in
|
|
|
4c79b5 |
http:
|
|
|
4c79b5 |
sometimes appears there after you get your wiki
|
|
|
4c79b5 |
working into virtual domains. So you should create a
|
|
|
4c79b5 |
virtual domain for that address too and change the
|
|
|
4c79b5 |
DocumentoRoot param to wherever you want to load at
|
|
|
4c79b5 |
that moment.
|
|
|
4c79b5 |
|
|
|
4c79b5 |
If you are still in troubles, you can write to:
|
|
|
4c79b5 |
<alain.reguera@gmail.com>.
|
|
|
4c79b5 |
|
|
|
4c79b5 |
Other way ...
|
|
|
4c79b5 |
|
|
|
4c79b5 |
Enjoy your installed wikifarm :).
|
|
|
4c79b5 |
|
|
|
4c79b5 |
LASTMESSAGE
|