[FIX]
* restore with the user connexion to owner's object, intead of the owner who originaly create the database [IMP] * pg_dump command is launch with no owner defined bzr revid: christophe.chauvet@syleam.fr-20090426090444-glridpyq1llqlac0
This commit is contained in:
@@ -171,7 +171,7 @@ class db(netsvc.Service):
|
||||
security.check_super(password)
|
||||
logger = netsvc.Logger()
|
||||
|
||||
cmd = ['pg_dump', '--format=c']
|
||||
cmd = ['pg_dump', '--format=c', '--no-owner']
|
||||
if tools.config['db_user']:
|
||||
cmd.append('--username=' + tools.config['db_user'])
|
||||
if tools.config['db_host']:
|
||||
@@ -210,7 +210,7 @@ class db(netsvc.Service):
|
||||
cr.close()
|
||||
sql_db.close_db('template1')
|
||||
|
||||
cmd = ['pg_restore']
|
||||
cmd = ['pg_restore', '--no-owner']
|
||||
if tools.config['db_user']:
|
||||
cmd.append('--username=' + tools.config['db_user'])
|
||||
if tools.config['db_host']:
|
||||
|
||||
Reference in New Issue
Block a user