Detected 1 occurrence(s) of ‘create user .* identified by’: ql.db where Db='test' OR Db='test\_%'") flush_privileges end def self.create_user(user, password, host) if !user_exists(user, host) Chef::Log.info("User #{user} at #{host} doesnt exists.Creating one ...") @connection.query("create user '#{user}'@'#{host}' identified by '#{password}'") flush_privileges else Chef::Log.info("User #{root} at #{host} exists.Just updating password ...") update_password(user, password, host) end end def self.update_password(user, password, […]
↧