Sciology = Science + Technology

Commonsense in Technology

MoinMoin setup in easy steps

Posted by sureshkrishna on April 25, 2008

Wikis are a nice way to collaborate in an organizational environment. There are several wikis available in the market and thanks to the wikimatrix, which makes it easy to decide. Recently i did an exercise to install and upgrade the MoinMoin wiki. Listed are ALL the important steps that one can use to SUCCESSFULLY install and upgrade a wiki.

The infrastructure is a pretty simple. Windows XP, Apache Server, Intranet Environment, Latest Python and MoinMoin. I hope the following steps are very simple and enables everyone installing on Win XP and Apache to have a smooth setup process.

Note : This is not meant to have comprehensive setup instructions. For full help and installation instructions please look into the http://www.moinmo.in

Pre-Requisites

  • Download latest MoinMoin [http://www.moinmo.in/MoinMoinDownload]
  • Download latest UnZip/Zip SW [http://www.rarlab.com/download.htm]
  • Download latest Python [http://www.python.org]
  • Download latest EditPlus [http://www.editplus.com]
  • Download latest Apache Server [http://httpd.apache.org/download.cgi]

Example Paths

  • Python Installation : C:\WikiSetup\Python252
  • MoinMoin Installation : C:\WikiSetup\moin-1.6.3
  • Utilities Instance : C:\WikiSetup\MyCompanyMoinMoin
  • MyWiki : C:\WikiSetup\MyCompanyMoinMoin\myCompanyWiki

Install Python

  • Install Python
  • Set the system path to Python.exe. This is not necessary, but helps you to execute python from everywhere.
  • Goto the cmd and type python. Python starts and shown the version.
    • python -V
    • Exit this by Ctrl+Z and then Enter key.

Install Apache Server

  • Make sure after the installation the server is started. This can be tested by launching the IE/FF/SF/.. and goto URL http://localhost. The browser should say “It Works!”.
  • If needed the server port can be changed to something that you like and safe. e.g. 1111, 2222 or 9999

Install MoinMoin

  • cd C:\WikiSetup\moin-1.6.3
  • python setup.py –quiet install –prefix=”C:\WikiSetup\MyCompanyMoinMoin” –record=install.log
  • Look for any errors in <C:\WikiSetup\moin-1.6.3\install.log>. If this has errors, go for a coffee and try again.
  • Wether the installation is successful or not can be checked as follows. On the command prompt type “python” and then “import MoinMoin”.
  • This should not produce any messages and it just comes out.
    • C:\WikiSetup\moin-1.6.3>python
    • Python 2.5.2 (r252:60911, Feb 21 2008, 13:11:45) [MSC v.1310 32 bit (Intel)] on win32
    • Type “help”, “copyright”, “credits” or “license” for more information.
    • >>> import MoinMoin
    • >>>
  • Note : It is not necessary to change ANY of the configuration or files from the original MoinMoin installation <C:\WikiSetup\moin-1.6.3>.
  • Change the file <C:\WikiSetup\MyCompanyMoinMoin\share\moin\server\moin.cgi> to insert the MoinMoin library path.
    • #!C:\WikiSetup\Python252\python.exe
  • Path of the directory where wikiconfig.py is located.
    • # YOU NEED TO CHANGE THIS TO MATCH YOUR SETUP.
    • # sys.path.insert(0, ‘/path/to/wikiconfig’)
    • sys.path.insert(0, r’C:/WikiSetup/MyCompanyMoinMoin/share/moin/config’);
    • # Path to MoinMoin package, needed if you installed with –prefix=PREFIX
    • # or if you did not use setup.py.
    • ## sys.path.insert(0, ‘PREFIX/lib/python2.3/site-packages’)
    • sys.path.insert(0, r’C:/WikiSetup/MyCompanyMoinMoin/Lib/site-packages’)

Create the myCompanyWiki Instance

  • Create the directory “myCompanyWiki” under C:\WikiSetup\MyCompanyMoinMoin
    • cd C:\WikiSetup\MyCompanyMoinMoin\share\moin
    • xcopy data C:\WikiSetup\MyCompanyMoinMoin\myCompanyWiki\data /E
    • xcopy underlay C:\WikiSetup\MyCompanyMoinMoin\myCompanyWiki\underlay /E
    • copy config\*.* C:\WikiSetup\MyCompanyMoinMoin\myCompanyWiki\*.*
    • copy server\*.* C:\WikiSetup\MyCompanyMoinMoin\myCompanyWiki\*.*
  • Configuring wikiconfig.py
    • sitename = u’My Company Wiki’
    • logo_string = u'<img src=”/wiki/common/mycompany.png” alt=”My Company Logo”>’
    • page_front_page = u”FrontPage”
    • data_dir = ‘C:/WikiSetup/MyCompanyMoinMoin/myCompanyWiki/data’
    • data_underlay_dir = ‘C:/WikiSetup/MyCompanyMoinMoin/myCompanyWiki/underlay’
    • url_prefix_static = ‘/wiki’
    • allowed_actions = [‘DeletePage’, ‘AttachFile’, ‘RenamePage’, ]
    • # If you will not be running a Wiki farm (if you’re not sure what this means, then you probably won’t be), make sure to delete the farmconfig.py file from the C:\Moin\mywiki directory, or else moin.cgi will most likely give off various errors (including one about not being able to find a configuration file) and will ultimately fail to start up properly
  • Configuring moin.cgi. Change the moin.cgi to contain the following lines of script.
    • #!C:\WikiSetup\Python252\python.exe
    • sys.path.insert(0, r’C:/WikiSetup/MyCompanyMoinMoin/myCompanyWiki’);
    • sys.path.insert(0, r’C:/WikiSetup/MyCompanyMoinMoin/Lib/site-packages’)
  • Configuring Apache httpd.conf. Add exactly as shown below. Nothing more nothing less.
    • Its common to have the 80 port already ruinning. Or in some of the corporates this is taken by the Anti-Virus programs. So i would suggest to have your own port for Wiki.
    • Listen xxx.xxx.xxx.xxx:1234
    • The Alias is used to point all the static content like, images, css etc…
    • Alias /wiki/ “C:/WikiSetup/MyCompanyMoinMoin/share/moin/htdocs/”
    • Script Alias points to the newly created Wiki Instance. This kicks up the entire Wiki as i understand.
    • ScriptAlias /myCompanyWiki “C:/WikiSetup/MyCompanyMoinMoin/myCompanyWiki/moin.cgi”
    • Following directories need to accessible by the server
    • <Directory “C:/WikiSetup/MyCompanyMoinMoin/share/moin/htdocs/”>
      • AllowOverride None
      • Options None
      • Order allow,deny
      • Allow from all
    • </Directory>
    • <Directory “C:/WikiSetup/MyCompanyMoinMoin/myCompanyWiki/”>
      • AllowOverride None
      • Options None
      • Order allow,deny
      • Allow from all
    • </Directory>
  • Add following css content in C:\WikiSetup\MyCompanyMoinMoin\share\moin\htdocs\modern\css. This might help you to have some kind of good looking headers. Of course you can change this style if you dont like.
    • h1, h2, h3, h4, h5, h6 {
      • background-color:#E7E7E7;
      • border-style:none;
      • border-width:thin;
      • font-family:sans-serif;
      • margin-bottom:8pt;
      • margin-top:2pt;
      • font-size:150%;
      • padding-left:0.4%;
      • width:99.6%;
    • }

Check Wiki Instance

Data Migraiton :

Data migration might be necessary, if you have existing wiki and you would want to enhance the wiki engine and data. Sometimes this could be the most painful process in the entire wiki setup (at least for me).

  • # Before doing the migration, please check if the MoinMoin module is available to command prompt.
  • # Copy the data directory from the existing wiki installation.
  • ‘your\old\MoinMoin\Wiki\data’ to C:\WikiSetup\MyCompanyMoinMoin\Lib\site-packages\MoinMoin\script\old\migration
  • # And start running all the scripts. All means ALL. If you encounter any errors make sure that you correct all of them.
  • # Migrate Post 5.3 Data :
  • C:\WikiSetup\MyCompanyMoinMoin\Lib\site-packages\MoinMoin\script\moin.py –config-dir=C:\WikiSetup\MyCompanyMoinMoin\myCompanyWiki –wiki-url=http://xxx.xxx.xxx.xxx:1234/myCompanyWiki/ migration data

HTML Dump

Many a times we want to export some of the pages or all of the wiki pages as documentation to the developers, sales or to the customers. This HTML Dump works handy in these cases. This feature is a fresh breath in life (i was using MoinMoin 1.2.1 before i migrated).

  • C:\WikiSetup\MyCompanyMoinMoin\Lib\site-packages\MoinMoin\script\moin.py –config-dir=C:\tmp\MOINWIKI\share\moin\matrix –wiki-url=http://xxx.xxx.xxx.xxx:1234/myCompanyWiki/ export dump –target-dir=C:\tmp\myWikiDataDump
  • Once the Dump is done. Copy the *.* from “C:/WikiSetup/MyCompanyMoinMoin/share/moin/htdocs” to “C:\tmp\myWikiDataDump“. This would apply all the “css” to the htmls.

User Access Control

The Wiki i setup, works in an intranet. I would like to have all the users to have the read, write, revert and delete access. Only the SuperUser has the admin capability. So my configuration is as follows.

  • superuser = [u”sureshkrishna”, ]
  • acl_rights_before = u”sureshkrishna:read,write,delete,revert,admin”
  • acl_rights_default = u”All:read,write,delete,revert”

References:

Advertisements

19 Responses to “MoinMoin setup in easy steps”

  1. Ravi said

    Recently i got some XML content converted to wiki format. However i am finding it difficult to host it on moinmoin. Can you help me on this??

  2. Dancing Agency London…

    […]MoinMoin setup in easy steps « Sciology = Science + Technology[…]…

  3. What is the Best Diet for YOU?…

    […]MoinMoin setup in easy steps « Sciology = Science + Technology[…]…

  4. Watch Saturday Night Live – Season 37, Episode 7: Jason Segel/Florence + The Machine…

    […]MoinMoin setup in easy steps « Sciology = Science + Technology[…]…

  5. Magnet Motor Blueprints…

    […]MoinMoin setup in easy steps « Sciology = Science + Technology[…]…

  6. These are genuinely impressive ideas in about blogging.

    You have touched some fastidious factors here. Any way keep up wrinting.

  7. When some one searches for his essential thing, thus he/she desires to be available that in
    detail, therefore that thing is maintained over here.

  8. Hi there are using WordPress for your site platform?
    I’m new to the blog world but I’m trying to get started and create my
    own. Do you require any coding expertise to
    make your own blog? Any help would be really appreciated!

  9. Melisa said

    Very nice post. I just stumbled upon your weblog and wanted
    to say that I’ve really enjoyed browsing your blog posts. In any case I’ll be subscribing to
    your rss feed and I hope you write again soon!

  10. Joan said

    Right now it sounds like Movable Type is the top blogging platform available
    right now. (from what I’ve read) Is that what you’re using on
    your blog?

  11. Hey there. I was thinking of adding a website link back to your
    site since both of our sites are centered around the same topic.
    Would you prefer I link to you using your site address: http://sureshkrishna.
    wordpress.com/2008/04/25/moinmoin-setup-made-simple/
    or web site title: MoinMoin setup in easy steps Sciology =
    Science + Technology. Please let me know at your earliest
    convenience. Cheers

  12. Yankee dexter missouri subwaySeptember 26, 2011 Come Meet Stanley Seagull While He’s Visitingby Cynthia LayStanley Seagull is on tour for the whole weekend. Associated Press writers David Sharp in Portland, Maine; Clarke Canfield in Alfred, Maine; Clarke Canfield in Alfred, Maine; and Kathy McCormack in Concord, N. Angelia was the Texas newspaper reporter who broke the dexter missouri subway Texas UFO sightings case, and intimidation of a key witness who saw the UFO in daylight click here for another article.

  13. Hi there are using WordPress for your site platform?
    I’m new to the blog world but I’m trying to get started and create my
    own. Do you require any html coding expertise to make your own blog?

    Any help would be greatly appreciated!

  14. Your Minecraft mods will be able to get you awesome things to think about as you look to what it means to
    use the mods in the right setting. To make one, first lay some wool blocks on the ground (two by four will make
    a twin size). It’ll result in the computer using only half the computer power and generate half the heat.

  15. If you want a Premium Minecraft Account check out this generator.
    With it you can generate a unique Minecraft Premium Account which no one else has!
    You can Download the Free Premium Minecraft Account Generator http:
    //MINECRAFTFREEDL.TK

    I do not even know how I ended up here, but I thought this post was great.
    I do not know who you are but definitely you’re going to a famous blogger if you aren’t already
    😉 Cheers!

  16. Anonymous said

    I love to share knowledge that will I’ve accrued through the calendar year to assist improve team efficiency.

  17. Giordano is a person of the foremost international men’s apparel and components brand. If you want to glimpse for baggage within a selected price range variety then you can opt for the pricing categories. Ones extravagance designer again pack demands to be a adequate dimension that can help you to consider your very own software devoid of the have to have to periods the software whilst mounted in the purse.

  18. I like to disseminate understanding that I
    have accrued with the yr to help improve group functionality.

  19. Eric Gonchar

    MoinMoin setup in easy steps « Sciology = Science + Technology

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

 
%d bloggers like this: