From 85f69abc9779dd28c0dfdf128aa4c77e08fe3b7f Mon Sep 17 00:00:00 2001 From: Matthijs Kooijman Date: Thu, 1 Jan 2009 19:56:12 +0100 Subject: [PATCH] mysql: Properly set the path to .my.conf when vservers are used. This fixes the case when the user option and the vsname option are both used. --- handlers/mysql.in | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/handlers/mysql.in b/handlers/mysql.in index d22ef26..3a908f6 100644 --- a/handlers/mysql.in +++ b/handlers/mysql.in @@ -161,7 +161,11 @@ else debug "User home set to: $userhome" [ -f $userhome/.my.cnf ] || fatal "Can't find config file in $userhome/.my.cnf" - defaultsfile="--defaults-extra-file=$userhome/.my.cnf" + if [ $usevserver = yes ]; then + defaultsfile="--defaults-extra-file=$vuserhome/.my.cnf" + else + defaultsfile="--defaults-extra-file=$userhome/.my.cnf" + fi debug "using $defaultsfile" fi -- 2.30.2