4 - sudo -u postgres psql
5 - postgres=# CREATE DATABASE pharos_dashboard
6 - postgres=# CREATE USER opnfv WITH PASSWORD 'opnfvopnfv'
7 - postgres# createuser --interactive
8 - postgres# ALTER ROLE opnfv SET client_encoding TO 'utf8';
9 - postgres# ALTER ROLE opnfv SET default_transaction_isolation TO 'read committed';
10 - postgres# ALTER ROLE opnfv SET timezone TO 'UTC';
11 - postgres# GRANT ALL PRIVILEGES ON DATABASE pharos_dashboard TO opnfv;
15 - log out all users, stop server
16 - (venv) # python manage.py dumpdata > dashboard/fixtures/<dump_name>.json
20 - setup clean database, run migrate
21 - (venv) # python manage.py loaddata <dump_name>
28 - # source venv/bin/activate
29 - (venv) # pip install -r requirements.txt
31 ** initializing or after change in models.py
33 - (venv) # python manage.py makemigrations
34 - (venv) # python manage.py migrate
38 - (venv) # python manage.py runserver
39 - (venv) # python manage.py shell
43 Javascript / CSS dependencies are managed with bower. To install them, you have to install bower, switch directory to the dashboard/static folder and run
45 Bower will download and install the right versions of all the static files.