对apache2不熟,折腾了半天,记录一下,主要就是virtualhost那块比较乱
Virtual hosts allow you to run different servers for different IP addresses, different host names, or different ports on the same machine. For example, you can run the website for http://www.example.com and http://www.anotherexample.com on the same Web server using virtual hosts. This option corresponds to the <VirtualHost> directive for the default virtual host and IP-based virtual hosts. It corresponds to the <NameVirtualHost> directive for a name-based virtual host.
The directives set for a virtual host only apply to that particular virtual host. If a directive is set server-wide and not defined within the virtual host settings, the default setting is used. For example, you can define a Webmaster email address and not define individual email addresses for each virtual host.
Set the DocumentRoot directive to the directory that contains the root document (such as index.html) for the virtual host. The default DocumentRoot is /var/www
.
The ServerAdmin directive within the VirtualHost stanza is email the address used in the footer of error pages if you choose to show a footer with an email address on the error pages.
这一段参考:https://help.ubuntu.com/6.06/ubuntu/serverguide/C/httpd.html
moinmoin的配置方法在/usr/share/doc/python-moinmoin/README.Debian.gz里面有
ports.conf中新增一个端口
NameVirtualHost *:8000
Listen 8000
sites-available中:新建一个mywiki文件
访问localhost:8000/MyWiki 就可以了