{{Request redirection of all mail from the source to the target, specifying on
which nodes this redirection should be applied.}}
-val alias = \user -> \email -> aliasPrim (userSource user) (addressTarget email);
+val emailAlias = \user -> \email -> aliasPrim (userSource user) (addressTarget email);
{{Redirect mail for the user at the current domain to the e-mail address.}}
val aliasMulti = \user -> \emails -> aliasPrim (userSource user) (addressesTarget emails);
{{Redirect mail for the user at the current domain to all of the e-mail
extern type no_spaces;
{{Any string with no space characters}}
+extern type no_newlines;
+{{Any string with no newline characters}}
+
extern type ip;
{{An IP address}}
--- /dev/null
+{{Basic Apache URL handling}}
+
+extern val alias : location -> your_path -> [Vhost];
+{{All requests for the location should be served from the path.}}
+
+extern val scriptAlias : location -> your_path -> [Vhost];
+{{Like <tt>alias</tt>, for Apache's <tt>ScriptAlias</tt>}}
+
+extern val errorDocument : no_spaces -> no_newlines -> [^Vhost];
+{{The first argument specifies an HTTP error code, which should be handled using
+ the second argument, which is either a URL or a string to display.}}
val _ = Env.type_one "no_spaces"
Env.string
(CharVector.all (fn ch => not (Char.isSpace ch)))
+val _ = Env.type_one "no_newlines"
+ Env.string
+ (CharVector.all (fn ch => ch <> #"\n" andalso ch <> #"\r"))
val _ = Env.type_one "ip"
Env.string
write "]");
write "\n"))
+val () = Env.action_two "alias"
+ ("from", Env.string, "to", Env.string)
+ (fn (from, to) =>
+ (write "\tAlias\t";
+ write from;
+ write " ";
+ write to;
+ write "\n"))
+
+val () = Env.action_two "scriptAlias"
+ ("from", Env.string, "to", Env.string)
+ (fn (from, to) =>
+ (write "\tScriptAlias\t";
+ write from;
+ write " ";
+ write to;
+ write "\n"))
+
+val () = Env.action_two "errorDocument"
+ ("code", Env.string, "handler", Env.string)
+ (fn (code, handler) =>
+ (write "\tErrorDocument\t";
+ write code;
+ write " ";
+ write handler;
+ write "\n"))
+
+
end
proxyPass "/proxyLand" "http://localhost:1234/otherProxyLand";
proxyPassReverse "/proxyLand" "http://localhost:1234/otherProxyLand";
+ scriptAlias "/cgi-bin/that-script" "/home/adamc/cgi/here-it-is";
+ errorDocument "404" "I just couldn't find it.";
+
directory "/home/adamc/thisPlace" with
rewriteRule "A" "B" [];
end
vhost "lists" with
proxyPass "/mailman" "http://hcoop.net/cgi-bin/mailman";
+ alias "/doc/mailman" "/home/adamc/mailman"
end
end