From 6090e34854efa56ac998a0747defb04e934b2434 Mon Sep 17 00:00:00 2001 From: Fabien BOURGEOIS Date: Mon, 23 Jul 2018 10:17:33 +0200 Subject: [PATCH] [IMP]Odoobackup : allows different formats options per host (default zip) --- odoo/backups/launch.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/odoo/backups/launch.sh b/odoo/backups/launch.sh index abfdf7d..40630f1 100644 --- a/odoo/backups/launch.sh +++ b/odoo/backups/launch.sh @@ -6,12 +6,13 @@ index=0 IFS=':' read -ra ODOO_HOST <<< "$ODOO_HOST" IFS=':' read -ra ODOO_ADMIN_PASSWORD <<< "$ODOO_ADMIN_PASSWORD" IFS=':' read -ra ODOO_DATABASES <<< "$ODOO_DATABASES" +IFS=':' read -ra ODOO_FMT <<< "$ODOO_FMT" for host in "${ODOO_HOST[@]}" do HOST=${host} ADMIN_PASSWORD=${ODOO_ADMIN_PASSWORD[$index]} DATABASES=${ODOO_DATABASES[$index]} - FMT=${ODOO_FMT:='zip'} + FMT=${ODOO_FMT[$index]:='zip'} export HOST ADMIN_PASSWORD DATABASES FMT envsubst < /home/odoo/backup.template >> /home/odoo/backup.sh ((index++))