The main model behind the zeeguu infrastructure.
Clone this repo
Create a new virtualenv
Run python setup.py install
or, for development run python setup.py develop
You must set ZEEGUU_CORE_CONFIG
as an environment variable
before you can run import zeeguu
. For an example of how that
file should look look see testing_default.cfg
. The config file
should contain login credentials to a DB that you will have to
create.
The tests overwrite the ZEEGUU_CORE_CONFIG
by setting it to
~/.config/zeeguu/core_test.cfg
.
- Clone the project
- Create a new Virtual Environment
- Activate your Virtual Environment by running
source bin/activate
from within the Virtual Environment folder
- Activate your Virtual Environment by running
- Run
pip install mysql
(if you don't have MySQL installed already) cd
into the project folder- Run
python setup
- Fix all the install exceptions.
- Run
mysql -u root
- Run
CREATE DATABASE zeeguu;
- Run
exit
- Run
- Run
mysql.server start
- Open the
testing_default.cfg
file- Change the value of
SQLALCHEMY_DATABASE_URI
from("mysql://zeeguu_test:zeeguu_test@localhost/zeeguu_test")
to("mysql://root@localhost/zeeguu")
- Save and close
testing_default.cfg
- Change the value of
- Let's check whether the Tests can be run and completed successfully.
- Make sure that the Virtual Environment is still active. Otherwise, redo Step 2.1
cd
into the project folder- Run
./run_tests.sh
- Check that all tests return 'ok'
- Finally, lets populate the database
- From inside the project folder, run
mkdir -p ~/.config/zeeguu/ && cp testing_default.cfg ~/.config/zeeguu/core.cfg
- Run
python zeeguu/populate.py
- The database should be populated by now.
- From inside the project folder, run
Install mysql and also the connection to python
apt-get install mysql-server libmysqlclient-dev python-mysqldb
apt-get install libxml2-dev libxslt1-dev