comparison docs/INSTALL.html @ 3599:2b734fe96f57 1.7.0beta2

1.7.0beta2 release (updated CHANGES, install-docs, interwiki, bumped version)
author Thomas Waldmann <tw AT waldmann-edv DOT de>
date Tue, 13 May 2008 01:51:32 +0200
parents 1e699674f73b
children 8ffe79f29100
comparison
equal deleted inserted replaced
3598:b7b205661352 3599:2b734fe96f57
50 <a href="#HelpOnInstalling.2BAC8-BasicInstallation.Installingtothedefaultsystemlocation">Installing to the default system location</a></li><li> 50 <a href="#HelpOnInstalling.2BAC8-BasicInstallation.Installingtothedefaultsystemlocation">Installing to the default system location</a></li><li>
51 <a href="#HelpOnInstalling.2BAC8-BasicInstallation.Installinginthehomedirectoryoranotherspecificlocation">Installing in the home directory or another specific location</a></li></ol></li><li> 51 <a href="#HelpOnInstalling.2BAC8-BasicInstallation.Installinginthehomedirectoryoranotherspecificlocation">Installing in the home directory or another specific location</a></li></ol></li><li>
52 <a href="#HelpOnInstalling.2BAC8-BasicInstallation.Testinstallation">Test installation</a></li><li> 52 <a href="#HelpOnInstalling.2BAC8-BasicInstallation.Testinstallation">Test installation</a></li><li>
53 <a href="#HelpOnInstalling.2BAC8-BasicInstallation.Whathasbeeninstalled">What has been installed</a></li></ol></div><p class="line874"> <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-14"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-15"></span><p class="line862">Before you can integrate Moin<tt class="backtick"></tt>Moin into your web environment, you have to install the <a href="http://master17.moinmo.in/MoinMoin">MoinMoin</a> source code and data files using the standard Python <em>distutils</em> mechanism (<tt class="backtick">setup.py</tt>). This page explains the steps you usually need to take to do this. For more details on the <em>distutils</em> installation process, consult the <a class="http" href="http://www.python.org/doc/current/inst/inst.html">Installing Python Modules</a> document in your Python documentation set. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-16"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-17"></span><p class="line874">The installation is similar on Windows and Linux (and other POSIX-type systems; for simplicity, we just say "Linux" in the docs). <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-18"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-19"></span><ul><li style="list-style-type:none"><p class="line891"><img alt="(!)" height="15" src="/moin_static170/modern/img/idea.png" title="(!)" width="15" /> We use text such as <strong><tt class="backtick">&gt;&nbsp;command&nbsp;arguments</tt></strong> to show what you have to type at the command prompt (also known as shell, terminal, etc.). In our examples "<tt class="backtick">&gt;&nbsp;</tt>" is the prompt, you don't have to type it in, you have to type what comes after it. Lines that do not begin with "<tt class="backtick">&gt;&nbsp;</tt>" are the answers to the commands you have typed. Read them carefully. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-20"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-21"></span></li></ul><p class="line867"> 53 <a href="#HelpOnInstalling.2BAC8-BasicInstallation.Whathasbeeninstalled">What has been installed</a></li></ol></div><p class="line874"> <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-14"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-15"></span><p class="line862">Before you can integrate Moin<tt class="backtick"></tt>Moin into your web environment, you have to install the <a href="http://master17.moinmo.in/MoinMoin">MoinMoin</a> source code and data files using the standard Python <em>distutils</em> mechanism (<tt class="backtick">setup.py</tt>). This page explains the steps you usually need to take to do this. For more details on the <em>distutils</em> installation process, consult the <a class="http" href="http://www.python.org/doc/current/inst/inst.html">Installing Python Modules</a> document in your Python documentation set. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-16"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-17"></span><p class="line874">The installation is similar on Windows and Linux (and other POSIX-type systems; for simplicity, we just say "Linux" in the docs). <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-18"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-19"></span><ul><li style="list-style-type:none"><p class="line891"><img alt="(!)" height="15" src="/moin_static170/modern/img/idea.png" title="(!)" width="15" /> We use text such as <strong><tt class="backtick">&gt;&nbsp;command&nbsp;arguments</tt></strong> to show what you have to type at the command prompt (also known as shell, terminal, etc.). In our examples "<tt class="backtick">&gt;&nbsp;</tt>" is the prompt, you don't have to type it in, you have to type what comes after it. Lines that do not begin with "<tt class="backtick">&gt;&nbsp;</tt>" are the answers to the commands you have typed. Read them carefully. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-20"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-21"></span></li></ul><p class="line867">
54 <h1 id="HelpOnInstalling.2BAC8-BasicInstallation.CheckifPythonisworking">Check if Python is working</h1> 54 <h1 id="HelpOnInstalling.2BAC8-BasicInstallation.CheckifPythonisworking">Check if Python is working</h1>
55 <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-22"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-23"></span><p class="line862">Moin<tt class="backtick"></tt>Moin needs Python to run, so the first step is to check if an usable version of Python is installed and correctly set-up. If this is not the case, you will have to fix that before you can proceed. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-24"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-25"></span><p class="line862">The <tt class="backtick">CHANGES</tt> file in the Moin<tt class="backtick"></tt>Moin archive mentions what versions are supported. Python 2.3 is the minimum requirement for Moin<tt class="backtick"></tt>Moin 1.5, but we suggest you use the latest Python release version. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-26"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-27"></span><p class="line862">You can download Python at <a class="http" href="http://www.python.org/download/">http://www.python.org/download/</a>. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-28"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-29"></span><p class="line862">If you are pretty sure an acceptable version of Python is installed but the commands below do not work, this may be because your Python files are not in the <em>search path</em>. Correctly setting the search path is outside the scope of this document; please ask for help on your favorite Python, Linux, or Windows discussion board. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-30"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-31"></span><p class="line874">If you have shell access, checking if Python is working is very simple. Just type the following command, and look at the result: <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-32"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-33"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-34"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-35"></span><pre>&gt; python -V 55 <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-22"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-23"></span><p class="line862">Moin<tt class="backtick"></tt>Moin needs Python to run, so the first step is to check if an usable version of Python is installed and correctly set-up. If this is not the case, you will have to fix that before you can proceed. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-24"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-25"></span><p class="line862">The <tt class="backtick">CHANGES</tt> file in the Moin<tt class="backtick"></tt>Moin archive mentions what versions are supported. Python 2.3 is the minimum requirement for Moin<tt class="backtick"></tt>Moin 1.7, but we suggest you use the latest Python release version. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-26"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-27"></span><p class="line862">You can download Python at <a class="http" href="http://www.python.org/download/">http://www.python.org/download/</a>. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-28"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-29"></span><p class="line862">If you are pretty sure an acceptable version of Python is installed but the commands below do not work, this may be because your Python files are not in the <em>search path</em>. Correctly setting the search path is outside the scope of this document; please ask for help on your favorite Python, Linux, or Windows discussion board. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-30"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-31"></span><p class="line874">If you have shell access, checking if Python is working is very simple. Just type the following command, and look at the result: <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-32"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-33"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-34"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-35"></span><pre>&gt; python -V
56 Python 2.4.3</pre><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-36"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-37"></span><p class="line862">If you don't have shell access, you can try using this <tt class="backtick">pythontest.cgi</tt> script (it assumes that you are using a Linux kind of webserver). Upload the script to your <tt class="backtick">cgi-bin</tt> directory, use <tt class="backtick">chmod&nbsp;a+rx&nbsp;pythontest.cgi</tt> (or a similar command in your FTP program) to make it executable, and invoke it using your web browser. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-38"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-39"></span><p class="line867"><object data="/HelpOnInstalling/BasicInstallation?action=AttachFile&amp;do=get&amp;target=pythontest.cgi" title="" type="application/octet-stream">pythontest.cgi</object> <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-40"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-41"></span><p class="line874">If it doesn't display "CGI scripts work", well, then CGI scripts don't work. If it doesn't show one or more Python version numbers, then Python is not correctly installed. In both cases, before you can proceed, you will have to get in touch with the administrator of the server so that the problems get corrected. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-42"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-43"></span><p class="line862">Also be sure to read <a href="http://master17.moinmo.in/HelpOnInstalling/ApacheOnLinuxFtp">../ApacheOnLinuxFtp</a> after you've completed the ../BasicInstallation illustrated here. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-44"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-45"></span><p class="line867"> 56 Python 2.4.4</pre><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-36"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-37"></span><p class="line862">If you don't have shell access, you can try using this <tt class="backtick">pythontest.cgi</tt> script (it assumes that you are using a Linux kind of webserver). Upload the script to your <tt class="backtick">cgi-bin</tt> directory, use <tt class="backtick">chmod&nbsp;a+rx&nbsp;pythontest.cgi</tt> (or a similar command in your FTP program) to make it executable, and invoke it using your web browser. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-38"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-39"></span><p class="line867"><object data="/HelpOnInstalling/BasicInstallation?action=AttachFile&amp;do=get&amp;target=pythontest.cgi" title="" type="application/octet-stream">pythontest.cgi</object> <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-40"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-41"></span><p class="line874">If it doesn't display "CGI scripts work", well, then CGI scripts don't work. If it doesn't show one or more Python version numbers, then Python is not correctly installed. In both cases, before you can proceed, you will have to get in touch with the administrator of the server so that the problems get corrected. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-42"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-43"></span><p class="line862">Also be sure to read <a href="http://master17.moinmo.in/HelpOnInstalling/ApacheOnLinuxFtp">../ApacheOnLinuxFtp</a> after you've completed the ../BasicInstallation illustrated here. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-44"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-45"></span><p class="line867">
57 <h1 id="HelpOnInstalling.2BAC8-BasicInstallation.DownloadMoinMoin">Download MoinMoin</h1> 57 <h1 id="HelpOnInstalling.2BAC8-BasicInstallation.DownloadMoinMoin">Download MoinMoin</h1>
58 <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-46"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-47"></span><p class="line862">To download the distribution archive, go to the <a class="http" href="http://moinmo.in/MoinMoinDownload">download page</a> and fetch the latest archive. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-48"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-49"></span><p class="line862">The next step is to unpack the distribution archive (which you have done already if you are reading this text from your hard drive). If you read this on the web, the distribution comes in a versioned <tt class="backtick">.tar.gz</tt> archive, which you can unpack as shown below. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-50"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-51"></span><ul><li>On Windows <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-52"></span><ul><li><p class="line862">You can use recent versions of programs like <a class="http" href="http://www.7-zip.org/">7-Zip</a>, Win<tt class="backtick"></tt>Zip, Win<tt class="backtick"></tt>Rar, and Win<tt class="backtick"></tt>Ace, which handle .tar.gz kind of archives. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-53"></span></li><li><p class="line862">At the command prompt, you can use <a class="http" href="http://gnuwin32.sourceforge.net/packages/gzip.htm">GNU gzip</a> and <a class="http" href="http://gnuwin32.sourceforge.net/packages/tar.htm">GNU tar</a> for Windows. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-54"></span></li></ul></li><li>On Linux <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-55"></span><ul><li>You can use your favorite file manager -- it should be able to unpack them. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-56"></span></li><li><p class="line862">At any shell prompt, you can use the <tt class="backtick">tar</tt> command. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-57"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-58"></span></li></ul></li></ul><p class="line862">The distribution archive will always unpack into a directory named <tt class="backtick">moin-&lt;version&gt;</tt>, for example <tt class="backtick">moin-1.6.0</tt>. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-59"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-60"></span><p class="line862">Here is how you would unpack the archive (using GNU tar) and enter the directory with the Moin<tt class="backtick"></tt>Moin files: <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-61"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-62"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-63"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-64"></span><pre>&gt; tar xzf moin-1.6.0.tar.gz 58 <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-46"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-47"></span><p class="line862">To download the distribution archive, go to the <a class="http" href="http://moinmo.in/MoinMoinDownload">download page</a> and fetch the latest archive. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-48"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-49"></span><p class="line862">The next step is to unpack the distribution archive (which you have done already if you are reading this text from your hard drive). If you read this on the web, the distribution comes in a versioned <tt class="backtick">.tar.gz</tt> archive, which you can unpack as shown below. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-50"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-51"></span><ul><li>On Windows <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-52"></span><ul><li><p class="line862">You can use recent versions of programs like <a class="http" href="http://www.7-zip.org/">7-Zip</a>, Win<tt class="backtick"></tt>Zip, Win<tt class="backtick"></tt>Rar, and Win<tt class="backtick"></tt>Ace, which handle .tar.gz kind of archives. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-53"></span></li><li><p class="line862">At the command prompt, you can use <a class="http" href="http://gnuwin32.sourceforge.net/packages/gzip.htm">GNU gzip</a> and <a class="http" href="http://gnuwin32.sourceforge.net/packages/tar.htm">GNU tar</a> for Windows. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-54"></span></li></ul></li><li>On Linux <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-55"></span><ul><li>You can use your favorite file manager -- it should be able to unpack them. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-56"></span></li><li><p class="line862">At any shell prompt, you can use the <tt class="backtick">tar</tt> command. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-57"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-58"></span></li></ul></li></ul><p class="line862">The distribution archive will always unpack into a directory named <tt class="backtick">moin-&lt;version&gt;</tt>, for example <tt class="backtick">moin-1.7.0</tt>. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-59"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-60"></span><p class="line862">Here is how you would unpack the archive (using GNU tar) and enter the directory with the Moin<tt class="backtick"></tt>Moin files: <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-61"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-62"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-63"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-64"></span><pre>&gt; tar xzf moin-1.7.0.tar.gz
59 &gt; cd moin-1.6.0</pre><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-65"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-66"></span><p class="line867"> 59 &gt; cd moin-1.7.0</pre><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-65"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-66"></span><p class="line867">
60 <h1 id="HelpOnInstalling.2BAC8-BasicInstallation.InstallMoinMoin">Install MoinMoin</h1> 60 <h1 id="HelpOnInstalling.2BAC8-BasicInstallation.InstallMoinMoin">Install MoinMoin</h1>
61 <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-67"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-68"></span><p class="line862">You can install Moin<tt class="backtick"></tt>Moin to either: <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-69"></span><ul><li>a system location (if you have the necessary rights to do that -- on Linux you need to be root) <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-70"></span></li><li><p class="line862">some specific location, like your home directory (Linux) or <tt class="backtick">C:\moin</tt> (Windows). <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-71"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-72"></span></li></ul><p class="line874">The installation to a system location is easier, so choose that if possible. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-73"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-74"></span><p class="line867"><img alt="/!\" height="15" src="/moin_static170/modern/img/alert.png" title="/!\" width="15" /> If you have several versions of Python installed, please use the same version for setup and for running the wiki. Usually, the latest Python version will get the best results. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-75"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-76"></span><p class="line867"> 61 <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-67"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-68"></span><p class="line862">You can install Moin<tt class="backtick"></tt>Moin to either: <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-69"></span><ul><li>a system location (if you have the necessary rights to do that -- on Linux you need to be root) <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-70"></span></li><li><p class="line862">some specific location, like your home directory (Linux) or <tt class="backtick">C:\moin</tt> (Windows). <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-71"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-72"></span></li></ul><p class="line874">The installation to a system location is easier, so choose that if possible. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-73"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-74"></span><p class="line867"><img alt="/!\" height="15" src="/moin_static170/modern/img/alert.png" title="/!\" width="15" /> If you have several versions of Python installed, please use the same version for setup and for running the wiki. Usually, the latest Python version will get the best results. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-75"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-76"></span><p class="line867">
62 <h2 id="HelpOnInstalling.2BAC8-BasicInstallation.RecommendedinstallationcommandforLinux.28andMacOsX.29">Recommended installation command for Linux (and MacOs X)</h2> 62 <h2 id="HelpOnInstalling.2BAC8-BasicInstallation.RecommendedinstallationcommandforLinux.28andMacOsX.29">Recommended installation command for Linux (and MacOs X)</h2>
63 <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-77"></span><p class="line862">As you have chosen to not use a preconfigured package for your system this time it is highly recommended that you do not install <a href="http://master17.moinmo.in/MoinMoin">MoinMoin</a> into the default location. This is because otherwise, if you later want to install a moin package of your distribution this will overwrite your existing installation. The most common path for your own installations is below <tt>/usr/local</tt> (this is called the PREFIX). A command that should be ok for most Linux distributions and also MacOS X is <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-78"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-79"></span><p class="line867"><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-80"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-81"></span><pre>&gt; python setup.py install --prefix='/usr/local' --record=install.log</pre><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-82"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-83"></span><p class="line862">This will install the shared files to '/usr/local/share/moin' and the moin code to <tt class="backtick">/usr/local/lib/python2.x/site-packages/MoinMoin/</tt>. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-84"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-85"></span><p class="line867"> 63 <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-77"></span><p class="line862">As you have chosen to not use a preconfigured package for your system this time it is highly recommended that you do not install <a href="http://master17.moinmo.in/MoinMoin">MoinMoin</a> into the default location. This is because otherwise, if you later want to install a moin package of your distribution this will overwrite your existing installation. The most common path for your own installations is below <tt>/usr/local</tt> (this is called the PREFIX). A command that should be ok for most Linux distributions and also MacOS X is <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-78"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-79"></span><p class="line867"><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-80"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-81"></span><pre>&gt; python setup.py install --prefix='/usr/local' --record=install.log</pre><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-82"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-83"></span><p class="line862">This will install the shared files to '/usr/local/share/moin' and the moin code to <tt class="backtick">/usr/local/lib/python2.x/site-packages/MoinMoin/</tt>. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-84"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-85"></span><p class="line867">
64 <h2 id="HelpOnInstalling.2BAC8-BasicInstallation.Debuggingsetupprocess">Debugging setup process</h2> 64 <h2 id="HelpOnInstalling.2BAC8-BasicInstallation.Debuggingsetupprocess">Debugging setup process</h2>
70 <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-123"></span><tt class="backtick">is&nbsp;not&nbsp;in&nbsp;Python's&nbsp;module&nbsp;search&nbsp;path&nbsp;(sys.path)&nbsp;--&nbsp;you'll</tt><br> 70 <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-123"></span><tt class="backtick">is&nbsp;not&nbsp;in&nbsp;Python's&nbsp;module&nbsp;search&nbsp;path&nbsp;(sys.path)&nbsp;--&nbsp;you'll</tt><br>
71 <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-124"></span><tt class="backtick">have&nbsp;to&nbsp;change&nbsp;the&nbsp;search&nbsp;path&nbsp;yourself</tt> <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-125"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-126"></span></li></ul><p class="line862">This means exactly what it says, you need to add your install directory to the search path of Python, or it won't find the Moin<tt class="backtick"></tt>Moin code. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-127"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-128"></span><p class="line862">For example, if you are running using a webserver and standard CGI, edit <tt class="backtick">moin.cgi</tt> and add your installation directory to the Python path, like this: <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-129"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-130"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-131"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-132"></span><pre>import sys 71 <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-124"></span><tt class="backtick">have&nbsp;to&nbsp;change&nbsp;the&nbsp;search&nbsp;path&nbsp;yourself</tt> <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-125"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-126"></span></li></ul><p class="line862">This means exactly what it says, you need to add your install directory to the search path of Python, or it won't find the Moin<tt class="backtick"></tt>Moin code. <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-127"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-128"></span><p class="line862">For example, if you are running using a webserver and standard CGI, edit <tt class="backtick">moin.cgi</tt> and add your installation directory to the Python path, like this: <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-129"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-130"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-131"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-132"></span><pre>import sys
72 sys.path.insert(0, 'C:/moin')</pre><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-133"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-134"></span><p class="line867"> 72 sys.path.insert(0, 'C:/moin')</pre><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-133"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-134"></span><p class="line867">
73 <h1 id="HelpOnInstalling.2BAC8-BasicInstallation.Testinstallation">Test installation</h1> 73 <h1 id="HelpOnInstalling.2BAC8-BasicInstallation.Testinstallation">Test installation</h1>
74 <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-135"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-136"></span><p class="line862">As a final step, if you have access to the shell or the command prompt, you can check that everything is correctly installed and ready to run. Start Python and type <tt class="backtick">import&nbsp;MoinMoin</tt>. Nothing should be displayed in response to this command. Example: <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-137"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-138"></span><p class="line867"><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-139"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-140"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-141"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-142"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-143"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-144"></span><pre>&gt; python 74 <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-135"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-136"></span><p class="line862">As a final step, if you have access to the shell or the command prompt, you can check that everything is correctly installed and ready to run. Start Python and type <tt class="backtick">import&nbsp;MoinMoin</tt>. Nothing should be displayed in response to this command. Example: <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-137"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-138"></span><p class="line867"><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-139"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-140"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-141"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-142"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-143"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-144"></span><pre>&gt; python
75 Python 2.4.3 (...) 75 Python 2.4.4 (...)
76 Type "help", "copyright", "credits" or "license" for more information. 76 Type "help", "copyright", "credits" or "license" for more information.
77 &gt;&gt;&gt; import MoinMoin 77 &gt;&gt;&gt; import MoinMoin
78 &gt;&gt;&gt;</pre><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-145"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-146"></span><p class="line874">If you get this instead: <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-147"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-148"></span><p class="line867"><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-149"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-150"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-151"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-152"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-153"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-154"></span><pre>&gt;&gt;&gt; import MoinMoin 78 &gt;&gt;&gt;</pre><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-145"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-146"></span><p class="line874">If you get this instead: <span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-147"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-148"></span><p class="line867"><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-149"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-150"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-151"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-152"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-153"></span><span class="anchor" id="HelpOnInstalling.2BAC8-BasicInstallation.line-154"></span><pre>&gt;&gt;&gt; import MoinMoin
79 Traceback (most recent call last): 79 Traceback (most recent call last):
80 File "&lt;stdin&gt;", line 1, in ? 80 File "&lt;stdin&gt;", line 1, in ?
513 <span class="anchor" id="HelpOnInstalling.2BAC8-TwistedWeb.line-64"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TwistedWeb.line-65"></span><p class="line862">On GNU/Linux, Mac OS X or another POSIX-like OS, copy <tt class="backtick">wiki/server/mointwisted</tt> to your wiki directory. You might want to adapt <tt class="backtick">PYTHONPATH</tt> and the path to <tt class="backtick">twistd</tt>. <span class="anchor" id="HelpOnInstalling.2BAC8-TwistedWeb.line-66"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TwistedWeb.line-67"></span><p class="line862">Start the server with <tt>./mointwisted&nbsp;start</tt> and test your wiki at <a class="http" href="http://localhost:8080/">http://localhost:8080/</a>. Stop the server with <tt>./mointwisted&nbsp;stop</tt>. <span class="anchor" id="HelpOnInstalling.2BAC8-TwistedWeb.line-68"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TwistedWeb.line-69"></span><p class="line862">For more options run <tt>./mointwisted</tt> without arguments. <span class="anchor" id="HelpOnInstalling.2BAC8-TwistedWeb.line-70"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TwistedWeb.line-71"></span><p class="line862">If you want to start the server via initscript make sure <tt>mointwisted</tt> finds <tt>montwisted.py</tt> on startup! <span class="anchor" id="HelpOnInstalling.2BAC8-TwistedWeb.line-72"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TwistedWeb.line-73"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TwistedWeb.line-74"></span><p class="line867"> 513 <span class="anchor" id="HelpOnInstalling.2BAC8-TwistedWeb.line-64"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TwistedWeb.line-65"></span><p class="line862">On GNU/Linux, Mac OS X or another POSIX-like OS, copy <tt class="backtick">wiki/server/mointwisted</tt> to your wiki directory. You might want to adapt <tt class="backtick">PYTHONPATH</tt> and the path to <tt class="backtick">twistd</tt>. <span class="anchor" id="HelpOnInstalling.2BAC8-TwistedWeb.line-66"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TwistedWeb.line-67"></span><p class="line862">Start the server with <tt>./mointwisted&nbsp;start</tt> and test your wiki at <a class="http" href="http://localhost:8080/">http://localhost:8080/</a>. Stop the server with <tt>./mointwisted&nbsp;stop</tt>. <span class="anchor" id="HelpOnInstalling.2BAC8-TwistedWeb.line-68"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TwistedWeb.line-69"></span><p class="line862">For more options run <tt>./mointwisted</tt> without arguments. <span class="anchor" id="HelpOnInstalling.2BAC8-TwistedWeb.line-70"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TwistedWeb.line-71"></span><p class="line862">If you want to start the server via initscript make sure <tt>mointwisted</tt> finds <tt>montwisted.py</tt> on startup! <span class="anchor" id="HelpOnInstalling.2BAC8-TwistedWeb.line-72"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TwistedWeb.line-73"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TwistedWeb.line-74"></span><p class="line867">
514 <h3 id="HelpOnInstalling.2BAC8-TwistedWeb.onWindows">on Windows</h3> 514 <h3 id="HelpOnInstalling.2BAC8-TwistedWeb.onWindows">on Windows</h3>
515 <span class="anchor" id="HelpOnInstalling.2BAC8-TwistedWeb.line-75"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TwistedWeb.line-76"></span><p class="line862">Copy <tt class="backtick">wiki/server/mointwisted.cmd</tt> to your wiki directory. You might have to change the path pointing to the python-scripts directory. <span class="anchor" id="HelpOnInstalling.2BAC8-TwistedWeb.line-77"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TwistedWeb.line-78"></span><p class="line862">Double click <tt class="backtick">mointwisted.cmd</tt> to start the server. It will create a new terminal window. To stop the server, close the terminal window. <span class="anchor" id="HelpOnInstalling.2BAC8-TwistedWeb.line-79"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TwistedWeb.bottom"></span></div> <span class="anchor" id="line-63"></span><hr class="hr2" /><p class="line874"> <span class="anchor" id="line-64"></span><span class="anchor" id="linuxstandalone-install"></span> <span class="anchor" id="line-65"></span> 515 <span class="anchor" id="HelpOnInstalling.2BAC8-TwistedWeb.line-75"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TwistedWeb.line-76"></span><p class="line862">Copy <tt class="backtick">wiki/server/mointwisted.cmd</tt> to your wiki directory. You might have to change the path pointing to the python-scripts directory. <span class="anchor" id="HelpOnInstalling.2BAC8-TwistedWeb.line-77"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TwistedWeb.line-78"></span><p class="line862">Double click <tt class="backtick">mointwisted.cmd</tt> to start the server. It will create a new terminal window. To stop the server, close the terminal window. <span class="anchor" id="HelpOnInstalling.2BAC8-TwistedWeb.line-79"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TwistedWeb.bottom"></span></div> <span class="anchor" id="line-63"></span><hr class="hr2" /><p class="line874"> <span class="anchor" id="line-64"></span><span class="anchor" id="linuxstandalone-install"></span> <span class="anchor" id="line-65"></span>
516 <h1>Linux Installation using standalone server</h1> 516 <h1>Linux Installation using standalone server</h1>
517 <div dir="ltr" id="HelpOnInstalling.2BAC8-StandaloneServer.content" lang="en"><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.top"></span> 517 <div dir="ltr" id="HelpOnInstalling.2BAC8-StandaloneServer.content" lang="en"><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.top"></span>
518 <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-9"></span><p class="line867"><strong>Installing and configuring standalone server</strong> <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-10"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-11"></span><p class="line862">See also: <a href="http://master17.moinmo.in/HelpOnConfiguration/IntegratingWithApache">HelpOnConfiguration/IntegratingWithApache</a> <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-12"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-13"></span><p class="line874">The standalone server is especially made for local wikis because it does not need a web server installed. Only Python and Moin are necessary! <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-14"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-15"></span><p class="line874">To install and run the standalone server: <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-16"></span><ol type="1"><li><p class="line862">If <a href="http://master17.moinmo.in/MoinMoin">MoinMoin</a> is not installed yet, perform <a href="http://master17.moinmo.in/HelpOnInstalling/BasicInstallation">../BasicInstallation</a> <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-17"></span></li><li><p class="line862">Create a wiki instance as described in <a href="http://master17.moinmo.in/HelpOnInstalling/WikiInstanceCreation">../WikiInstanceCreation</a> <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-18"></span></li><li><p class="line862">Copy <tt>moin.py</tt> to your wiki directory, where your <tt>wikiconfig.py</tt> is <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-19"></span></li><li><p class="line862">If you installed with <tt class="backtick">--prefix</tt> option, you must edit moin.py and set <tt class="backtick">docs</tt> to the correct path. <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-20"></span></li><li><p class="line862">Run <tt>moin.py</tt> <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-21"></span></li><li><p class="line862">Access your wiki at <a class="http" href="http://localhost:8000/">http://localhost:8000/</a> <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-22"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-23"></span></li></ol><p class="line862">On most cases, the default settings will be just fine. You may want to edit <tt>moin.py</tt> and change some of the options, as described in the next section. <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-24"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-25"></span><p class="line867"> 518 <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-9"></span><p class="line867"><strong>Installing and configuring standalone server</strong> <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-10"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-11"></span><p class="line862">See also: <a href="http://master17.moinmo.in/HelpOnConfiguration/IntegratingWithApache">HelpOnConfiguration/IntegratingWithApache</a> <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-12"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-13"></span><p class="line874">The standalone server is especially made for local wikis because it does not need a web server installed. Only Python and Moin are necessary! <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-14"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-15"></span><p class="line867">
519 <h1 id="HelpOnInstalling.2BAC8-StandaloneServer.Configuringmoin.py">Configuring moin.py</h1> 519 <h1 id="HelpOnInstalling.2BAC8-StandaloneServer.Thequickway">The quick way</h1>
520 <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-26"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-27"></span><p class="line867"> 520 <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-16"></span><p class="line862">See <a href="http://master17.moinmo.in/DesktopEdition">DesktopEdition</a>. <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-17"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-18"></span><p class="line867">
521 <h2 id="HelpOnInstalling.2BAC8-StandaloneServer.Systempathconfiguration">System path configuration</h2> 521 <h1 id="HelpOnInstalling.2BAC8-StandaloneServer.Theflexibleway">The flexible way</h1>
522 <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-28"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-29"></span><p class="line874">If you did a standard install, and you are not a developer, you probably want to skip this section. If not, you might want to add the path to moin and config file, like that: <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-30"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-31"></span><p class="line867"><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-32"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-33"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-34"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-35"></span><pre>import sys 522 <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-19"></span><p class="line862">Instead of just running it like described above, you can of course move stuff to different places (see <a href="http://master17.moinmo.in/HelpOnInstalling/BasicInstallation">../BasicInstallation</a>, <a href="http://master17.moinmo.in/HelpOnInstalling/WikiInstanceCreation">../WikiInstanceCreation</a>). <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-20"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-21"></span><p class="line862">You can then invoke the moin standalone server using the <tt class="backtick">moin</tt> scripting command: <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-22"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-23"></span><p class="line867"><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-24"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-25"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-26"></span><pre># for details and other options, see: moin server standalone --help
523 sys.path.insert(0, '/path/to/moin') 523 moin --config-dir=/etc/moin server standalone --docs=/usr/share/moin/htdocs</pre><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-27"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-28"></span><p class="line874">Of course you have to give correct values that match your setup: <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-29"></span><ul><li><p class="line891"><tt class="backtick">--config-dir</tt> gives the directory that contains your wikiconfig (or farmconfig). <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-30"></span><ul><li><p class="line862">wikiconfig points to other important pathes, e.g. <tt class="backtick">data_dir</tt> and <tt class="backtick">underlay_dir</tt> <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-31"></span></li></ul></li><li><p class="line891"><tt class="backtick">--docs</tt> gives the directory where moin finds the static files (css, imgs, etc.) <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-32"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-33"></span></li></ul><p class="line862">If it does not find the <tt class="backtick">moin</tt> command: <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-34"></span><ul><li><p class="line862">if you used <tt class="backtick">setup.py</tt> it should have copied it to <tt class="backtick">/usr(/local)/bin</tt> - check your PATH. <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-35"></span></li><li><p class="line862">if you don't want to use <tt class="backtick">setup.py</tt> just write your own <tt class="backtick">moin</tt> command script: <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-36"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-37"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-38"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-39"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-40"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-41"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-42"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-43"></span><pre>#Fix and uncomment those 2 lines if it doesn't find the MoinMoin package:
524 sys.path.insert(0, '/path/to/wikiconfig')</pre><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-36"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-37"></span><p class="line867"><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.options"></span> <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-38"></span> 524 #import sys
525 <h2 id="HelpOnInstalling.2BAC8-StandaloneServer.Configclassoptions">Config class options</h2> 525 #sys.path.insert(0, '/path/to/moin_code')
526 <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-39"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-40"></span><div><table><tbody><tr> <td><p class="line862"> <strong>Option</strong> </td> 526 from MoinMoin.script.moin import run
527 run()</pre><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-44"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-45"></span></li></ul><p class="line867"><img alt="(!)" height="15" src="/moin_static170/modern/img/idea.png" title="(!)" width="15" /> If it crashes and tells it can't import <tt class="backtick">MoinMoin</tt>, then just uncomment and fix the <tt class="backtick">sys.path</tt> stuff you see above. <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-46"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-47"></span><p class="line862">Now point your browser at <tt class="backtick">http://localhost:8080/</tt> (or whatever moin tells you). <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-48"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-49"></span><p class="line862">If you want to run the moin process as a daemon, have a look at the <tt class="backtick">--start</tt>, <tt class="backtick">--stop</tt> and <tt class="backtick">--pidfile</tt> options. <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-50"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-51"></span><p class="line867">
528 <h2 id="HelpOnInstalling.2BAC8-StandaloneServer.Servingport80onUnix">Serving port 80 on Unix</h2>
529 <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-52"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-53"></span><p class="line862">On GNU/Linux, Mac OS X or other Posix like OS, you can serve the standard port 80 used for web serving, but you must start moin as <tt>root</tt> for this. <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-54"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-55"></span><p class="line862">Set <tt>port</tt> to 80, and verify that <tt>user</tt> and <tt>group</tt> exists on your system. If not, set them to an existing user, meant for web serving. If needed, <tt>chown</tt> your wiki dir to this user and group. <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-56"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-57"></span><p class="line867">
530 <h2 id="HelpOnInstalling.2BAC8-StandaloneServer.StandaloneServerconfiguration">Standalone Server configuration</h2>
531 <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-58"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-59"></span><p class="line862">Alternatively to giving parameters by commandline options, you can also have a <tt class="backtick">wikiserverconfig.py</tt> and specify your stuff in a <tt class="backtick">Config</tt> class there. See the example file in the toplevel directory. <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-60"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-61"></span><div><table><tbody><tr> <td><p class="line862"> <strong>Option</strong> </td>
527 <td><p class="line862"> <strong>Default</strong> </td> 532 <td><p class="line862"> <strong>Default</strong> </td>
528 <td><p class="line862"> <strong>Comment</strong> </td> 533 <td><p class="line862"> <strong>Comment</strong> </td>
529 </tr> 534 </tr>
530 <tr> <td><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-41"></span><p class="line862"> name </td> 535 <tr> <td><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-62"></span><p class="line862"> name </td>
531 <td><p class="line862"> <tt>'moin'</tt> </td> 536 <td><p class="line862"> <tt>'moin'</tt> </td>
532 <td><p class="line862"> Server name, used by default for log and pid files. <img alt="(!)" height="15" src="/moin_static170/modern/img/idea.png" title="(!)" width="15" /> New in 1.5 </td> 537 <td><p class="line862"> Server name, used by default for log and pid files. </td>
533 </tr> 538 </tr>
534 <tr> <td><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-42"></span><p class="line862"> docs </td> 539 <tr> <td><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-63"></span><p class="line862"> docs </td>
535 <td><p class="line862"> <tt>'/usr/share/moin/wiki/htdocs'</tt> </td> 540 <td><p class="line862"> <tt>'/usr/share/moin/wiki/htdocs'</tt> </td>
536 <td><p class="line862"> Path to moin shared files. If you used <tt class="backtick">--prefix</tt> install, the default path will not work, and you must set the path to <tt>'PREFIX/share/moin/wiki/htdocs'</tt>. </td> 541 <td><p class="line862"> Path to moin shared files. If you used <tt class="backtick">--prefix</tt> install, the default path will not work, and you must set the path to <tt>'PREFIX/share/moin/wiki/htdocs'</tt>. </td>
537 </tr> 542 </tr>
538 <tr> <td><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-43"></span><p class="line862"> user </td> 543 <tr> <td><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-64"></span><p class="line862"> user </td>
539 <td><p class="line862"> <tt>'www-data'</tt> </td> 544 <td><p class="line862"> <tt>'www-data'</tt> </td>
540 <td><p class="line862"> If you run as root, the server will run with as this user </td> 545 <td><p class="line862"> If you run as root, the server will run with as this user </td>
541 </tr> 546 </tr>
542 <tr> <td><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-44"></span><p class="line862"> group </td> 547 <tr> <td><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-65"></span><p class="line862"> group </td>
543 <td><p class="line862"> <tt>'www-data'</tt> </td> 548 <td><p class="line862"> <tt>'www-data'</tt> </td>
544 <td><p class="line862"> If you run as root, the server will run with as this group </td> 549 <td><p class="line862"> If you run as root, the server will run with as this group </td>
545 </tr> 550 </tr>
546 <tr> <td><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-45"></span><p class="line862"> port </td> 551 <tr> <td><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-66"></span><p class="line862"> port </td>
547 <td><p class="line862"> <tt>8000</tt> </td> 552 <td><p class="line862"> <tt>8000</tt> </td>
548 <td><p class="line862"> Port to serve. To serve privileged port under 1024 you will have to run as root </td> 553 <td><p class="line862"> Port to serve. To serve privileged port under 1024 you will have to run as root </td>
549 </tr> 554 </tr>
550 <tr> <td><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-46"></span><p class="line862"> interface </td> 555 <tr> <td><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-67"></span><p class="line862"> interface </td>
551 <td><p class="line862"> <tt>'localhost'</tt> </td> 556 <td><p class="line862"> <tt>'localhost'</tt> </td>
552 <td><p class="line862"> The interface the server will listen to. The default will listen only to localhost. Set to <tt>''</tt> to listen to all.</td> 557 <td><p class="line862"> The interface the server will listen to. The default will listen only to localhost. Set to <tt>''</tt> to listen to all.</td>
553 </tr> 558 </tr>
554 <tr> <td><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-47"></span><p class="line862"> logPath </td> 559 <tr> <td><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-68"></span><p class="line862"> serverClass </td>
555 <td><p class="line862"> <tt>name&nbsp;+&nbsp;'.log'</tt> </td>
556 <td><p class="line862"> Log file. Default is commented. </td>
557 </tr>
558 <tr> <td><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-48"></span><p class="line862"> serverClass </td>
559 <td><p class="line862"> <tt>'ThreadPoolServer'</tt>, <tt>'ThreadingServer'</tt>, <tt>'ForkingServer'</tt>, <tt>'SimpleServer'</tt>, <tt>'SecureThreadPoolServer'</tt> </td> 560 <td><p class="line862"> <tt>'ThreadPoolServer'</tt>, <tt>'ThreadingServer'</tt>, <tt>'ForkingServer'</tt>, <tt>'SimpleServer'</tt>, <tt>'SecureThreadPoolServer'</tt> </td>
560 <td><p class="line862"> The server type to use, see the comments in the <tt>moin.py</tt>. The default is <tt>'ThreadPoolServer'</tt>, which create a pool of threads and reuse them for new connections. <img alt="(!)" height="15" src="/moin_static170/modern/img/idea.png" title="(!)" width="15" /> New in 1.3.5 </td> 561 <td><p class="line862"> The server type to use, see the comments in the <tt>moin.py</tt>. The default is <tt>'ThreadPoolServer'</tt>, which create a pool of threads and reuse them for new connections. </td>
561 </tr> 562 </tr>
562 <tr> <td><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-49"></span><p class="line862"> threadLimit </td> 563 <tr> <td><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-69"></span><p class="line862"> threadLimit </td>
563 <td><p class="line862"> <tt>10</tt> </td> 564 <td><p class="line862"> <tt>10</tt> </td>
564 <td><p class="line862"> How many threads to create. </td> 565 <td><p class="line862"> How many threads to create. </td>
565 </tr> 566 </tr>
566 <tr> <td><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-50"></span><p class="line862"> requestQueueSize </td> 567 <tr> <td><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-70"></span><p class="line862"> requestQueueSize </td>
567 <td><p class="line862"> <tt>50</tt> </td> 568 <td><p class="line862"> <tt>50</tt> </td>
568 <td><p class="line862"> The count of socket connection requests that are buffered by the operating system. <img alt="(!)" height="15" src="/moin_static170/modern/img/idea.png" title="(!)" width="15" /> New in 1.3.5 </td> 569 <td><p class="line862"> The count of socket connection requests that are buffered by the operating system. </td>
569 </tr> 570 </tr>
570 <tr> <td><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-51"></span><p class="line862"> properties </td> 571 <tr> <td><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-71"></span><p class="line862"> properties </td>
571 <td><p class="line862"> <tt>&nbsp;{}&nbsp;</tt> </td> 572 <td><p class="line862"> <tt>&nbsp;{}&nbsp;</tt> </td>
572 <td><p class="line862"> allow overriding any request property by setting the value in this dict e.g <tt>properties&nbsp;=&nbsp;{'script_name':&nbsp;'/mywiki'</tt>}. <img alt="(!)" height="15" src="/moin_static170/modern/img/idea.png" title="(!)" width="15" /> New in 1.5 </td> 573 <td><p class="line862"> allow overriding any request property by setting the value in this dict e.g <tt>properties&nbsp;=&nbsp;{'script_name':&nbsp;'/mywiki'</tt>}. </td>
573 </tr> 574 </tr>
574 <tr> <td><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-52"></span><p class="line862"> ssl_privkey </td> 575 <tr> <td><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-72"></span><p class="line862"> ssl_privkey </td>
575 <td><p class="line862"> <tt>&nbsp;None&nbsp;</tt> </td> 576 <td><p class="line862"> <tt>&nbsp;None&nbsp;</tt> </td>
576 <td><p class="line862"> If using the <a class="nonexistent" href="http://master17.moinmo.in/SecureThreadPoolServer">SecureThreadPoolServer</a>, this must point to the server's private key <img alt="(!)" height="15" src="/moin_static170/modern/img/idea.png" title="(!)" width="15" /> New in 1.6 </td> 577 <td><p class="line862"> If using the <a class="nonexistent" href="http://master17.moinmo.in/SecureThreadPoolServer">SecureThreadPoolServer</a>, this must point to the server's private key. </td>
577 </tr> 578 </tr>
578 <tr> <td><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-53"></span><p class="line862"> ssl_certificate </td> 579 <tr> <td><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-73"></span><p class="line862"> ssl_certificate </td>
579 <td><p class="line862"> <tt>&nbsp;None&nbsp;</tt> </td> 580 <td><p class="line862"> <tt>&nbsp;None&nbsp;</tt> </td>
580 <td><p class="line862"> If using the <a class="nonexistent" href="http://master17.moinmo.in/SecureThreadPoolServer">SecureThreadPoolServer</a>, this must point to the server's certificate <img alt="(!)" height="15" src="/moin_static170/modern/img/idea.png" title="(!)" width="15" /> New in 1.6 </td> 581 <td><p class="line862"> If using the <a class="nonexistent" href="http://master17.moinmo.in/SecureThreadPoolServer">SecureThreadPoolServer</a>, this must point to the server's certificate. </td>
581 </tr> 582 </tr>
582 </tbody></table></div><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-54"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-55"></span><ul><li style="list-style-type:none"><p class="line891"><img alt="(!)" height="15" src="/moin_static170/modern/img/idea.png" title="(!)" width="15" /> There may be more options useful to moin developers, see the comments in <tt>moin.py</tt> <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-56"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-57"></span></li></ul><p class="line867"> 583 </tbody></table></div><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-74"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-75"></span><ul><li style="list-style-type:none"><p class="line891"><img alt="(!)" height="15" src="/moin_static170/modern/img/idea.png" title="(!)" width="15" /> There may be more options useful to moin developers, see the comments in <tt>moin.py</tt> <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-76"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-77"></span></li></ul><p class="line867">
584 <h2 id="HelpOnInstalling.2BAC8-StandaloneServer.Configuringwikiconfig.py">Configuring wikiconfig.py</h2>
585 <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-78"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-79"></span><p class="line874">The sample config file should be just fine. <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-80"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-81"></span><p class="line862">The default value of <tt class="backtick">url_prefix_static</tt> is hardcoded into the standalone server script, do not change it or it won't work! <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-82"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-83"></span><p class="line867">
583 <h2 id="HelpOnInstalling.2BAC8-StandaloneServer.Usingthesecurestandaloneserver">Using the secure standalone server</h2> 586 <h2 id="HelpOnInstalling.2BAC8-StandaloneServer.Usingthesecurestandaloneserver">Using the secure standalone server</h2>
584 <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-58"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-59"></span><p class="line867"><img alt="(!)" height="15" src="/moin_static170/modern/img/idea.png" title="(!)" width="15" /> New in 1.6 <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-60"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-61"></span><p class="line862">The standalone server supports SSL when using the <a class="nonexistent" href="http://master17.moinmo.in/SecureThreadPoolServer">SecureThreadPoolServer</a> server class. The SSL support is provided by the <a class="http" href="http://trevp.net/tlslite/">TLSLite library</a>. <strong>All wiki traffic is forced to SSL when using the <a class="nonexistent" href="http://master17.moinmo.in/SecureThreadPoolServer">SecureThreadPoolServer</a></strong>. <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-62"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-63"></span><p class="line862">Two additional configuration options are required when using the <a class="nonexistent" href="http://master17.moinmo.in/SecureThreadPoolServer">SecureThreadPoolServer</a>. First, <tt class="backtick">ssl_privkey</tt> must point to the server's private key. Second, <tt class="backtick">ssl_certificate</tt> must point to the server's certificate. <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-64"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-65"></span><p class="line867"><img alt="/!\" height="15" src="/moin_static170/modern/img/alert.png" title="/!\" width="15" /> <em>TLSLite does not support a password protected private key unless additional libraries are used. Consult the TLSLite webpage for more information.</em> <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-66"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-67"></span><p class="line862">Typically a certificate would be purchased from an certificate authority, such as Thawte (<a class="http" href="http://www.thawte.com">http://www.thawte.com</a>). However, since the suggested usage of the standalone server is for personal use, a self signed certificate may be appropriate. For more information on how to generate a server private key, and a self signed certificate, see the <a class="http" href="http://www.openssl.org/docs/HOWTO/">openssl HOWTO pages</a>. <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-68"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-69"></span><p class="line874">For example, to create the server's private key, run the following: <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-70"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-71"></span><p class="line867"><tt class="backtick">openssl&nbsp;genrsa&nbsp;-out&nbsp;privkey.pem&nbsp;2048</tt> <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-72"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-73"></span><p class="line874">To create a self signed certificate for the newly created private key, run the following: <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-74"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-75"></span><p class="line867"><tt class="backtick">openssl&nbsp;req&nbsp;-new&nbsp;-x509&nbsp;-key&nbsp;privkey.pem&nbsp;-out&nbsp;cacert.pem&nbsp;-days&nbsp;1095</tt> <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-76"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-77"></span><p class="line862">moin.py then needs to be told about the generated files <tt class="backtick">privkey.pem</tt> and <tt class="backtick">cacert.pem</tt>. For the example above, the following lines would need to be added to moin.py: <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-78"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-79"></span><p class="line867"><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-80"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-81"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-82"></span><pre> ssl_privkey = "/secure/path/to/privkey.pem" 587 <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-84"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-85"></span><p class="line862">The standalone server supports SSL when using the <a class="nonexistent" href="http://master17.moinmo.in/SecureThreadPoolServer">SecureThreadPoolServer</a> server class. The SSL support is provided by the <a class="http" href="http://trevp.net/tlslite/">TLSLite library</a>. <strong>All wiki traffic is forced to SSL when using the <a class="nonexistent" href="http://master17.moinmo.in/SecureThreadPoolServer">SecureThreadPoolServer</a></strong>. <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-86"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-87"></span><p class="line862">Two additional configuration options are required when using the <a class="nonexistent" href="http://master17.moinmo.in/SecureThreadPoolServer">SecureThreadPoolServer</a>. First, <tt class="backtick">ssl_privkey</tt> must point to the server's private key. Second, <tt class="backtick">ssl_certificate</tt> must point to the server's certificate. <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-88"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-89"></span><p class="line867"><img alt="/!\" height="15" src="/moin_static170/modern/img/alert.png" title="/!\" width="15" /> <em>TLSLite does not support a password protected private key unless additional libraries are used. Consult the TLSLite webpage for more information.</em> <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-90"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-91"></span><p class="line862">Typically a certificate would be purchased from an certificate authority, such as Thawte (<a class="http" href="http://www.thawte.com">http://www.thawte.com</a>). However, since the suggested usage of the standalone server is for personal use, a self signed certificate may be appropriate. For more information on how to generate a server private key, and a self signed certificate, see the <a class="http" href="http://www.openssl.org/docs/HOWTO/">openssl HOWTO pages</a>. <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-92"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-93"></span><p class="line874">For example, to create the server's private key, run the following: <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-94"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-95"></span><p class="line867"><tt class="backtick">openssl&nbsp;genrsa&nbsp;-out&nbsp;privkey.pem&nbsp;2048</tt> <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-96"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-97"></span><p class="line874">To create a self signed certificate for the newly created private key, run the following: <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-98"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-99"></span><p class="line867"><tt class="backtick">openssl&nbsp;req&nbsp;-new&nbsp;-x509&nbsp;-key&nbsp;privkey.pem&nbsp;-out&nbsp;cacert.pem&nbsp;-days&nbsp;1095</tt> <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-100"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-101"></span><p class="line862">moin.py then needs to be told about the generated files <tt class="backtick">privkey.pem</tt> and <tt class="backtick">cacert.pem</tt>. For the example above, the following lines would need to be added to moin.py: <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-102"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-103"></span><p class="line867"><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-104"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-105"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-106"></span><pre> ssl_privkey = "/secure/path/to/privkey.pem"
585 ssl_certificate = "/secure/path/to/cacert.pem"</pre><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-83"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-84"></span><p class="line867"><img alt="/!\" height="15" src="/moin_static170/modern/img/alert.png" title="/!\" width="15" /> Using a self signed certificate will cause your browser to generate a warning that it cannot verify the identify of the wiki server. This is because the certificate was not signed by a recognized certificate authority (CA). In order to get rid of this warning, you must purchase a certificate from a CA. <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-85"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-86"></span><p class="line867"> 588 ssl_certificate = "/secure/path/to/cacert.pem"</pre><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-107"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-108"></span><p class="line867"><img alt="/!\" height="15" src="/moin_static170/modern/img/alert.png" title="/!\" width="15" /> Using a self signed certificate will cause your browser to generate a warning that it cannot verify the identify of the wiki server. This is because the certificate was not signed by a recognized certificate authority (CA). In order to get rid of this warning, you must purchase a certificate from a CA. <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-109"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.bottom"></span></div> <span class="anchor" id="line-66"></span><hr class="hr2" /><p class="line874"> <span class="anchor" id="line-67"></span><span class="anchor" id="macosx-install"></span> <span class="anchor" id="line-68"></span>
586 <h1 id="HelpOnInstalling.2BAC8-StandaloneServer.Configuringwikiconfig.py">Configuring wikiconfig.py</h1>
587 <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-87"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-88"></span><p class="line874">The sample config file should be just fine. <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-89"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-90"></span><p class="line862">The default value of <tt class="backtick">url_prefix_static</tt> is hardcoded into the standalone server script, do not change it or it won't work! <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-91"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-92"></span><p class="line867">
588 <h1 id="HelpOnInstalling.2BAC8-StandaloneServer.Startingtheserver">Starting the server</h1>
589 <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-93"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-94"></span><p class="line862">Run <tt>moin.py</tt> from the command line: <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-95"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-96"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-97"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-98"></span><pre>$ ./moin.py
590 Serving on localhost:8000</pre><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-99"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-100"></span><p class="line862">Test your wiki at <a class="http" href="http://localhost:8000/">http://localhost:8000/</a> <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-101"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-102"></span><p class="line862">On Windows, you can double click <tt>moin.py</tt> to start the server. A new terminal window will be opened. Close the window or press <tt>Control&nbsp;+&nbsp;Pause</tt> to stop the server. <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-103"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-104"></span><p class="line862">On Unix, interrupt the server with <tt>Control&nbsp;+&nbsp;C</tt> in order to shut it down. <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-105"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-106"></span><p class="line867">
591 <h1 id="HelpOnInstalling.2BAC8-StandaloneServer.Servingport80onUnix">Serving port 80 on Unix</h1>
592 <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-107"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-108"></span><p class="line862">On GNU/Linux, Mac OS X or other Posix like OS, you can serve the standard port 80 used for web serving, but you must run as <tt>root</tt> for this. <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-109"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-110"></span><p class="line862">Set <tt>port</tt> to 80, and verify that <tt>user</tt> and <tt>group</tt> exists on your system. If not, set them to an existing user, meant for web serving. If needed, <tt>chown</tt> your wiki dir to this user and group. <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-111"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-112"></span><p class="line862">Run <tt>moin.py</tt> as root: <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-113"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-114"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-115"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-116"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-117"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-118"></span><pre>$ sudo moin.py
593 Password:
594 Serving on localhost:8000
595 Running as uid/gid 70/70</pre><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-119"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-120"></span><p class="line862">Test your wiki at <a class="http" href="http://localhost/">http://localhost/</a> <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-121"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-122"></span><p class="line867">
596 <h1 id="HelpOnInstalling.2BAC8-StandaloneServer.Runningasdaemon">Running as daemon</h1>
597 <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-123"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-124"></span><p class="line874">If run on Unix, you can run moin.py as a background process: <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-125"></span><ol type="1"><li><p class="line862">Have a working <tt>moin.py</tt> as explained above <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-126"></span></li><li><p class="line862">Copy the file <tt>prefix/share/moin/server/moin</tt> to your wiki directory. <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-127"></span></li><li>Start moin server: <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-128"></span></li></ol><p class="line867"><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-129"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-130"></span><pre>./moin start</pre><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-131"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-132"></span><p class="line874">To stop the server: <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-133"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-134"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-135"></span><pre>./moin stop</pre><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-136"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-137"></span><p class="line862">For more info run <tt>moin</tt> with no arguments. <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-138"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-139"></span><p class="line862">If you want to start moin from a system startup script, you may need to add the path to <tt>moin.py</tt> in the top of the script: <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-140"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-141"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-142"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-143"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-144"></span><pre># Add the path to moin.py directory
598 import sys
599 sys.path.insert(0, '/path/to/moin')</pre><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-145"></span><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-146"></span><ul><li style="list-style-type:none"><p class="line891"><img alt="(!)" height="15" src="/moin_static170/modern/img/idea.png" title="(!)" width="15" /> New in release 1.5 <span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.line-147"></span></li></ul><span class="anchor" id="HelpOnInstalling.2BAC8-StandaloneServer.bottom"></span></div> <span class="anchor" id="line-66"></span><hr class="hr2" /><p class="line874"> <span class="anchor" id="line-67"></span><span class="anchor" id="macosx-install"></span> <span class="anchor" id="line-68"></span>
600 <h1>Mac OS X Installation using Apache</h1> 589 <h1>Mac OS X Installation using Apache</h1>
601 <div dir="ltr" id="HelpOnInstalling.2BAC8-ApacheOnMacOsx.content" lang="en"><span class="anchor" id="HelpOnInstalling.2BAC8-ApacheOnMacOsx.top"></span> 590 <div dir="ltr" id="HelpOnInstalling.2BAC8-ApacheOnMacOsx.content" lang="en"><span class="anchor" id="HelpOnInstalling.2BAC8-ApacheOnMacOsx.top"></span>
602 <span class="anchor" id="HelpOnInstalling.2BAC8-ApacheOnMacOsx.line-8"></span><span class="anchor" id="HelpOnInstalling.2BAC8-ApacheOnMacOsx.line-9"></span><p class="line874">These instructions will walk you through, step by step, setting up Moin on Mac OS X <span class="anchor" id="HelpOnInstalling.2BAC8-ApacheOnMacOsx.line-10"></span><span class="anchor" id="HelpOnInstalling.2BAC8-ApacheOnMacOsx.line-11"></span><p class="line867"><div class="table-of-contents"><p class="table-of-contents-heading">Contents<ol><li><ol><li> 591 <span class="anchor" id="HelpOnInstalling.2BAC8-ApacheOnMacOsx.line-8"></span><span class="anchor" id="HelpOnInstalling.2BAC8-ApacheOnMacOsx.line-9"></span><p class="line874">These instructions will walk you through, step by step, setting up Moin on Mac OS X <span class="anchor" id="HelpOnInstalling.2BAC8-ApacheOnMacOsx.line-10"></span><span class="anchor" id="HelpOnInstalling.2BAC8-ApacheOnMacOsx.line-11"></span><p class="line867"><div class="table-of-contents"><p class="table-of-contents-heading">Contents<ol><li><ol><li>
603 <a href="#HelpOnInstalling.2BAC8-ApacheOnMacOsx.SystemRequirements.26Preparation">System Requirements &amp; Preparation</a></li><li> 592 <a href="#HelpOnInstalling.2BAC8-ApacheOnMacOsx.SystemRequirements.26Preparation">System Requirements &amp; Preparation</a></li><li>
604 <a href="#HelpOnInstalling.2BAC8-ApacheOnMacOsx.Installation">Installation</a><ol><li> 593 <a href="#HelpOnInstalling.2BAC8-ApacheOnMacOsx.Installation">Installation</a><ol><li>
863 python -V 2&gt;&amp;1 852 python -V 2&gt;&amp;1
864 python2.3 -V 2&gt;&amp;1 853 python2.3 -V 2&gt;&amp;1
865 python2.4 -V 2&gt;&amp;1 854 python2.4 -V 2&gt;&amp;1
866 python2.5 -V 2&gt;&amp;1 855 python2.5 -V 2&gt;&amp;1
867 echo "Finished."</pre><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-41"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-42"></span><p class="line874">to see if you can get it to announce that cgi works. Then you will also know which versions of python are usable. This is especially handy for users with no root access. <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-43"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-44"></span><p class="line867"> 856 echo "Finished."</pre><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-41"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-42"></span><p class="line874">to see if you can get it to announce that cgi works. Then you will also know which versions of python are usable. This is especially handy for users with no root access. <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-43"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-44"></span><p class="line867">
868 <h1 id="HelpOnInstalling.2BAC8-TroubleShooting.Built-intest">Built-in test</h1>
869 <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-45"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-46"></span><p class="line862">There's a built-in diagnostic mode that's useful when doing an install; just append "<tt class="backtick">?action=test</tt>" to the URL of your wiki: <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-47"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-48"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-49"></span><pre>lynx --dump http://`hostname`/mywiki?action=test</pre><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-50"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-51"></span><p class="line874">If you see an import error here, but <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-52"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-53"></span><p class="line867"><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-54"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-55"></span><pre>python -c "import MoinMoin"</pre><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-56"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-57"></span><p class="line874">works, it's likely a result of missing file permissions or a wrong PYTHONPATH setting within the web server environment. <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-58"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-59"></span><p class="line867">
870 <h1 id="HelpOnInstalling.2BAC8-TroubleShooting.DuellingPythons">Duelling Pythons</h1> 857 <h1 id="HelpOnInstalling.2BAC8-TroubleShooting.DuellingPythons">Duelling Pythons</h1>
871 <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-60"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-61"></span><p class="line862">The most common problem you might encounter is when you have an old Python version installed into "<tt class="backtick">/usr</tt>", and a newer Python distribution into "<tt class="backtick">/usr/local</tt>"; this is typical for GNU/Linux distributions that still come bundled with an old Python version. <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-62"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-63"></span><p class="line862">In that case, if you enter "<tt class="backtick">python</tt>" on your prompt, you will usually get the more recent Python interpreter, because "<tt class="backtick">/usr/local/bin</tt>" is in your <tt class="backtick">PATH</tt>. The situation is different in your webserver environment, and thus you might have to change the bang path of "<tt class="backtick">moin.cgi</tt>", like this: <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-64"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-65"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-66"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-67"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-68"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-69"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-70"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-71"></span><pre>""" 858 <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-45"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-46"></span><p class="line862">The most common problem you might encounter is when you have an old Python version installed into "<tt class="backtick">/usr</tt>", and a newer Python distribution into "<tt class="backtick">/usr/local</tt>"; this is typical for GNU/Linux distributions that still come bundled with an old Python version. <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-47"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-48"></span><p class="line862">In that case, if you enter "<tt class="backtick">python</tt>" on your prompt, you will usually get the more recent Python interpreter, because "<tt class="backtick">/usr/local/bin</tt>" is in your <tt class="backtick">PATH</tt>. The situation is different in your webserver environment, and thus you might have to change the bang path of "<tt class="backtick">moin.cgi</tt>", like this: <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-49"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-50"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-51"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-52"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-53"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-54"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-55"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-56"></span><pre>"""
872 MoinMoin - CGI Driver Script 859 MoinMoin - CGI Driver Script
873 ... 860 ...
874 """</pre><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-72"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-73"></span><ul><li><p class="line862">When installing, make sure you install with the version of python you want to run moin with. <tt class="backtick">python&nbsp;setup.py&nbsp;install</tt> will install with the first python in the path, which may be the version you expect or not! <tt class="backtick">/usr/local/bin/python2.4</tt> will install in specific python. You will have to use the same path in the moin server script. <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-74"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-75"></span></li></ul><p class="line867"> 861 """</pre><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-57"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-58"></span><ul><li><p class="line862">When installing, make sure you install with the version of python you want to run moin with. <tt class="backtick">python&nbsp;setup.py&nbsp;install</tt> will install with the first python in the path, which may be the version you expect or not! <tt class="backtick">/usr/local/bin/python2.4</tt> will install in specific python. You will have to use the same path in the moin server script. <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-59"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-60"></span></li></ul><p class="line867">
875 <h1 id="HelpOnInstalling.2BAC8-TroubleShooting.Missingfilepermissions">Missing file permissions</h1> 862 <h1 id="HelpOnInstalling.2BAC8-TroubleShooting.Missingfilepermissions">Missing file permissions</h1>
876 <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-76"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-77"></span><p class="line862">If you are root, the installed files may be readable only by root, but they must also be readable by the web server before the wiki will work. This includes both the Python modules and the site itself. For the data directory, the wiki engine also needs <em>write</em> access. To fix this, first find out where the Python module directory is; look in <tt class="backtick">install.log</tt>, or run the command: <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-78"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-79"></span><p class="line867"><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-80"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-81"></span><pre>python -c "import sys; print '%s/lib/python%s/site-packages' % ( sys.prefix, sys.version[:3] )"</pre><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-82"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-83"></span><p class="line862">For the example below, we'll assume that the Python module directory is <tt class="backtick">/usr/local/lib/python2.3/site-packages</tt>. <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-84"></span>Make the files world-readable using the following commands: <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-85"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-86"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-87"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-88"></span><pre>cd /usr/local 863 <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-61"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-62"></span><p class="line862">If you are root, the installed files may be readable only by root, but they must also be readable by the web server before the wiki will work. This includes both the Python modules and the site itself. For the data directory, the wiki engine also needs <em>write</em> access. To fix this, first find out where the Python module directory is; look in <tt class="backtick">install.log</tt>, or run the command: <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-63"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-64"></span><p class="line867"><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-65"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-66"></span><pre>python -c "import sys; print '%s/lib/python%s/site-packages' % ( sys.prefix, sys.version[:3] )"</pre><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-67"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-68"></span><p class="line862">For the example below, we'll assume that the Python module directory is <tt class="backtick">/usr/local/lib/python2.4/site-packages</tt>. <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-69"></span>Make the files world-readable using the following commands: <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-70"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-71"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-72"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-73"></span><pre>cd /usr/local
877 chmod -R a+rX lib/python2.3/site-packages/MoinMoin</pre><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-89"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-90"></span><p class="line867"> 864 chmod -R a+rX lib/python2.4/site-packages/MoinMoin</pre><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-74"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-75"></span><p class="line867">
878 <h1 id="HelpOnInstalling.2BAC8-TroubleShooting.SetYourVariablesCarefully">Set Your Variables Carefully</h1> 865 <h1 id="HelpOnInstalling.2BAC8-TroubleShooting.SetYourVariablesCarefully">Set Your Variables Carefully</h1>
879 <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-91"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-92"></span><p class="line862">Be especially careful when you retype instead of cut and paste. Quoting errors in <tt class="backtick">wikiconfig.py</tt> can cause things to fail. The following items are also variable issues. Also, some features only work if they are enabled by their option in either <tt class="backtick">wikiconfig.py</tt> or <tt class="backtick">farmconfig.py</tt>. <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-93"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-94"></span><p class="line867"> 866 <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-76"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-77"></span><p class="line862">Be especially careful when you retype instead of cut and paste. Quoting errors in <tt class="backtick">wikiconfig.py</tt> can cause things to fail. The following items are also variable issues. Also, some features only work if they are enabled by their option in either <tt class="backtick">wikiconfig.py</tt> or <tt class="backtick">farmconfig.py</tt>. <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-78"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-79"></span><p class="line867">
880 <h2 id="HelpOnInstalling.2BAC8-TroubleShooting.moin.cgifound.2CMoindoesn.27trun">moin.cgi found, Moin doesn't run</h2> 867 <h2 id="HelpOnInstalling.2BAC8-TroubleShooting.moin.cgifound.2CMoindoesn.27trun">moin.cgi found, Moin doesn't run</h2>
881 <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-95"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-96"></span><p class="line862">If you have to add the moin code location into the system path, make sure to specify the place <tt class="backtick"></tt>above<tt class="backtick"></tt> MoinMoin itself, so that the word MoinMoin is recognized during the import request. <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-97"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-98"></span><p class="line867"> 868 <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-80"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-81"></span><p class="line862">If you have to add the moin code location into the system path, make sure to specify the place <tt class="backtick"></tt>above<tt class="backtick"></tt> MoinMoin itself, so that the word MoinMoin is recognized during the import request. <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-82"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-83"></span><p class="line867">
882 <h2 id="HelpOnInstalling.2BAC8-TroubleShooting.CSSfilesdonotwork">CSS files do not work</h2> 869 <h2 id="HelpOnInstalling.2BAC8-TroubleShooting.CSSfilesdonotwork">CSS files do not work</h2>
883 <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-99"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-100"></span><p class="line862">Very common error is missing CSS styles. Your wiki look bare and ugly, unlike this nice wiki. In most cases, you did broke the configuration by not reading the instructions, or by trying to customize the instructions because you are smarter then us. <img alt=":-)" height="15" src="/moin_static170/modern/img/smile.png" title=":-)" width="15" /> <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-101"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-102"></span><p class="line862">The fix is very easy: make sure your Apache Alias and <a class="nonexistent" href="http://master17.moinmo.in/ScriptAlias">ScriptAlias</a> are <strong>NOT</strong> the same. This Apache setup will <strong>never work</strong>: <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-103"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-104"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-105"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-106"></span><pre>Alias /wiki/ "/prefix/share/moin/htdocs/" 870 <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-84"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-85"></span><p class="line874">A very common error is missing CSS styles. Your wiki looks bare and ugly, unlike this nice wiki. In most cases, you did break the configuration by not reading the instructions. <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-86"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-87"></span><p class="line862">The fix is very easy: make sure your Apache Alias and <a class="nonexistent" href="http://master17.moinmo.in/ScriptAlias">ScriptAlias</a> are <strong>NOT</strong> the same. <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-88"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-89"></span><p class="line862">This Apache setup will <strong>never work</strong>: <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-90"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-91"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-92"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-93"></span><pre>Alias /wiki/ "/prefix/share/moin/htdocs/"
884 ScriptAlias /wiki/ "/var/www/wiki/moin.cgi"</pre><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-107"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-108"></span><p class="line862">Alias is used to serve static files: css, images etc. <a class="nonexistent" href="http://master17.moinmo.in/ScriptAlias">ScriptAlias</a> is used to hide moin.cgi from the url. You must use different values! You can use anything you like for <a class="nonexistent" href="http://master17.moinmo.in/ScriptAlias">ScriptAlias</a>, or Alias, but Alias must match the <tt class="backtick">url_prefix_static</tt> configuration option. Here is an example that works (the default): <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-109"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-110"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-111"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-112"></span><pre># Apache config 871 ScriptAlias /wiki/ "/var/www/wiki/moin.cgi"</pre><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-94"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-95"></span><p class="line862">The Alias is used to serve static files: css, images, etc. <a class="nonexistent" href="http://master17.moinmo.in/ScriptAlias">ScriptAlias</a> is used to hide moin.cgi from the url. You must use different values! You can use anything you like for <a class="nonexistent" href="http://master17.moinmo.in/ScriptAlias">ScriptAlias</a>, or Alias, but Alias must match the <tt class="backtick">url_prefix_static</tt> configuration option. <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-96"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-97"></span><p class="line874">Here is an example that works (the default): <span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-98"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-99"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-100"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-101"></span><pre># Apache config
885 Alias /moin_static160/ "/prefix/share/moin/htdocs/"</pre><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-113"></span><p class="line867"><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-114"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-115"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-116"></span><pre># Wiki config 872 Alias /moin_static170/ "/prefix/share/moin/htdocs/"</pre><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-102"></span><p class="line867"><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-103"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-104"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-105"></span><pre># Wiki config
886 url_prefix_static = '/moin_static160'</pre><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-117"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.bottom"></span></div> <span class="anchor" id="line-78"></span><span class="anchor" id="bottom"></span></div><p id="pageinfo" class="info" lang="en" dir="ltr">MoinMaster: MoinMoin/InstallDocs (last edited 2007-12-19 12:51:43 by <span title="ThomasWaldmann @ p57B4409C.dip0.t-ipconnect.de[87.180.64.156]"><a class="interwiki" href="http://moinmo.in/ThomasWaldmann" title="ThomasWaldmann @ p57B4409C.dip0.t-ipconnect.de[87.180.64.156]">ThomasWaldmann</a></span>)</p> 873 url_prefix_static = '/moin_static170'</pre><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.line-106"></span><span class="anchor" id="HelpOnInstalling.2BAC8-TroubleShooting.bottom"></span></div> <span class="anchor" id="line-78"></span><span class="anchor" id="bottom"></span></div><p id="pageinfo" class="info" lang="en" dir="ltr">MoinMaster: MoinMoin/InstallDocs (last edited 2007-12-19 12:51:43 by <span title="ThomasWaldmann @ p57B4409C.dip0.t-ipconnect.de[87.180.64.156]"><a class="interwiki" href="http://moinmo.in/ThomasWaldmann" title="ThomasWaldmann @ p57B4409C.dip0.t-ipconnect.de[87.180.64.156]">ThomasWaldmann</a></span>)</p>
887 <div id="pagebottom"></div> 874 <div id="pagebottom"></div>
888 </div> 875 </div>
889 </body> 876 </body>
890 </html> 877 </html>
891 878