From cedcdd3273577bff4f4d0de7c5d83a56113bc315 Mon Sep 17 00:00:00 2001 From: wes Date: Sat, 25 Feb 2017 13:15:30 -0500 Subject: [PATCH] local build task --- fabfile.py | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/fabfile.py b/fabfile.py index 28104bc..1eb9781 100644 --- a/fabfile.py +++ b/fabfile.py @@ -45,6 +45,15 @@ def serveUp(): sudo("systemctl enable search.service") sudo("systemctl restart search.service") +@task +def serveUpLocal(): + local("sudo rm -fr /srv/http/build") + local("sudo cp -r /home/wes/TextbookEngine/build/ /srv/http/build") + local("sudo cp /home/wes/TextbookEngine/build/search.service /etc/systemd/system/search.service") + local("sudo systemctl daemon-reload") + local("sudo systemctl enable search.service") + local("sudo systemctl restart search.service") + @task def buildVenv(): with cd("~/tbookbuild"): @@ -69,3 +78,13 @@ def build(): upload() buildVenv() serveUp() + +@task +def buildLocal(): + makeBuild() + buildTags() + uglify() + sass() + copy() + buildLocalVenv() + serveUpLocal()