Add a slash
[hcoop/domtool2.git] / lib / web_apps.dtl
CommitLineData
18f63ec1
AC
1{{Configuring common web applications}}
2
3val addWordPress = \ loc : (location) ->
4 location loc with
18f63ec1
AC
5 rewriteCond "%{REQUEST_FILENAME}" "!-f" [];
6 rewriteCond "%{REQUEST_FILENAME}" "!-d" [];
7 rewriteRule "." "/index.php" [last]
8 end;
9{{Add a standard WordPress blog set-up code to a virtual host. The WordPress
10 files should be rooted at the location you specify.}}
11
12val wordPress = \ host : (host) ->
13 web host with
14 addWordPress "/"
15 end;
16{{Create a WordPress blog with just the standard set-up code. The WordPress blog should
17 be rooted at the vhost's <tt>DocumentRoot</tt>.}}
18
19val addMoinMoin = begin
20 htdocs <- Htdocs;
21 prefix <- Prefix;
22 script <- Script;
23
24 alias htdocs "/usr/share/moin/htdocs";
25 scriptAlias prefix script
26end;
27{{Add a MoinMoin wiki to a vhost.}}
28
29val moinMoin = \ host : (host) ->
30 web host with
31 addMoinMoin where
4e38d526 32 Htdocs = "/moin";
18f63ec1
AC
33 Prefix = "/"
34 end
35 end;
36{{Create a new vhost with just a MoinMoin wiki.}}