Ansible roles
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.
 
 
 
 
 
 

13 lines
509 B

#!/bin/bash -e
/usr/bin/mysqldump \
{% if metabase_db_server not in ['localhost','127.0.0.1'] %}
--user={{ metabase_db_user | quote }} \
--password={{ metabase_db_pass | quote }} \
--host={{ metabase_db_server | quote }} \
--port={{ metabase_db_port | quote }} \
{% endif %}
--quick --single-transaction \
--add-drop-table {{ metabase_db_name | quote }} | zstd -c > {{ metabase_root_dir }}/backup/{{ metabase_db_name }}.sql.zst
cp {{ metabase_root_dir }}/etc/env {{ metabase_root_dir }}/backup/