Execute GRANT statement as sipwise user

From: Michael Prokop <mprokop@sipwise.com>
2.6
Michael Prokop 13 years ago
parent a797075f13
commit 853870d974

@ -35,7 +35,7 @@ if [ -z "${SIPWISE_DB_PASSWORD}" ] ; then
exit 1
fi
if ! mysql -e "GRANT ALL PRIVILEGES ON *.* TO sipwise@localhost IDENTIFIED BY '${SIPWISE_DB_PASSWORD}' WITH GRANT OPTION;" ; then
if ! mysql -usipwise -p"${SIPWISE_DB_PASSWORD}" -e "GRANT ALL PRIVILEGES ON *.* TO sipwise@localhost IDENTIFIED BY '${SIPWISE_DB_PASSWORD}' WITH GRANT OPTION;" ; then
echo 'Error: grants for user sipwise on localhost could not be applied.' >&2
exit 1
fi

Loading…
Cancel
Save