From 707c74c70084808b1a7a1bd172f88319e6062ca0 Mon Sep 17 00:00:00 2001 From: WilliamMiceli Date: Fri, 22 Nov 2019 23:23:50 -0500 Subject: [PATCH] And again --- scripts/mysql_setup.sh | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/scripts/mysql_setup.sh b/scripts/mysql_setup.sh index 7bb4dc2..d599e7c 100644 --- a/scripts/mysql_setup.sh +++ b/scripts/mysql_setup.sh @@ -1,2 +1,5 @@ -#!/bin/bash -mysql -u root -p -e /scripts/mysql_secure_install_equivalent.sql \ No newline at end of file +mysql -e "UPDATE mysql.user SET authentication_string=PASSWORD('{input_password_here}') WHERE User='root';" +mysql -e "DELETE FROM mysql.user WHERE User='root' AND Host NOT IN ('localhost', '127.0.0.1', '::1');" +mysql -e "DELETE FROM mysql.user WHERE User='';" +mysql -e "DELETE FROM mysql.db WHERE Db='test' OR Db='test_%';" +mysql -e "FLUSH PRIVILEGES;" \ No newline at end of file