Commit | Line | Data |
---|---|---|
18f63ec1 AC |
1 | {{Configuring common web applications}} |
2 | ||
3 | val addWordPress = \ loc : (location) -> | |
4 | location loc with | |
1a86b2d3 | 5 | phpVersion php5; |
a052bc91 CE |
6 | rewriteRule "^(.*/)?\.svn/" "-" [forbidden, last]; |
7 | rewriteRule "^(.*/)?\.git/" "-" [forbidden, last]; | |
8 | ||
18f63ec1 AC |
9 | rewriteCond "%{REQUEST_FILENAME}" "!-f" []; |
10 | rewriteCond "%{REQUEST_FILENAME}" "!-d" []; | |
a052bc91 CE |
11 | |
12 | rewriteRule "." "/index.php" [last]; | |
18f63ec1 AC |
13 | end; |
14 | {{Add a standard WordPress blog set-up code to a virtual host. The WordPress | |
15 | files should be rooted at the location you specify.}} | |
16 | ||
17 | val wordPress = \ host : (host) -> | |
18 | web host with | |
19 | addWordPress "/" | |
20 | end; | |
21 | {{Create a WordPress blog with just the standard set-up code. The WordPress blog should | |
22 | be rooted at the vhost's <tt>DocumentRoot</tt>.}} | |
23 | ||
5ea8643a CE |
24 | val moin_default_htdocs : (location) = "/moin_static196"; |
25 | {{Alias for static content used by the system-wide MoinMoin.}} | |
26 | ||
18f63ec1 AC |
27 | val addMoinMoin = begin |
28 | htdocs <- Htdocs; | |
29 | prefix <- Prefix; | |
30 | script <- Script; | |
31 | ||
5ea8643a | 32 | alias htdocs "/afs/hcoop.net/common/app/moin/installed/moin19/lib/python2.6/site-packages/MoinMoin/web/static/htdocs"; |
b0963032 | 33 | scriptAlias prefix (end_in_slash script) |
18f63ec1 AC |
34 | end; |
35 | {{Add a MoinMoin wiki to a vhost.}} | |
36 | ||
37 | val moinMoin = \ host : (host) -> | |
38 | web host with | |
39 | addMoinMoin where | |
5ea8643a | 40 | Htdocs = moin_default_htdocs; |
18f63ec1 AC |
41 | Prefix = "/" |
42 | end | |
43 | end; | |
44 | {{Create a new vhost with just a MoinMoin wiki.}} | |
5ea8643a CE |
45 | |
46 | (* Legacy version of moin macros *) | |
47 | ||
48 | val addMoinMoinOld = begin | |
49 | htdocs <- Htdocs; | |
50 | prefix <- Prefix; | |
51 | script <- Script; | |
52 | ||
53 | alias htdocs "/usr/share/moin/htdocs"; | |
54 | scriptAlias prefix (end_in_slash script) | |
55 | end; | |
660f5874 | 56 | {{Add a MoinMoin wiki to a vhost.}} |