From 7bde250178ea8df00d255de13dbb04fb2310e36d Mon Sep 17 00:00:00 2001 From: nicholai Date: Tue, 16 Sep 2025 12:56:14 -0600 Subject: [PATCH] Fix MariaDB bootstrap: use 'FLUSH PRIVILEGES' (no parentheses) and update .dockerignore --- .dockerignore | 4 ++++ docker/entrypoint.sh | 4 ++-- 2 files changed, 6 insertions(+), 2 deletions(-) create mode 100644 .dockerignore diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 0000000..cfa99b7 --- /dev/null +++ b/.dockerignore @@ -0,0 +1,4 @@ +seafile-server/ +seahub/ +.seafile-data/ +.git diff --git a/docker/entrypoint.sh b/docker/entrypoint.sh index 34648f4..6c1c75f 100644 --- a/docker/entrypoint.sh +++ b/docker/entrypoint.sh @@ -161,7 +161,7 @@ init_mariadb() { log "Configuring root password and seafile database" "${MYSQL_BIN}" --protocol=socket --socket=/run/mysqld/mysqld.sock -uroot <<-SQL ALTER USER 'root'@'localhost' IDENTIFIED BY '${DB_ROOT_PASSWORD}'; - FLUSH PRIVILEGES(); + FLUSH PRIVILEGES; SQL "${MYSQL_BIN}" --protocol=socket --socket=/run/mysqld/mysqld.sock -uroot -p"${DB_ROOT_PASSWORD}" <<-SQL @@ -177,7 +177,7 @@ SQL GRANT ALL PRIVILEGES ON \`${DB_NAME_CCNET:-ccnet_db}\`.* TO '${DB_USER}'@'localhost'; GRANT ALL PRIVILEGES ON \`${DB_NAME_SEAHUB:-seahub_db}\`.* TO '${DB_USER}'@'localhost'; - FLUSH PRIVILEGES(); + FLUSH PRIVILEGES; SQL log "Shutting down temporary MariaDB"