Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Add 1.0.1 migration script.

  • Loading branch information...
commit d7bbbf9aeffe2e19bad67aad860f2e7619327b86 1 parent 73e373a
@onyxfish onyxfish authored
Showing with 38 additions and 0 deletions.
  1. +38 −0 scripts/migrations/1.0.0-to-1.0.1.sh
View
38 scripts/migrations/1.0.0-to-1.0.1.sh
@@ -0,0 +1,38 @@
+#!/bin/bash
+
+# PANDA Project migration script to ugprade version 1.0.0 to version 1.0.1.
+# Must be executed with sudo!
+
+set -x
+exec 1> >(tee /var/log/panda-upgrade-1.0.1.log) 2>&1
+
+echo "PANDA upgrade beginning."
+
+# Setup environment variables
+export DEPLOYMENT_TARGET="deployed"
+
+# Shutdown services
+service celeryd stop
+service nginx stop
+service uwsgi stop
+service solr stop
+
+# Fetch updated source code
+cd /opt/panda
+git pull
+git checkout 1.0.1
+
+# Update Python requirements
+pip install -U -r requirements.txt
+
+# Regenerate assets
+sudo -u panda -E python manage.py collectstatic --noinput
+
+# Restart services
+service solr start
+service uwsgi start
+service nginx start
+sudo service celeryd start
+
+echo "PANDA upgrade complete."
+
Please sign in to comment.
Something went wrong with that request. Please try again.