This question has been flagged
2 Replies
10186 Views

good afternoon,
when a bbdd is restored or odoo is migrated from one container to another, you must always correct the assets (regenerate Assets Bundles) manually or execute a script in the database, there is some way to do it automatically so that Always available immediately.
you have the services in aws and every time you run autoscaling, all the bbdd stop working.
I will appreciate your help.

Avatar
Discard
Best Answer

Just in case someone stumbles over this question and is looking for a solution:

One way would be to automate the deletion of the attachments either via XML RPC with the domain 

domain = ["&", ("res_model", "=", "ir\\.ui\\.view"\\),\\ "\\|",\\ \\("name",\\ "=like",\\ "%\\.assets_%\\.css"\\),\\ \\("name",\\ "=like",\\ "%\\.assets_%\\.js"\\)\\]

or\ directly\ in\ the\ database:

delete\ from\ ir_attachment\ where\ res_model\ =\ 'ir\.ui\.view'\ and\ \(name\ ilike\ '%\.assets_%\.css'\ or\ name\ ilike\ '%\.assets_%\.js'\)

The debug javascript menu does it similar

Avatar
Discard
Best Answer

not a complete solution, but the following article might help:

https://medium.com/@reedrehg/odoo-images-and-attachments-explaining-and-regenerating-assets-d1eb7fe8a3ed

Avatar
Discard