mirror of
https://github.com/midoks/mdserver-web.git
synced 2026-10-23 10:04:02 +08:00
Update index.py
This commit is contained in:
@@ -323,13 +323,13 @@ def initMysql8Pwd():
|
||||
"alter user 'root'@'localhost' IDENTIFIED WITH mysql_native_password by '" + pwd + "';"
|
||||
alter_root_pwd = alter_root_pwd + "flush privileges;"
|
||||
|
||||
cmd_pass = serverdir + '/bin/mysqladmin -uroot password root'
|
||||
cmd_pass = 'mysqladmin -uroot password root'
|
||||
data = mw.execShell(cmd_pass)
|
||||
# print(data)
|
||||
|
||||
tmp_file = "/tmp/mysql_init_tmp.log"
|
||||
mw.writeFile(tmp_file, alter_root_pwd)
|
||||
cmd_pass = serverdir + '/bin/mysql -uroot -proot < ' + tmp_file
|
||||
cmd_pass = 'mysql -uroot -proot < ' + tmp_file
|
||||
|
||||
data = mw.execShell(cmd_pass)
|
||||
# print(data)
|
||||
|
||||
Reference in New Issue
Block a user