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