Commit fe395b96 authored by LE GAC Renaud's avatar LE GAC Renaud
Browse files

Use the construct DBURIS.

parent 496df8f3
......@@ -4,7 +4,7 @@
.pydevproject
*.pyc
.settings/
_db.py
_db*.py*
cache/
cron/
databases
......
......@@ -3,7 +3,7 @@
setup the connection to the databases.
Define constants for the different role
"""
# Migration flags
MIGRATE = False
......@@ -19,7 +19,7 @@ ID_USER, USER, DEF_USER = 2, 'user', 'project leader,...'
#
#-------------------------------------------------------------------------------
try:
mysql = 'mysql://%s:%s@%s/%s' % (DB_USER, DB_PWD, DB_HOST, DATABASE)
mysql = DBURIS[request.application]
db = DAL(mysql, lazy_tables=False, migrate_enabled=MIGRATE, pool_size=10)
except:
raise HTTP(500, T("Can't access the MySQL database !!!"))
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment