Skip to content
Snippets Groups Projects
Unverified Commit 592eb15c authored by Birte Kristina Friesel's avatar Birte Kristina Friesel
Browse files

add update.sh example script

parent 2f01ea6f
No related branches found
No related tags found
No related merge requests found
#!/bin/sh
#
# Updates a travelynx instance deployed via git. Performs database migrations
# as necessary.
git pull
if [ "$1" = "with-deps" ]; then
mkdir local.new
cd local.new
cp ../cpanfile* .
carton install
cd ..
sudo systemctl stop travelynx
mv local local.old
mv local.new/local .
perl index.pl database migrate
sudo systemctl start travelynx
elif perl index.pl database has-current-schema; then
sudo systemctl reload travelynx
else
sudo systemctl stop travelynx
perl index.pl database migrate
sudo systemctl start travelynx
fi
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment