You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
16 lines
556 B
16 lines
556 B
#!/bin/bash -e
|
|
|
|
# Dump Databases
|
|
for DB in {{ seafile_db_ccnet }} {{ seafile_db_seafile }} {{ seafile_db_seahub }}; do
|
|
/usr/bin/mysqldump \
|
|
--quick --single-transaction \
|
|
{% if seafile_db_server not in ['127.0.0.1', 'localhost'] %}
|
|
--user='{{ seafile_db_user }}' \
|
|
--password='{{ seafile_db_pass }}' \
|
|
--host={{ seafile_db_server }} \
|
|
{% endif %}
|
|
--add-drop-table $DB | zstd -T0 -c > {{ seafile_root_dir }}/backup/$DB.sql.zst
|
|
done
|
|
|
|
# Mount fuse FS
|
|
{{ seafile_root_dir }}/seafile-server/seaf-fuse.sh start {{ seafile_root_dir }}/fuse/
|
|
|