From ea5f78d172c2932b6f72dd95bc0462919e5d5a62 Mon Sep 17 00:00:00 2001 From: "Glenn Y. Rolland" Date: Wed, 5 Dec 2018 22:15:03 +0100 Subject: [PATCH] Upgrade to latest version --- Dockerfile | 10 +++++----- gx-backup-erp | 20 ++++++++++++++++++++ 2 files changed, 25 insertions(+), 5 deletions(-) create mode 100755 gx-backup-erp diff --git a/Dockerfile b/Dockerfile index 00e03bc..f0bbd0b 100644 --- a/Dockerfile +++ b/Dockerfile @@ -21,13 +21,13 @@ RUN curl -sS https://getcomposer.org/installer \ | php -- --install-dir=/usr/local/bin --filename=composer RUN wget \ - -O /tmp/dolibarr-7.0.0.zip \ - https://github.com/Dolibarr/dolibarr/archive/7.0.0.zip + -O /tmp/dolibarr-8.0.3.zip \ + https://github.com/Dolibarr/dolibarr/archive/8.0.3.zip -RUN unzip -d /usr/src /tmp/dolibarr-7.0.0.zip \ - && chown -R www-data:www-data /usr/src/dolibarr-7.0.0 \ +RUN unzip -d /usr/src /tmp/dolibarr-8.0.3.zip \ + && chown -R www-data:www-data /usr/src/dolibarr-8.0.3 \ && rm -fr /var/www/html \ - && cp -a /usr/src/dolibarr-7.0.0 /var/www/html + && cp -a /usr/src/dolibarr-8.0.3 /var/www/html ADD php-uploads.ini /usr/local/etc/php/conf.d/glenux-uploads.ini ADD php-performance.ini /usr/local/etc/php/conf.d/glenux-performance.ini diff --git a/gx-backup-erp b/gx-backup-erp new file mode 100755 index 0000000..0486875 --- /dev/null +++ b/gx-backup-erp @@ -0,0 +1,20 @@ +#!/bin/sh + +set -x + +DATE="$(date --iso-8601)" +DISPLAY=:0 + +BACKUP_DIR="$HOME/Documents/Backup" + +echo "Exporting database dump" +/usr/bin/setsid ssh apps.glenux.net \ + dokku mariadb:export erp \ + > "$BACKUP_DIR/net.glenux.apps.erp.$DATE.sql" + +echo "Exporting files" +/usr/bin/setsid ssh apps.glenux.net \ + docker exec erp.web.1 \ + "bash -c 'cd /var/www/html/documents ; tar czf - .'" \ + > "$BACKUP_DIR/net.glenux.apps.erp.$DATE.tar.gz" +