From 3ba932209fc33206a28483d07fb0e108d1b16a2b Mon Sep 17 00:00:00 2001 From: jaseg Date: Mon, 4 Jul 2022 23:57:28 +0200 Subject: gerboweb: add deployment stuff --- gerboweb/develop-startup.sh | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100755 gerboweb/develop-startup.sh (limited to 'gerboweb/develop-startup.sh') diff --git a/gerboweb/develop-startup.sh b/gerboweb/develop-startup.sh new file mode 100755 index 0000000..8723ab0 --- /dev/null +++ b/gerboweb/develop-startup.sh @@ -0,0 +1,22 @@ +#!/bin/sh + +set -e + +cd /gerbolyze/gerbonara +echo "### Setting up gerbonara ###" +# newer pip is buggy and just crashes so we pinned an old version. +# python packaging infrastructure is such an incoherent, buggy mess +# also ignore the running pip as root warning, it's dumb and here we actually want to do just that. +python3 -m pip --disable-pip-version-check install . +cd /gerbolyze +echo "### Setting up gerbolyze ###" +python3 -m pip --disable-pip-version-check install . + +export PATH=$PATH:$HOME/.cargo/bin +cd /gerbolyze/gerboweb +echo "### Launching app ###" +tmux new-session -d -s dev env GERBOWEB_SETTINGS=gerboweb-develop.cfg FLASK_APP=gerboweb.py flask run -h 0.0.0.0 +tmux bind -n C-q kill-session +tmux rename-window gerboweb +tmux split-window -t 0 -v python3 job_processor.py /var/cache/job_queue.sqlite3 +tmux attach -- cgit