dépôts
/
lhc
/
ateliers.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Modification : vm_hosted -> etc/sv/*/configure.sh .
[lhc/ateliers.git]
/
etc
/
mysql
/
bin
/
createuser
diff --git a/etc/mysql/bin/createuser
b/etc/mysql/bin/createuser
new file mode 100755
(executable)
index 0000000..
bf58fea
--- /dev/null
+++ b/
etc/mysql/bin/createuser
@@ -0,0
+1,8
@@
+#!/bin/sh -eux
+user="$1"
+sudo mysql -u mysql --batch <<-EOF || true
+ DROP USER '$user'@'localhost';
+ EOF
+sudo mysql -u mysql --batch <<-EOF
+ CREATE USER '$user'@'localhost' IDENTIFIED WITH auth_socket;
+ EOF