Odoo Help

Welcome!

This community is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.

0

Is there any way i can filter my databases using my domain with and without www?

By
Chris Magic
on 7/30/16, 6:07 PM 142 views

Hi everybody, I have --dbfilter set to  %h$ which works fine only when i access mydomain.com without www but when i access using www.mydomain.com i get redirected to  the database manager.

Is there any way i can filter my databases using my domain with and without www?

1

Ermin Trevisan

--Ermin Trevisan--
3548
| 6 3 7
Walchwil, Switzerland
--Ermin Trevisan--


Ermin Trevisan
On 7/31/16, 2:57 AM

^%h$ takes the complete domain and therefore Odoo tries to match the database name "www-domain-com", which it could not find. If you use ^%d$ instead, it tries to find the database name of the subdomain except of "www". If there is no other subdomain than "www", it matches the domain name. Examples with ^%d$:

- www.domain.tld: database "domain"

- subdomain.domain.tld: database "subdomain"



0
Chris Magic
On 7/31/16, 3:26 AM

Thanks for your response. I actually have it set to %h$ but if i set it to ^%h$ or ^%d$ i get the website only without www, but it won't let me access the backend because for domain1.tld/web it shows the database manager as well as for the other domains23.tld/web . Is there a way to resolve this issue maybe using apache or any other approach?

Yes of course you need a proxy server for a (reasonable) setup. Check this for further help:

http://antiun.github.io/odoo-reverse-proxy-howto/

I would also recommend not to use self-signed Certificates, but "Let's encrypt"-SSL for example. You might also look at caddyserver (www.caddyserver.com) for a simple proxy server with automatic SSL.

Ermin Trevisan
on 7/31/16, 5:59 AM

Thank you Ermin!

Chris Magic
on 8/9/16, 10:47 PM

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

1 follower(s)

Stats

Asked: 7/30/16, 6:07 PM
Seen: 142 times
Last updated: 8/9/16, 10:46 PM