Memopol installation : Différence entre versions
(Creation from README.md) |
|||
(3 révisions intermédiaires par un autre utilisateur non affichées) | |||
Ligne 1 : | Ligne 1 : | ||
{{Infobox Version|en=Memopol_(en)|fr=Memopol_(fr)}} | {{Infobox Version|en=Memopol_(en)|fr=Memopol_(fr)}} | ||
− | [ | + | [[Memopol|Political Memory]] is a toolbox designed by La Quadrature du Net to help european citizens to reach members of European Parliament (MEPs), and track their voting records. |
− | + | ||
+ | = Installation for development = | ||
Memopol with lqdn's customization is little bit more complex to install than a normal django project, but not that much more complicated. | Memopol with lqdn's customization is little bit more complex to install than a normal django project, but not that much more complicated. | ||
− | ==== Debian and debian-based | + | == Architecture specific == |
+ | |||
+ | === Debian and debian-based === | ||
Install the base python virtualenv tools (on Ubuntu you have to enable universe): | Install the base python virtualenv tools (on Ubuntu you have to enable universe): | ||
− | sudo apt-get install python-setuptools python-dev libxml2-dev libxslt1-dev libfreetype6-dev libpng12-dev python-pip libatlas-base-dev g++ mercurial git libtidy-dev imagemagick ruby-sass | + | sudo apt-get install python-setuptools python-dev libxml2-dev libxslt1-dev libfreetype6-dev libpng12-dev python-pip |
+ | libatlas-base-dev g++ mercurial git libtidy-dev imagemagick ruby-sass | ||
sudo pip install virtualenv | sudo pip install virtualenv | ||
− | + | === Archlinux === | |
Install the following to have the tools on Archlinux (please note that you may have to adapt the following install procedure): | Install the following to have the tools on Archlinux (please note that you may have to adapt the following install procedure): | ||
− | pacman -S python2 libxml2 libxslt freetype2 python-lxml python2-pip python2-virtualenv libpng mercurial git imagemagick tidyhtml ruby-sass | + | pacman -S python2 libxml2 libxslt freetype2 python-lxml python2-pip python2-virtualenv libpng mercurial git imagemagick |
+ | tidyhtml ruby-sass | ||
− | + | === Fedora === | |
Install the following to have the tools on Fedora (please note that you may have to adapt the following install procedure): | Install the following to have the tools on Fedora (please note that you may have to adapt the following install procedure): | ||
− | yum install python-setuptools python-devel libxml2-devel libxslt-devel freetype freetype-devel libpng libpng-devel python-lxml python-pip atlas-devel g++ mercurial git imagemagick rubygem-sass | + | yum install python-setuptools python-devel libxml2-devel libxslt-devel freetype freetype-devel libpng libpng-devel python-lxml |
+ | python-pip atlas-devel g++ mercurial git imagemagick rubygem-sass | ||
+ | pip-python install virtualenv | ||
+ | |||
+ | === OpenSuse === | ||
+ | |||
+ | Install the following to have the tools on OpenSuse (please note that you may have to adapt the following install procedure): | ||
+ | |||
+ | to come... | ||
− | |||
− | + | == Python dependencies == | |
In a directory: | In a directory: | ||
Ligne 43 : | Ligne 55 : | ||
pip install -r ../memopol-core/requirements.txt | pip install -r ../memopol-core/requirements.txt | ||
− | + | === Virtualenv === | |
− | |||
− | |||
− | |||
− | |||
To enter the virtualenv | To enter the virtualenv | ||
Ligne 57 : | Ligne 65 : | ||
deactivate | deactivate | ||
− | + | ||
+ | == Build the db == | ||
+ | |||
+ | === Db creation === | ||
Simply: | Simply: | ||
Ligne 63 : | Ligne 74 : | ||
python manage.py init | python manage.py init | ||
− | + | '''You will have an error like this "ContentType matching query does not exist.", just redo the command a second time and this will be working. This | |
− | exist.", just redo the command a second time and this will be working. | + | is a known bug that we haven't got the time to fix.''' |
− | is a known bug that we haven't got the time to fix. | + | |
+ | === Db update === | ||
+ | |||
+ | You'll probably want to run this command to update your database: | ||
+ | |||
+ | python manage.py update_meps | ||
− | + | And you should be done. | |
+ | |||
+ | |||
+ | == Run the server == | ||
python manage.py runserver | python manage.py runserver | ||
Ligne 78 : | Ligne 97 : | ||
You can find more informations on how to use memopol in the memopol-core [README.md](https://gitorious.org/memopol2-0/memopol-core/blobs/master/README.md) | You can find more informations on how to use memopol in the memopol-core [README.md](https://gitorious.org/memopol2-0/memopol-core/blobs/master/README.md) | ||
− | + | [[Category:Memopol]] | |
− | |||
− |
Version actuelle datée du 29 juillet 2015 à 19:55
Political Memory is a toolbox designed by La Quadrature du Net to help european citizens to reach members of European Parliament (MEPs), and track their voting records.
Sommaire
Installation for development[modifier]
Memopol with lqdn's customization is little bit more complex to install than a normal django project, but not that much more complicated.
Architecture specific[modifier]
Debian and debian-based[modifier]
Install the base python virtualenv tools (on Ubuntu you have to enable universe):
sudo apt-get install python-setuptools python-dev libxml2-dev libxslt1-dev libfreetype6-dev libpng12-dev python-pip libatlas-base-dev g++ mercurial git libtidy-dev imagemagick ruby-sass sudo pip install virtualenv
Archlinux[modifier]
Install the following to have the tools on Archlinux (please note that you may have to adapt the following install procedure):
pacman -S python2 libxml2 libxslt freetype2 python-lxml python2-pip python2-virtualenv libpng mercurial git imagemagick tidyhtml ruby-sass
Fedora[modifier]
Install the following to have the tools on Fedora (please note that you may have to adapt the following install procedure):
yum install python-setuptools python-devel libxml2-devel libxslt-devel freetype freetype-devel libpng libpng-devel python-lxml python-pip atlas-devel g++ mercurial git imagemagick rubygem-sass pip-python install virtualenv
OpenSuse[modifier]
Install the following to have the tools on OpenSuse (please note that you may have to adapt the following install procedure):
to come...
Python dependencies[modifier]
In a directory:
git clone git://gitorious.org/memopol2-0/memopol2-0.git git clone git://gitorious.org/memopol2-0/memopol-core.git cd memopol2-0 ln -s ../memopol-core/memopol . virtualenv ve source ve/bin/activate pip install -r requirements-dev.txt pip install numpy pip install -r ../memopol-core/requirements.txt
Virtualenv[modifier]
To enter the virtualenv
source ve/bin/activate
To quit the virtualenv
deactivate
Build the db[modifier]
Db creation[modifier]
Simply:
python manage.py init
You will have an error like this "ContentType matching query does not exist.", just redo the command a second time and this will be working. This is a known bug that we haven't got the time to fix.
Db update[modifier]
You'll probably want to run this command to update your database:
python manage.py update_meps
And you should be done.
Run the server[modifier]
python manage.py runserver
Your application is available on http://localhost:8000/
And you're done, but you might want to take a look at the next section depending on what you want to dev.
You can find more informations on how to use memopol in the memopol-core [README.md](https://gitorious.org/memopol2-0/memopol-core/blobs/master/README.md)