odoo-saas-tools icon indicating copy to clipboard operation
odoo-saas-tools copied to clipboard

Add old client database to new saas

Open bassn opened this issue 8 years ago • 4 comments

Hello, i have installed odoo-saas-tools and would like to add an already existing client database to the saas. Is there a way of doing that? Best regards Bass


Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.

bassn avatar Apr 11 '16 18:04 bassn

We haven't checked it, but you can try:

  • you need to install saas_client module
  • new record must be created in saas Server database
  • new record must be created in saas portal database

yelizariev avatar Apr 13 '16 13:04 yelizariev

Thanks, Ivan. I haven't seen your answer all the time. I will try that and report back.

bassn avatar May 13 '16 08:05 bassn

Here what i have done for adding an existing client data to a new saas:

  1. Create a dummy client database from saas portal using any template; so you have all needed records in saas portal database and in saas server database
  2. Delete the dummy client database (we will replace it by the old existing client database)
  3. Restore the existing client database you wanna add to saas with the same name as the dummy database you deleted before
  4. Install module saas_client in the client database
  5. Add these system parameters in client database:
    - saas_client.ab_location
    - saas_client.ab_register
    - res.users.owner
    - saas_client.max_users
    - saas_client.expiration_datetime
    - saas_client.total_storage_limit
    maybe the solution work without step 5, but i haven't tested that.
  6. in PostgreSQL: replace the database UUID by the UUID in both tables saas_portal_client and saas_server_client (fieldname client_id)
  7. in client database: create a new OAuth Provider record for saas portal oauth provider and afterwards assign this to the admin user

Now i can:

  • see and configure the client database in my saas portal database
  • login in the client database via oauth provider (from client database)

But when i try to login to the client database out of the saas portal, i get message

Internal Server Error The server encountered an internal error and was unable to complete your request. Either the server is overloaded or there is an error in the application.

Then the URL of browser is switched to

http://client-db.domain.tld/saas_client/edit_database?access_token=TfO35iheZVhEcitPvHujq3eDAtMuPA&state=%7B%22d%22%3A+%22client-db.domain.tld%22%2C+%22client_id%22%3A+%22878784c4-ebf2-11e5-ad20-0cc47a0c95d4%22%7D

Has someone an idea how to fix that?

Thanks.

bassn avatar May 25 '16 12:05 bassn

Hi bassn,

Did you manage to migrate an old databse to odoo-saas ?

Thanks.

vkhalil avatar Oct 23 '17 20:10 vkhalil