Se rendre au contenu
Menu
Cette question a été signalée
1 Répondre
5344 Vues

I have built custom modules in Odoo 16 community edition. 
Recently I noticed an error when I checked my log files. When I run my logs this error appears all the time: 

ERROR Production odoo.addons.bus.websocket: 400 Bad Request: Empty or missing header(s): upgrade

It doesn't disrupt any of the running processes and doesn't break any of my modules. I can't seem to find an origin for it. 

I'm trying to figure out where it's coming from and if anybody dealt with similar one before.

Thank you.

Avatar
Ignorer
Meilleure réponse

You need to add in your nginx config :




upstream odoo {
    server 127.0.0.1:8070;
}

upstream odoochat {
    server 127.0.0.1:8072 weight=1 fail_timeout=0;
}

location /websocket {
...
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "Upgrade";
proxy_pass http://odoochat;
...
location / {
    proxy_redirect off;    
    proxy_pass http://odoo;
}




And in your odoo.conf :
proxy_mode = True
xmlrpc_port = 8070
xmlrpc_interface = 127.0.0.1
gevent_port = 8072 (default in odoo16)
workers = 2 or more
Avatar
Ignorer
Auteur

I've tried something like this. That's what my nginx.conf looks like now:
location /websocket {
proxy_read_timeout 600s;
proxy_pass http://127.0.0.1:8069;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
proxy_set_header Host $host;
proxy_pass http://odoochat;

But unfortunately the error is still there.

Publications associées Réponses Vues Activité
1
mars 24
2050
3
avr. 22
14010
3
déc. 24
1955
3
mars 15
7565
0
sept. 25
658