From 942d3eaf2300e60ce1a0abcce1304ceaaa85f9af Mon Sep 17 00:00:00 2001 From: Daniel Hansson Date: Mon, 24 Jul 2017 01:40:04 +0200 Subject: [PATCH] utf8mb4 --- nextcloud-startup-script.sh | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/nextcloud-startup-script.sh b/nextcloud-startup-script.sh index b6a06c44..3f05a075 100644 --- a/nextcloud-startup-script.sh +++ b/nextcloud-startup-script.sh @@ -275,9 +275,10 @@ echo "Please be patient, it may take a while." sudo /etc/init.d/mysql reload & spinner_loading #mysqladmin shutdown & spinner_loading #systemctl restart mariadb & spinner_loading -RESULT="mysqlshow --user=root --password=$MARIADBMYCNFPASS $NCCONFIGDB| grep -v Wildcard | grep -o $NCCONFIGDB" -if [ "$RESULT" == "$NCCONFIGDB" ]; then - check_command mysql -u root -e "ALTER DATABASE $NCCONFIGDB CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci;" +RESULT="$(mysqlshow --user=root --password=$MARIADBMYCNFPASS $NCCONFIGDB | grep -v Wildcard | grep -o $NCCONFIGDB)" +if [ "$RESULT" == "$NCCONFIGDB" ] +then + check_command 'mysql -u root -e "ALTER DATABASE $NCCONFIGDB CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci;"' wait fi check_command sudo -u www-data $NCPATH/occ config:system:set mysql.utf8mb4 --type boolean --value="true"