From 65048e2d575a9ad6d7552875e3110f55520cea60 Mon Sep 17 00:00:00 2001 From: Artyom Kazak Date: Wed, 19 Jun 2019 16:54:00 +0300 Subject: [PATCH] Gzip backups --- INSTALL.md | 2 ++ Makefile | 3 +++ 2 files changed, 5 insertions(+) diff --git a/INSTALL.md b/INSTALL.md index 03c64fa..66581f7 100644 --- a/INSTALL.md +++ b/INSTALL.md @@ -111,6 +111,8 @@ Next, create `upload.sh`: ~~~ cd /root/guide/state +rm -f *.gz +gzip -k -f *.log git add -A GIT_COMMITTER_NAME='auto' GIT_COMMITTER_EMAIL='' git commit --author="auto <>" -m "`date`" git push diff --git a/Makefile b/Makefile index cb73a99..3729615 100644 --- a/Makefile +++ b/Makefile @@ -16,6 +16,7 @@ back/db: rm -rf back/state git clone --depth 1 https://github.com/aelve/guide-database.git mv guide-database back/state + (cd back/state && gzip -d *.gz) # Test that the official database can be loaded .PHONY: back/test-db @@ -23,6 +24,7 @@ back/test-db: back if [ -d back/state ]; then mv back/state back/state-old; fi git clone --depth 1 https://github.com/aelve/guide-database.git mv guide-database back/state + (cd back/state && gzip -d *.gz) (cd back/state && git branch -v && git status && ls) stack exec --cwd back -- guide --dry-run rm -rf back/state @@ -41,6 +43,7 @@ back/travis-docker: rm -rf docker/back/files && mkdir docker/back/files git clone --depth 1 https://github.com/aelve/guide-database.git \ docker/back/files/state + (cd docker/back/files/state && gzip -d *.gz) rm -rf docker/back/files/state/.git cp .stack-work/install/*/*/*/bin/guide docker/back/files/ cp -R back/{static,templates} docker/back/files/