Changeset 1058 in main


Ignore:
Timestamp:
04/27/12 07:47:05 (7 years ago)
Author:
pcosquer
Message:

docs: admin: add example of settings

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/docs/admin/ht_1_install_server.rst

    r1054 r1058  
    106106=================== 
    107107 
    108 Edit the file :file:`/var/django/openPLM/trunk/openPLM/settings.py` and set correct password ('MyPassword') 
    109 for DATABASE_PASSWORD. 
     108Edit the file :file:`/var/django/openPLM/trunk/openPLM/settings.py`  
     109and set the database password ('MyPassword') 
    110110It must be the one set with the command ``create role django with password 'MyPassword' login;`` 
    111111Here the DATABASE_USER is ``django``, not the Django admin created by 
    112112``./manage.py syncdb --all``. 
     113 
     114For example: 
     115 
     116.. code-block:: python 
     117    :emphasize-lines: 7  
     118 
     119    # settings.py 
     120    DATABASES = { 
     121        'default': { 
     122            'ENGINE': 'django.db.backends.postgresql_psycopg2', # or 'postgresql', 'mysql', 'sqlite3', 'oracle'. 
     123            'NAME': 'openplm',               # Or path to database file if using sqlite3. 
     124            'USER': 'django',                # Not used with sqlite3. 
     125            'PASSWORD': 'MyPassword',        # Not used with sqlite3. 
     126            'HOST': 'localhost',             # Set to empty string for localhost. Not used with sqlite3. 
     127            'PORT': '',                      # Set to empty string for default. Not used with sqlite3. 
     128        } 
     129    } 
     130 
     131 
     132 
    113133 
    114134Then execute the following commands: 
     
    181201Then you must modify the `BROKER_*` settings in the :file:`settings.py`, if you follow this tutorial, you 
    182202only have to change `BROKER_PASSWORD`. 
     203 
     204For example: 
     205 
     206.. code-block:: python 
     207    :emphasize-lines: 5 
     208 
     209    # settings.py  
     210    BROKER_HOST = "localhost" 
     211    BROKER_PORT = 5672 
     212    BROKER_USER = "openplm" 
     213    BROKER_PASSWORD = "secret" 
     214    BROKER_VHOST = "openplm" 
     215 
    183216 
    184217:command:`celeryd`, celery's daemon must be run. openPLM ships with an init script: 
Note: See TracChangeset for help on using the changeset viewer.