acsone / odoo-bedrock

Odoo Bedrock container image (BYOO)
MIT License
23 stars 17 forks source link

Add entrypoint parts to set `report.url`, `web.base.url` and `web.base.url.freeze` #16

Closed lmignon closed 1 year ago

lmignon commented 1 year ago

Any script placed in '/odoo/start-entrypoint.d' will be execyted add start of the container before the start of Odoo. Files are run in the lexical sort order of their names (according to the C/POSIX locale character collation rules) as explained into the command documentation.

TO BE TESTED

sbidoul commented 1 year ago

@lmignon can you add the c2c credits (a copyright header in the 2 files should be fine)?

We need to test this does not break when psql is not installed.

PierrickBrun commented 1 year ago

Thanks for this ! Can we also test that it does not break if the database exists but was not initialized by odoo (createdb only).

I did this like this in our template project: https://github.com/akretion/docky-odoo-template/commit/021db06783edeacf9a295ea5924cc52b103997e2

lmignon commented 1 year ago

Thank you @PierrickBrun Changes done

sbidoul commented 1 year ago

I added tests for this. I'm now comfortable with merging it if you agree @lmignon @PierrickBrun

sbidoul commented 1 year ago

@adrienpeiffer FYI. This will automatically set the url system parameters ODOO_BASE_URL and ODOO_REPORT_URL environment variables.