diff options
author | François Schmidts <francois.schmidts@gmail.com> | 2015-04-06 10:37:13 +0200 |
---|---|---|
committer | François Schmidts <francois.schmidts@gmail.com> | 2015-04-06 10:37:13 +0200 |
commit | 29bb2a36f0b5d1781ab05f1976aa0c5017351807 (patch) | |
tree | 52b2dd87f4d36f6a9c518cc14f96e523b1dea045 /documentation/deployment.rst | |
parent | misc update (diff) | |
parent | Minor changes to the CSS. (diff) | |
download | newspipe-29bb2a36f0b5d1781ab05f1976aa0c5017351807.tar.gz newspipe-29bb2a36f0b5d1781ab05f1976aa0c5017351807.tar.bz2 newspipe-29bb2a36f0b5d1781ab05f1976aa0c5017351807.zip |
Merge remote-tracking branch 'upstream/master'
Conflicts:
pyaggr3g470r/controllers/feed.py
pyaggr3g470r/templates/home.html
Diffstat (limited to 'documentation/deployment.rst')
-rw-r--r-- | documentation/deployment.rst | 59 |
1 files changed, 20 insertions, 39 deletions
diff --git a/documentation/deployment.rst b/documentation/deployment.rst index 8a7f098d..59080b89 100644 --- a/documentation/deployment.rst +++ b/documentation/deployment.rst @@ -3,7 +3,8 @@ Deployment This application can be deployed on Heroku or on a traditional server. -After installation, you will be able to connect with the email *root@pyAggr3g470r.localhost* and the password *password*. +After installation, you will be able to connect with the email +*root@pyAggr3g470r.localhost* and the password *password*. Deploying the application with Vagrant -------------------------------------- @@ -13,8 +14,8 @@ Installation of VirtualBox and Vagrant .. code-block:: bash $ sudo apt-get install virtualbox - $ wget https://dl.bintray.com/mitchellh/vagrant/vagrant_1.6.5_x86_64.deb - $ sudo dpkg -i vagrant_1.6.5_x86_64.deb + $ wget https://dl.bintray.com/mitchellh/vagrant/vagrant_1.7.2_x86_64.deb + $ sudo dpkg -i vagrant_1.7.2_x86_64.deb Deployment of pyAggr3g470r @@ -45,7 +46,8 @@ The geek way $ heroku run init $ heroku ps:scale web=1 -To enable account creation for users, you have to set some environment variables: +To enable account creation for users, you have to set some environment +variables: .. code-block:: bash @@ -79,50 +81,27 @@ 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 + $ cd pyaggr3g470r/ If you want to use PostgreSQL ''''''''''''''''''''''''''''' - .. code-block:: bash - $ sudo apt-get install postgresql postgresql-server-dev-9.3 postgresql-client - $ 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 - $ createdb aggregator --no-password - $ echo "ALTER USER pgsqluser WITH ENCRYPTED PASSWORD 'pgsqlpwd';" | sudo -u postgres psql - $ echo "GRANT ALL PRIVILEGES ON DATABASE aggregator TO pgsqluser;" | sudo -u postgres psql - -Edit the configuration file with the line: - -.. code-block:: cfg - - [database] - uri = postgres://pgsqluser:pgsqlpwd@127.0.0.1:5433/aggregator + $ ./install.sh postgres If you want to use SQLite ''''''''''''''''''''''''' -Just edit the configuration file with the line: - -.. code-block:: cfg +.. code-block:: bash - [database] - uri = sqlite+pysqlite:///pyAggr3g470r.db + $ ./install.sh sqlite Finally: .. code-block:: bash - $ python manager.py db_create $ python runserver.py * Running on http://0.0.0.0:5000/ * Restarting with reloader @@ -131,20 +110,22 @@ Finally: Configuration ============= -Configuration (database url, email, proxy, user agent, etc.) is done via the file *conf/conf.cfg*. -Check these configuration before executing *db_create.py*. -If you want to use pyAggr3g470r with Tor/Privoxy, you just have to set the value of -*http_proxy* (most of the time: *http_proxy = 127.0.0.1:8118**). Else leave the value blank. +Configuration (database url, email, proxy, user agent, etc.) is done via the +file `conf/conf.cfg`. +Check this file before initializing the database (with `manager.py`). + +If you want to use pyAggr3g470r with Tor/Privoxy, you just have to set the value +of `http_proxy` (most of the time: `http_proxy = 127.0.0.1:8118`). Else leave +the value blank. Automatic updates ================= -You can fetch new articles with `cron <https://en.wikipedia.org/wiki/Cron>`_ and the script *fetch.py*. -For example if you want to check for updates every 30 minutes, add this line to your cron rules (*crontab -e*): +You can fetch new articles with `cron <https://en.wikipedia.org/wiki/Cron>`_. +For example if you want to check for updates every 30 minutes, add this line to +your cron rules (*crontab -e*): .. code-block:: bash */30 * * * * cd ~/.pyaggr3g470r/ ; python manager.py fetch_asyncio None None - -You must give the email address you use to login to pyAggr3g470r. |