HCoop
/
hcoop
/
domtool2.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
MySQL re-granting
[hcoop/domtool2.git]
/
src
/
plugins
/
mysql.sml
diff --git
a/src/plugins/mysql.sml
b/src/plugins/mysql.sml
index
7f55e5f
..
5114e17
100644
(file)
--- a/
src/plugins/mysql.sml
+++ b/
src/plugins/mysql.sml
@@
-59,10
+59,17
@@
fun dropdb {user, dbname} =
else
SOME "Error executing DROP DATABASE script"
else
SOME "Error executing DROP DATABASE script"
+fun grant {user, dbname} =
+ if Slave.shell [Config.MySQL.grant, user, " ", dbname] then
+ NONE
+ else
+ SOME "Error executing GRANT script"
+
val _ = Dbms.register ("mysql", {getpass = SOME Client.getpass,
adduser = adduser,
passwd = passwd,
createdb = createdb,
val _ = Dbms.register ("mysql", {getpass = SOME Client.getpass,
adduser = adduser,
passwd = passwd,
createdb = createdb,
- dropdb = dropdb})
+ dropdb = dropdb,
+ grant = grant})
end
end