nmbooker / oekit

OpenERP/Odoo toolkit for client-side XML-RPC testing and scripting
GNU General Public License v3.0
1 stars 2 forks source link

Example for use of odoo.backupdb #5

Closed HavardLine closed 8 years ago

HavardLine commented 8 years ago

Hi There I have tried to use odoo.backupdb without success.

Are there any examples for use of this function? What is the output format?

Thanks, Håvard

Nick-OpusVL commented 8 years ago
  odoo.backupdb --admin-password adminpass -u http://odooserver:8069 -o mydb.zip  mydb

You may need to play with whether to put a trailing forward-slash at the end of the URL.

With any luck the above should log into the database manager for the Odoo running on odooserver port 8069 with password adminpass (note this is the password for the database manager, and not the password for the admin user of the database itself), and download a backup of the mydb database (including database and filestore) and putting it in the zip file mydb.zip in your current directory.

Without -o it will output the zip file on STDOUT, and without -u it will try to use the OE_CLIENT_URL environment variable.

Please let me know whether that example worked (with modifications to suit your environment of course), and I'll put it into the documentation.

Nick-OpusVL commented 8 years ago

I should note it's equivalent to logging into the database manager and clicking the button to get a backup in zip format.

HavardLine commented 8 years ago

Perfect!

Thanks Nick-OpusVL

Nick-OpusVL commented 8 years ago

No problem. I've added the example and explanation above to the README file.