Commit | Line | Data |
---|---|---|
8a7c40fa AC |
1 | structure Apache :> APACHE_CONFIG = struct |
2 | ||
f8ef6c20 AC |
3 | open ConfigTypes |
4 | ||
979844d5 CE |
5 | val reload = ConfigCore.sudo ^ " " ^ ConfigCore.installPrefix ^ "/sbin/domtool-publish apache" |
6 | val down = ConfigCore.sudo ^ " " ^ ConfigCore.installPrefix ^ "/sbin/domtool-publish apache-down" | |
7 | val undown = ConfigCore.sudo ^ " " ^ ConfigCore.installPrefix ^ "/sbin/domtool-publish apache-undown" | |
8 | val fixperms = ConfigCore.sudo ^ " " ^ ConfigCore.installPrefix ^ "/sbin/domtool-publish apache-fixperms" | |
8a7c40fa | 9 | |
979844d5 CE |
10 | val reload1 = ConfigCore.sudo ^ " " ^ ConfigCore.installPrefix ^ "/sbin/domtool-publish apache1.3" |
11 | val down1 = ConfigCore.sudo ^ " " ^ ConfigCore.installPrefix ^ "/sbin/domtool-publish apache1.3-down" | |
12 | val undown1 = ConfigCore.sudo ^ " " ^ ConfigCore.installPrefix ^ "/sbin/domtool-publish apache1.3-undown" | |
13 | val fixperms1 = ConfigCore.sudo ^ " " ^ ConfigCore.installPrefix ^ "/sbin/domtool-publish apache1.3-fixperms" | |
55d4a268 | 14 | |
979844d5 | 15 | val confDir = ConfigCore.localRoot ^ "/vhosts" |
8a7c40fa | 16 | |
48c4786d | 17 | val webNodes_all = [("shelob", {version = APACHE_2, auth = MOD_WAKLOG})] |
47b18d28 CE |
18 | val webNodes_admin = [("minsky", {version = APACHE_2, auth = MOD_WAKLOG}), |
19 | ("busted", {version = APACHE_2, auth = MOD_WAKLOG})] | |
60695e99 | 20 | |
e95a129e AC |
21 | val proxyTargets = ["http://hcoop.net/cgi-bin/mailman", |
22 | "http://hcoop.net/pipermail"] | |
23 | ||
70a832f9 | 24 | val proxyHosts = ["marsh"] |
291eacbf | 25 | |
0da1c677 | 26 | val public_html = "public_html" |
de7fde3d | 27 | |
7d6cc0ec | 28 | fun logDirOf version1 user = |
409542d7 AC |
29 | if size user < 2 then |
30 | "/bad_username" | |
31 | else | |
7d6cc0ec AC |
32 | String.concat [if version1 then |
33 | "/var/log/apache/user/" | |
34 | else | |
35 | "/var/log/apache2/user/", | |
409542d7 AC |
36 | String.substring (user, 0, 1), |
37 | "/", | |
38 | String.substring (user, 0, 2), | |
39 | "/", | |
40 | user, | |
41 | "/apache/log"] | |
42 | ||
979844d5 | 43 | (* FIXME: hcoop.net reference *) |
f086616f AC |
44 | fun realLogDirOf user = |
45 | if size user < 2 then | |
46 | "/bad_username" | |
47 | else | |
48 | String.concat ["/afs/hcoop.net/user/", | |
49 | String.substring (user, 0, 1), | |
50 | "/", | |
51 | String.substring (user, 0, 2), | |
52 | "/", | |
53 | user, | |
54 | "/.logs/apache"] | |
55 | ||
31b50af0 AC |
56 | fun backupLogDirOf version1 = |
57 | if version1 then | |
979844d5 | 58 | ConfigCore.sharedRoot ^ "/backup/apache/" |
31b50af0 | 59 | else |
979844d5 | 60 | ConfigCore.sharedRoot ^ "/backup/apache2/" |
31b50af0 | 61 | |
42782c79 CE |
62 | fun fastCgiWrapperOf user = |
63 | if size user < 2 then | |
64 | "/bad_username" | |
65 | else | |
66 | String.concat [ConfigCore.sharedRoot, | |
67 | "/httpd/fastcgi/", | |
68 | String.substring (user, 0, 1), | |
69 | "/", | |
70 | String.substring (user, 0, 2), | |
71 | "/", | |
72 | user, | |
73 | "/", | |
74 | user, | |
75 | "-wrapper-wrapper"] | |
76 | ||
77 | (* FIXME: hcoop reference *) | |
4648ee8a | 78 | fun phpFastCgiWrapper version = "/afs/hcoop.net/common/bin/php" ^ Int.toString version ^ "-fcgi-wrapper" |
42782c79 | 79 | |
979844d5 | 80 | val waklogUserFile = ConfigCore.localRoot ^ "/waklog.conf" |
563e7792 | 81 | |
8a7c40fa | 82 | end |