#!/bin/sh # # shell script to grant privileges to the bacula database # # Copyright (C) 2000-2020 Kern Sibbald # License: BSD 2-Clause; see file LICENSE-FOSS # db_user=${db_user:-@db_user@} bindir=@MYSQL_BINDIR@ db_name=${db_name:-@db_name@} db_password=@db_password@ if [ "$db_password" != "" ]; then pass="identified by '$db_password'" fi db_ssl_options=@db_ssl_options@ if [ "$db_ssl_options" != "" ]; then ssl_options="require $db_ssl_options" fi if $bindir/mysql $* -u root -f 2>/dev/null 1>/dev/null <