Skip to content

Commit

Permalink
cats: set MySQL/SQLite make bareos tables deprecated
Browse files Browse the repository at this point in the history
  • Loading branch information
fbergkemper committed Aug 5, 2020
1 parent c392fda commit 7cd0b36
Showing 1 changed file with 6 additions and 10 deletions.
16 changes: 6 additions & 10 deletions core/src/cats/make_bareos_tables.in
Expand Up @@ -110,18 +110,14 @@ fi

case ${db_type} in
sqlite3)
sqlite3 $* ${working_dir}/${db_name}.db < ${temp_sql_schema}
chmod 640 ${working_dir}/${db_name}.db
retval=0
echo "The SQLite database backend is deprecated. Please use PostgreSQL instead."
echo "Creation of Bareos SQLite tables aborted."
retval=1
;;
mysql)
mysql $* --database=${db_name} -f < ${temp_sql_schema}
retval=$?
if test $retval = 0; then
echo "Creation of Bareos MySQL tables succeeded."
else
echo "Creation of Bareos MySQL tables failed."
fi
echo "The MySQL database backend is deprecated. Please use PostgreSQL instead."
echo "Creation of Bareos MySQL tables aborted."
retval=1
;;
postgresql)
PGOPTIONS='--client-min-messages=warning' psql -f ${temp_sql_schema} -d ${db_name} $*
Expand Down

0 comments on commit 7cd0b36

Please sign in to comment.