We have Odoo 12 (enterprise) on Ubuntu 18 running.
I want to force a database selection when a request comes from a certain domain (the webshop domain)
So https://webshop.mydomain.com should only use the production "myproductiondb"
In /etc/odoo/odoo.conf I have set this:
server_wide_modules = base,web,dbfilter_from_header
proxy_mode = True
In Apache:
ProxyRequests Off
RequestHeader set X-Odoo-dbfilter "myproductiondb"
#Redirect to ODOO
ProxyPreserveHost On
ProxyPass / http://localhost:8069/ retry=0
ProxyPassReverse / http://localhost:8069/
However I still get redirected to webshop.mydomain.com/web/database/selector
If I add this in /etc/odoo/odoo.conf
dbfilter = myproductiondb
It works. But now it is always doing this, while I only want to force this on the webshop. So why is the RequestHeader functionality not working.
Hope someone can help me
Thanks