Community mailing list archives

community@mail.odoo.com

Re: Muliple Odoo Website on single port

by
zoya patel
- 05/18/2016 05:54:42
Hello Jos De Graeve,

First of all thanks for your reply as you atlest replied on this.

I expected that will get proper solution from community within one day but my bad luck that not got exact solution till. From Odoo support also not get proper reply.


On Wed, May 18, 2016 at 1:42 PM, Jos De Graeve <jos.degraeve@apertoso.be> wrote:
Hi,

Why are you using multiple ip's for connecting to the same odoo DB ?  Odoo does not check the connection where a request came from, so i don't see the point of doing that.

I think odoo check that from where reuest came. If not pass proper ip it does not load proper pages. Dont know if i am wrong.
To use multiple websites in odoo, configure multiple websites in the backend.  odoo will match the website name with the http host headers.  Then have your reverse proxy forward the requests to you odoo instance.

We did configuration in backend.
A good idea is probably to get things working without reverse proxy, and then moving forward by adding the reverse proxy.

I dont know how it will work  without reverse proxy. If you have configuration for that please share it.
Regards,


Jos De Graeve - Apertoso business ICT


Guido Gezellelaan 16 - B-9800 Deinze - Belgium
 
Direct: +32 9 381 64 51
General:+32 9 381 64 50
Mobile: +32 475 54 68 80
mail/im/skype: Jos.DeGraeve@apertoso.be - apertoso

2016-05-18 9:42 GMT+02:00 Richard Lehnerdt <richard.lehnerdt@gmail.com>:
Have you tried it with a rewrite rule in apache?

<VirtualHost  iP_of_server:8080>
ServerName site name4
ServerAlias www.sitename4
RewriteEngine on
RewriteRule ^/(.*) http://127.0.0.40:8069/$1 [P]
ProxyPassReverse / http://127.0.0.40/ Keepalive=On

LogLevel warn
        CustomLog ${APACHE_LOG_DIR}/site4.com.access.log combined
</VirtualHost>



On 17 May 2016 at 15:52, zoya patel <zoya27p@gmail.com> wrote:
Thanks robert for your reply.

It is not caching problem.

if i refresh your browser (F5) dos it still load the wrong page.

It is loding wrong page from server itself.

This is somewhat complex and interesting stuff.

On Tue, May 17, 2016 at 4:57 PM, robert rottermann <robert@redcor.ch> wrote:

never done such a configuration.
But this sounds like a caching problem.
if you refresh your browser (F5) dos it still load the wrong page?

robert

On 17.05.2016 11:53, zoya patel wrote:
Hello Community,

We are running four website with different home page and menu in single db on odoo. It works as expected but some time it shows randome behaviour like if i enterd name of site1 and it loads pages of site2. There is no fix behaviour but yes once it load any site in browser it will load same for remaining three if i it open one by one.

Let me show you first what we have done as configuration:
1> we run our server on port 8069, with db filter= our_db_name
2> After login in db we have done configuration for website admin.

for website "site1":
    domain: 127.0.0.10

for website "site2":
    domain: 127.0.0.20

for website "site3":
    domain: 127.0.0.30

for website "site4":
    domain: 127.0.0.40

3> We have created different home pages and menus for each website.

4> Apache configuration:

<VirtualHost iP_of_server:8080>
        ServerName site1.in
        ServerAlias www.site1.in
        ServerAdmin admin@site1.in

        #ProxyPass /longpolling http://127.0.0.10:8072/longpolling
        #ProxyPassReverse /longpolling http://127.0.0.10:8072/longpolling

        ProxyPass / http://127.0.0.10:8069/
        ProxyPassReverse / http://127.0.0.10:8069/

        LogLevel warn
        CustomLog ${APACHE_LOG_DIR}/site1.in.access.log combined
</VirtualHost>

<VirtualHost iP_of_server:8080>
        ServerName site2.com
        ServerAdmin admin@site2.com
        ServerAlias www.site2.com
        #ProxyPass /longpolling http://127.0.0.20:8072/longpolling
        #ProxyPassReverse /longpolling http://127.0.0.20:8072/longpolling

        ProxyPass / http://127.0.0.20:8069/
        ProxyPassReverse / http://127.0.0.20:8069/

        LogLevel warn
        CustomLog ${APACHE_LOG_DIR}/site2.com.access.log combined

</VirtualHost>

<VirtualHost iP_of_server:8080>
        ServerName site3.us
        ServerAdmin admin@site3.us
        ServerAlias www.site3.us
        #ProxyPass /longpolling http://127.0.0.30:8072/longpolling
        #ProxyPassReverse /longpolling http://127.0.0.30:8072/longpolling

        ProxyPass / http://127.0.0.30:8069/
        ProxyPassReverse / http://127.0.0.30:8069/

        LogLevel warn
        CustomLog ${APACHE_LOG_DIR}/site3.us.access.log combined
</VirtualHost>

<VirtualHost iP_of_server:8080>
        ServerName site4.com
        ServerAdmin admin@site4.com
        ServerAlias www.site4.com
        #ProxyPass /longpolling http://127.0.0.40:8072/longpolling
        #ProxyPassReverse /longpolling http://127.0.0.40:8072/longpolling

        ProxyPass / http://127.0.0.40:8069/
        ProxyPassReverse / http://127.0.0.40:8069/

        LogLevel warn
        CustomLog ${APACHE_LOG_DIR}/site4.com.access.log combined
</VirtualHost>

Now If i run all sites using differnet ports it works but for same port it creates issue. I dont think we need to run multiple service of odoo for multi website behaviour. I am not sure where i am missing but it can be bacuse of apache or odoo configuration.

Any help or suggestion will be helpful.

Thanks.

_______________________________________________
Mailing-List: https://www.odoo.com/groups/community-59
Post to: mailto:community@mail.odoo.com
Unsubscribe: https://www.odoo.com/groups?unsubscribe


_______________________________________________
Mailing-List: https://www.odoo.com/groups/community-59
Post to: mailto:community@mail.odoo.com
Unsubscribe: https://www.odoo.com/groups?unsubscribe


_______________________________________________
Mailing-List: https://www.odoo.com/groups/community-59
Post to: mailto:community@mail.odoo.com
Unsubscribe: https://www.odoo.com/groups?unsubscribe


_______________________________________________
Mailing-List: https://www.odoo.com/groups/community-59
Post to: mailto:community@mail.odoo.com
Unsubscribe: https://www.odoo.com/groups?unsubscribe


_______________________________________________
Mailing-List: https://www.odoo.com/groups/community-59
Post to: mailto:community@mail.odoo.com
Unsubscribe: https://www.odoo.com/groups?unsubscribe