From bc8f4403919597d6e6fa698547f4f251edc14241 Mon Sep 17 00:00:00 2001 From: rscnt Date: Mon, 8 Jun 2015 23:19:00 -0600 Subject: [PATCH] added Makefile with only one task "rsync_upload". I wanted to use fabric, but it's to much hassle. The rsync_upload task uploads the project using rsync by ssh. Signed-off-by: rscnt --- Makefile | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 Makefile diff --git a/Makefile b/Makefile new file mode 100644 index 00000000..bc2fad1f --- /dev/null +++ b/Makefile @@ -0,0 +1,20 @@ +PY?=python3 + +BASEDIR=$(CURDIR) + +SSH_HOST=dynamicweb-staging.ungleich.ch +SSH_PORT=22 +SSH_USER=app +SSH_TARGET_DIR=/home/$(SSH_USER)/dynamicweb + +help: + @echo 'Makefile for a dynamicweb website' + @echo ' ' + @echo 'Usage: ' + @echo ' make rsync_upload ' + +collectstatic: + $(PY?) $(BASEDIR)/manage.py collectstatic + +rsync_upload: + rsync -avz -e "ssh -p $(SSH_PORT)" --exclude .git --exclude .ropeproject --exclude __pycache__ --exclude *.psd $(BASEDIR) $(SSH_USER)@$(SSH_HOST):$(SSH_TARGET_DIR)