0993234f25df110068534835213450b43a3a9ace
[hcoop/domtool2.git] / src / main.sig
1 (* HCoop Domtool (http://hcoop.sourceforge.net/)
2 * Copyright (c) 2006, Adam Chlipala
3 *
4 * This program is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU General Public License
6 * as published by the Free Software Foundation; either version 2
7 * of the License, or (at your option) any later version.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
17 *)
18
19 (* Main interface *)
20
21 signature MAIN = sig
22
23 val init : unit -> unit
24 val setupUser : unit -> string
25
26 val check : Env.env -> string -> Env.env * Ast.exp option
27 val check' : Env.env -> string -> Env.env
28 val checkDir : string -> unit
29
30 val basis : unit -> Env.env
31
32 val reduce : Env.env -> string -> Env.env * Ast.exp option
33 val eval : Env.env -> Env.env_vars -> string -> Env.env * Env.env_vars
34
35 val request : string * string option -> unit
36 val requestDir : string -> unit
37
38 val requestPing : unit -> OS.Process.status
39 val requestShutdown : unit -> unit
40 val requestGrant : Acl.acl -> unit
41 val requestRevoke : Acl.acl -> unit
42 val requestListPerms : string -> (string * string list) list option
43 val requestWhoHas : {class : string, value : string} -> string list option
44 val requestRmdom : string list -> unit
45 val requestRegen : unit -> unit
46 val requestRegenTc : unit -> unit
47 val requestRmuser : string -> unit
48 val requestDescribe : string -> unit
49 val requestReUsers : unit -> unit
50
51 val requestSlavePing : unit -> OS.Process.status
52 val requestSlaveShutdown : unit -> unit
53
54 val service : unit -> unit
55 val slave : unit -> unit
56
57 val listBasis : unit -> string list
58 val autodocBasis : string -> unit
59
60 val requestDbUser : {dbtype : string, passwd : string option} -> unit
61 val requestDbPasswd : {dbtype : string, passwd : string} -> unit
62 val requestDbTable : {dbtype : string, dbname : string, encoding : string option} -> unit
63 val requestDbDrop : {dbtype : string, dbname : string} -> unit
64 val requestDbGrant : {dbtype : string, dbname : string} -> unit
65
66 val requestListMailboxes : string -> Vmail.listing
67 val requestNewMailbox : {domain : string, user : string,
68 passwd : string, mailbox : string} -> unit
69 val requestPasswdMailbox : {domain : string, user : string, passwd : string}
70 -> unit
71 val requestRmMailbox : {domain : string, user : string} -> unit
72
73 val requestSaQuery : string -> unit
74 val requestSaSet : string * bool -> unit
75
76 val requestSmtpLog : string -> unit
77
78 val requestMysqlFixperms : unit -> unit
79
80 val requestApt : {node : string, pkg : string} -> OS.Process.status
81 val requestAptExists : {node : string, pkg : string} -> OS.Process.status
82 val requestCron : {node : string, uname : string} -> OS.Process.status
83 val requestFtp : {node : string, uname : string} -> OS.Process.status
84 val requestTrustedPath : {node : string, uname : string} -> OS.Process.status
85 val requestSocketPerm : {node : string, uname : string} -> OS.Process.status
86 val requestFirewall : {node : string, uname : string} -> OS.Process.status
87
88 val requestFirewallRegen : string -> OS.Process.status
89 end