From 3dac3aa1a580f04376a1c16d2416f34351b14adb Mon Sep 17 00:00:00 2001 From: Nawa Date: Thu, 29 Nov 2012 23:54:29 +0100 Subject: Documentation: new corrections, mainly on the administration part --- docs/_build/html/install.html | 82 +++++++++++++++++++++++-------------------- 1 file changed, 43 insertions(+), 39 deletions(-) (limited to 'docs/_build/html/install.html') diff --git a/docs/_build/html/install.html b/docs/_build/html/install.html index 3121524..6aaf672 100644 --- a/docs/_build/html/install.html +++ b/docs/_build/html/install.html @@ -130,7 +130,7 @@ to the applications’ websites.

Database configuration

Now that postgres and postgis are installed, you need to create a new user for -chimere:

+Chimère:

su postgres
 createuser --echo --adduser --createdb --encrypted --pwprompt chimere-user
@@ -143,8 +143,8 @@ psql -d chimere -f /usr/share/postgresql/$PG_VERSION/contrib/postgis-1.5/postgis psql -d chimere -f /usr/share/postgresql/$PG_VERSION/contrib/postgis-1.5/spatial_ref_sys.sql
-
-

Install the sources

+
+

Installing the sources

Choose a path to install your Chimère:

INSTALL_PATH=/var/local/django
 mkdir $INSTALL_PATH
@@ -153,8 +153,7 @@ mkdir $INSTALL_PATH

From an archive

The last “stable” version is available in this directory. Take care of getting the last version in the desired X.Y branch (for instance -the last version for the 1.0 branch is version 1.0.2. -Extract it to the desired destination path:

+the last version for the 1.0 branch is version 1.0.2).:

wget http://www.peacefrogs.net/download/chimere -q -O -| html2text
 (...)
 [[   ]] chimere-1.0.0.tar.bz2     17-Nov-2010 16:51  53K
@@ -173,7 +172,7 @@ chown -R myusername:www-data chimere

From the git repository

-

Another solution is to get the last git version:

+

Another solution is to get it from the git repository:

cd $INSTALL_PATH
 git clone git://www.peacefrogs.net/git/chimere
 cd chimere
@@ -182,23 +181,23 @@ git checkout v2.0 # checkout the desired version
-
-

Create a custom project template

-

There a default project is provided (example_project). Copy and modify it (or -get another project based on Chimere):

+
+

Creating a custom project template

+

There, a default project is provided (example_project). Copy and modify +it (or get another project based on Chimère):

cd $INSTALL_PATH/chimere
 cp -ra example_project mychimere_project

Your project name is used for the name of the Python package of your template. As a Python package it should follow the rule of Python variable name: -it must be at least one letter and can have a string of numbers, letters and -underscores (“_”) to any length. Don’t begin the name by “_” because it has -special significance in Python.

-

In your chimere application directory create local_settings.py to fit to your +it must contain at least one letter and can have a string of numbers, letters and +underscores (“_”) to any length. Don’t use accentuated letters. Don’t begin the +name by “_” because it has special significance in Python.

+

In your Chimère application directory create local_settings.py to fit to your configuration. -A base template is provided (local_settings.py.example) and short descriptions of -the more relevant fields are given below (at least check them). Most of these -settings are initialized in settings.py.

+A base template is provided (local_settings.py.example) and short descriptions +of the more relevant fields are given below (at least check them). Most of +these settings are initialized in settings.py.

cd $INSTALL_PATH/chimere/mychimere_project
 cp local_settings.py.sample local_settings.py
 vim local_settings.py
@@ -212,18 +211,20 @@ vim local_settings.py
  • PROJECT_NAME: name of the project
  • SECRET_KEY: a secret key for a particular Django installation. This is used to provide cryptographic signing, and should be set to a unique, -unpredictable value. Change it!
  • +unpredictable value. Change it!
  • ROOT_URLCONF: url configuration for your project something like: ‘mychimere_project.urls’
  • EMAIL_HOST: smtp of an email server to send emails
  • TINYMCE_URL: url to tinymce path (default is appropriate for a Debian -installation with tinymce activated)
  • -
  • JQUERY_JS_URLS: list of Jquery and Jquery-ui urls (default is appropriate -for a Debian installation with Jquery and Jquery-ui activated)
  • -
  • JQUERY_CSS_URLS: list of Jquery and Jquery-ui urls (default is appropriate -for a Debian installation with Jquery and Jquery-ui activated)
  • +installation with tinymce package installed) +
  • JQUERY_JS_URLS: list of jquery and jquery-ui javascript urls (default is +appropriate for a Debian installation with libjs-jquery libjs-jquery-ui +packages installed)
  • +
  • JQUERY_CSS_URLS: list of jquery and jquery-ui CSS urls (default is +appropriate for a Debian installation with libjs-jquery libjs-jquery-ui +packages installed)
  • GPSBABEL: path to gpsbabel (default is appropriate for a Debian -installation with gpsbabel installed)
  • +installation with gpsbabel package installed)
  • TIME_ZONE: local time zone for this installation
  • LANGUAGE_CODE: language code for this installation
  • @@ -249,9 +250,9 @@ chmod -R g+w /var/log/django/

    Compiling languages

    -

    If your language is available in the locale directory of chimere, you will just -need to get it compiled. This can be done with (here, fr stands for french. -Replace it with the appropriate language code):

    +

    If your language is available in the directory chimere/locale/, you will just +need to get it compiled. This can be done with the following command (here, +fr stands for French, replace it with the appropriate language code):

    cd $INSTALL_PATH/chimere/chimere/
     django-admin compilemessages
    @@ -268,13 +269,13 @@ would have if the language file was already available.

    Database initialisation

    -

    Create the appropriate tables (still being in chimère application directory):

    +

    Create the appropriate tables (still being in your Chimère project directory):

    cd $INSTALL_PATH/chimere/mychimere_project
     ./manage.py syncdb

    You will be prompted for the creation of an administrator account -(administration can be found at: http://where_is_chimere/admin). Then you have -to create tables managed with south:

    +(administration can be found at: http://where_is_chimere/admin/). Then you have +to create tables managed with Django-South:

    ./manage.py migrate

    The database is set, congratulations!

    @@ -287,26 +288,29 @@ an already populated instance!):

    Webserver configuration

    Apache configuration with mod_wsgi

    -

    Install mod_wsgi for apache:

    +

    Install mod_wsgi for Apache:

    apt-get install libapache2-mod-wsgi
    -

    TODO: adapt apache-wsgi.conf

    Create and edit a configuration for Chimère:

    -
    cp $INSTALL_PATH/chimere/apache/django.wsgi $INSTALL_PATH/chimere/apache/mydjango.wsgi
    +
    cp $INSTALL_PATH/chimere/apache/django.wsgi \
    +               $INSTALL_PATH/chimere/apache/mydjango.wsgi
     vim $INSTALL_PATH/chimere/apache/mydjango.wsgi
    -cp $INSTALL_PATH/chimere/apache/apache-wsgi.conf /etc/apache2/sites-available/chimere
    +cp $INSTALL_PATH/chimere/apache/apache-wsgi.conf \
    +               /etc/apache2/sites-available/chimere
     vim /etc/apache2/sites-available/chimere
     # create log dir
    -mkdir /var/log/apache2/chimere/
    +mkdir /var/log/apache2/chimere/ +chown www-data /var/log/apache2/chimere/
    -

    Adapt the files mydjango.wsgi (with the correct sys path) and Apache chimere.

    +

    Adapt the files mydjango.wsgi (with the correct sys path and the correct +module) and Apache chimere (with the correct servername and correct paths).

    To activate the website, reload apache:

    a2ensite chimere
     /etc/init.d/apache2 reload

    If you encounter problem with the upload of files with Unicode chars in their names, activate the appropriate locale in Apache. On a Debian server with UTF-8 -as default encoding in the file /etc/apache2/envvars, uncomment the following +as default encoding, in the file /etc/apache2/envvars uncomment the following line:

    . /etc/default/locale
    @@ -325,12 +329,12 @@ line:

  • Installation