K4ever install documentation
This commit is contained in:
parent
b06995f893
commit
bef462a86d
56
devel/README
56
devel/README
|
@ -1,55 +1,5 @@
|
||||||
Kassensystem
|
This is not the main documentation for k4ever. It resides in
|
||||||
############
|
k4ever/k4ever/docs or online somewhere at http://k4ever.someserver.de/
|
||||||
|
so go and take a look there.
|
||||||
Preamble
|
|
||||||
========
|
|
||||||
For ages there has been the discussion - Kassensystem!
|
|
||||||
|
|
||||||
So many attempts have been made, so many things have been discussed
|
|
||||||
and overengineered... But oh well, here is our attempt!
|
|
||||||
|
|
||||||
|
|
||||||
Mighty Kassensystem, finally!
|
|
||||||
|
|
||||||
Dependencies
|
|
||||||
============
|
|
||||||
- python-django >= 1.3
|
|
||||||
- python-django-auth-ldap
|
|
||||||
- python-django-piston
|
|
||||||
- easy-thumbnails
|
|
||||||
https://github.com/SmileyChris/easy-thumbnails.git
|
|
||||||
|
|
||||||
|
|
||||||
Installation Process
|
|
||||||
====================
|
|
||||||
|
|
||||||
1. Webserver
|
|
||||||
|
|
||||||
Some sort of Webserver is needed to host the django part. All about deploying
|
|
||||||
django can be found at https://docs.djangoproject.com/en/dev/howto/deployment/
|
|
||||||
Mostly this will be apache2 + mod_wsgi.
|
|
||||||
|
|
||||||
k4ever has static files which should be served by the webserver directly, so
|
|
||||||
be sure to turn off python for the media/ directory.
|
|
||||||
|
|
||||||
For development there is also djangos builtin webserver. You can use it via
|
|
||||||
./manage.py runserver but THIS SHOULD NEVER BE USED IN A PRODOCTIVE
|
|
||||||
ENVIRONMENT.
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
2. The database
|
|
||||||
- edit settings.py for database
|
|
||||||
- Add Usergroups: ('Normal User', 'Plugin') ( to be renamed)
|
|
||||||
- ./manage.py syncdb
|
|
||||||
- install script for needed data will be written.
|
|
||||||
|
|
||||||
|
|
||||||
Documentation
|
|
||||||
=============
|
|
||||||
|
|
||||||
Yes, there is more documentation than this readme! It is present
|
|
||||||
at k4ever/docs/, but if you want (and have python-sphinx) installed,
|
|
||||||
you can compile it to nice html (or pdf, ...) pages. There is a
|
|
||||||
``Makefile`` present to your assistance.
|
|
||||||
|
|
||||||
|
|
|
@ -11,6 +11,7 @@ Contents:
|
||||||
.. toctree::
|
.. toctree::
|
||||||
:maxdepth: 2
|
:maxdepth: 2
|
||||||
|
|
||||||
|
install
|
||||||
django/api
|
django/api
|
||||||
faq
|
faq
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,80 @@
|
||||||
|
.. This is the install documentation for a typical k4ever setup.
|
||||||
|
|
||||||
|
Installation
|
||||||
|
============
|
||||||
|
This is the installation manual for all the parts of k4ever.
|
||||||
|
|
||||||
|
k4ever Webinterface + API
|
||||||
|
-------------------------
|
||||||
|
The k4ever webinterface is a Django application. You will need some sort of
|
||||||
|
webserver and something that runs python code.
|
||||||
|
|
||||||
|
|
||||||
|
Dependencies
|
||||||
|
````````````
|
||||||
|
- django >= 1.3
|
||||||
|
- django-piston
|
||||||
|
- easy-thumbnails
|
||||||
|
- django-auth-ldap (if you want ldap support)
|
||||||
|
|
||||||
|
All of these are available via pip.
|
||||||
|
|
||||||
|
|
||||||
|
Webserver Configuration
|
||||||
|
```````````````````````
|
||||||
|
In this example configuration we will use apache2 + mod_wsgi, but there are
|
||||||
|
many other choices. These are described in Django's docs at `deploying Django
|
||||||
|
<https://docs.djangoproject.com/en/dev/howto/deployment/>_`.
|
||||||
|
|
||||||
|
k4ever has static files which should be served by the webserver directly, so
|
||||||
|
be sure this happens for the media/ directory.
|
||||||
|
|
||||||
|
Here is an apache2 example configuration::
|
||||||
|
|
||||||
|
<VirtualHost *:80>
|
||||||
|
ServerName k4ever.example.com
|
||||||
|
ServerAdmin k4ever@example.com
|
||||||
|
|
||||||
|
DocumentRoot "/home/k4ever/k4ever/"
|
||||||
|
|
||||||
|
Alias /media/ /home/k4ever/k4ever/k4ever/media/
|
||||||
|
<Location /media>
|
||||||
|
Options +FollowSymlinks
|
||||||
|
Options -Indexes
|
||||||
|
</Location>
|
||||||
|
|
||||||
|
# wsgi
|
||||||
|
WSGIScriptAlias / /home/k4ever/k4ever.wsgi
|
||||||
|
WSGIDaemonProcess k4ever user=k4ever group=k4ever processes=5 threads=1
|
||||||
|
WSGIProcessGroup k4ever
|
||||||
|
WSGIPassAuthorization On
|
||||||
|
</VirtualHost>
|
||||||
|
|
||||||
|
.. note::
|
||||||
|
|
||||||
|
You might want k4ever to be only reachable via https as k4ever's webinterface
|
||||||
|
and API depend upon password authentication. Not having encrypted connections
|
||||||
|
to your webserver will cause password loss.
|
||||||
|
|
||||||
|
Configuration
|
||||||
|
`````````````
|
||||||
|
Copy over the settings.py.template to settings.py. You can edit all the
|
||||||
|
settings fitting to your needs. Most of them are django switches, documented
|
||||||
|
`here <https://docs.djangoproject.com/en/dev/topics/settings/>_`. Some of them
|
||||||
|
are k4ever specific and have some inline documentation.
|
||||||
|
|
||||||
|
The **SECRET_KEY** variable has to be set by you. Just set it to something long
|
||||||
|
and kind of random. 60 characters should be sufficient.
|
||||||
|
|
||||||
|
If you want to add LDAP-Support to your instance of k4ever, edit the ldap
|
||||||
|
part of the config and make sure you have django-auth-ldap installed. All
|
||||||
|
users logging in via LDAP are added to djangos user database on login. They
|
||||||
|
have an invalid password, so they only can login via ldap. For more
|
||||||
|
documentation about this subject, look at django-auth-ldap's documentation.
|
||||||
|
|
||||||
|
If you want to see more settings (the parts we think nobody needs to change)
|
||||||
|
take a look at settings_default.py. DON'T overwrite them in there as it might
|
||||||
|
cause a *git pull* to fail, just put them in your settings.py and they will
|
||||||
|
get overridden.
|
||||||
|
|
||||||
|
|
|
@ -46,7 +46,6 @@ SECRET_KEY = ''
|
||||||
# LDAP configuration
|
# LDAP configuration
|
||||||
USE_LDAP = False
|
USE_LDAP = False
|
||||||
if USE_LDAP:
|
if USE_LDAP:
|
||||||
|
|
||||||
# For more information about the LDAP backend look the docs for
|
# For more information about the LDAP backend look the docs for
|
||||||
# django-auth-ldap - http://packages.python.org/django-auth-ldap/
|
# django-auth-ldap - http://packages.python.org/django-auth-ldap/
|
||||||
AUTH_LDAP_SERVER_URI = 'ldaps://your.server'
|
AUTH_LDAP_SERVER_URI = 'ldaps://your.server'
|
||||||
|
|
Loading…
Reference in New Issue