aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--documentation/deployment.rst6
-rw-r--r--install.sh16
2 files changed, 18 insertions, 4 deletions
diff --git a/documentation/deployment.rst b/documentation/deployment.rst
index 3aedbb60..6d1b119c 100644
--- a/documentation/deployment.rst
+++ b/documentation/deployment.rst
@@ -81,12 +81,9 @@ Deploying the application on a traditional server
.. code-block:: bash
- $ sudo apt-get install python libpq-dev python-dev python-pip build-essential git
- $ sudo apt-get install libxml2-dev libxslt1-dev # for lxml
$ git clone https://bitbucket.org/cedricbonhomme/pyaggr3g470r.git
$ cd pyaggr3g470r
- $ sudo pip install --upgrade -r requirements.txt
- $ cp conf/conf.cfg-sample conf/conf.cfg
+ $ ./install.sh
If you want to use PostgreSQL
'''''''''''''''''''''''''''''
@@ -94,6 +91,7 @@ If you want to use PostgreSQL
.. code-block:: bash
$ sudo apt-get install postgresql postgresql-server-dev-9.3 postgresql-client
+ $ sudo pip install psycopg2
$ echo "127.0.0.1:5432:aggregator:pgsqluser:pgsqlpwd" > ~/.pgpass
$ chmod 700 ~/.pgpass
$ sudo -u postgres createuser pgsqluser --no-superuser --createdb --no-createrole
diff --git a/install.sh b/install.sh
new file mode 100644
index 00000000..8d62a0b6
--- /dev/null
+++ b/install.sh
@@ -0,0 +1,16 @@
+#! /usr/bin/env sh
+
+#
+# This script install all dependencies for pyAggr3g470r.
+# psycopg2 is removed from the requirements.txt file since it is only required
+# if the user wants to use Postgres. Postgres is generally used on the Heroku
+# platform.
+#
+
+sudo apt-get install python libpq-dev python-dev python-pip build-essential git
+sudo apt-get install libxml2-dev libxslt1-dev # for lxml
+
+sed -i '/psycopg2/d' requirements.txt
+sudo pip install --upgrade -r requirements.txt
+
+cp conf/conf.cfg-sample conf/conf.cfg
bgstack15