distro-tracker.README.Debian 2.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273
  1. Notes concerning the distro-tracker Debian package
  2. --------------------------------------------------
  3. Initial setup
  4. -------------
  5. The package does quite some work for you but you still have some things
  6. to take care of:
  7. 1/ by default, the package is configured to use a PostgreSQL database
  8. using the default local unix socket and the authentication is done at
  9. the user level. The package creates a "distro-tracker" Unix account,
  10. you must create a "distro-tracker" database that can be managed by the
  11. "distro-tracker" user. You can do this with:
  12. $ sudo -u postgres createuser -D -R -S distro-tracker
  13. $ sudo -u postgres createdb -O distro-tracker distro-tracker
  14. If the default database configuration doesn't suit you, go
  15. edit /etc/distro-tracker/settings/db_postgresql.py.
  16. 2/ the Distro Tracker has many configuration options, you should review
  17. its documentation and /etc/distro-tracker/settings/* and update
  18. /etc/distro-tracker/settings/local.py according to your wishes.
  19. 3/ you must initialize the database:
  20. $ sudo -u distro-tracker distro-tracker migrate
  21. 4/ you must configure a webserver (see below for details on how to use
  22. nginx + gunicorn or apache2 + mod_wsgi).
  23. Configuration with Nginx + Gunicorn
  24. -----------------------------------
  25. If you wish to use nginx, you should also install gunicorn (they are
  26. probably already installed by way of dependencies unless you already had a
  27. webserver installed).
  28. The package provides a sample gunicorn configuration to run the Distro
  29. Tracker application on /var/lib/distro-tracker/gunicorn.sock and the
  30. corresponding nginx virtual host.
  31. $ sudo apt-get install nginx gunicorn
  32. $ sudo cp /etc/gunicorn.d/distro-tracker.example \
  33. /etc/gunicorn.d/distro-tracker
  34. $ sudo service gunicorn restart
  35. $ sudo vim /etc/nginx/sites-available/distro-tracker
  36. $ sudo ln -sf /etc/nginx/sites-available/distro-tracker \
  37. /etc/nginx/sites-enabled
  38. $ sudo service nginx restart
  39. Configuration with Apache + mod_wsgi
  40. ------------------------------------
  41. If you wish to use apache2, you should also install libapache2-mod-wsgi.
  42. The package provides a sample virtual host configuration file that
  43. you can customize and enable:
  44. $ sudo apt-get install apache2 libapache2-mod-wsgi
  45. $ sudo vim /etc/apache2/sites-available/distro-tracker
  46. $ sudo a2enmod ssl
  47. $ sudo a2ensite distro-tracker
  48. What the package does for you
  49. -----------------------------
  50. * Create the "distro-tracker" user
  51. * Collect static files in /var/lib/distro-tracker/static/
  52. (to do it yourself: sudo -u distro-tracker distro-tracker collectstatic)
  53. * Provide ready to customize configuration files for nginx/gunicorn
  54. and apache/mod_wsgi