跳至內容
選單
此問題已被標幟
3 回覆
1821 瀏覽次數

Hello

My website builder from Odoo 17 is still loading and does not display anything.

Here is the console result:

web.assets_web.min.js:832 Mixed Content: The page at 'https://mydomain.com/web#action=367&cids=1&menu_id=222' was loaded over HTTPS, but requested an insecure frame 'http://mydomain.com/'. This request has been blocked; the content must be served over HTTPS.


In Odoo 16, I fixed this issue with Nginx configuration by adding the following line:

add_header Content-Security-Policy "upgrade-insecure-requests";

This configuration line solved the problem for me. However, it's not working in Odoo 17.

Please suggest if you have any ideas.

Your help is greatly appreciated.

Thank you.


Thanks

頭像
捨棄
最佳答案

Hi,

Please add the below line inside your nginx file . you need to add this inside the location

proxy_set_header X-Forwarded-Proto https;


example

location /longpolling {

                proxy_connect_timeout   3600;

                proxy_read_timeout      3600;

                proxy_send_timeout      3600;

                send_timeout            3600;

                proxy_set_header X-Forwarded-Proto https;

                proxy_pass http://127.0.0.1:8072;

        }


After adding it , save the file and restart nginx service


Hope it helps

頭像
捨棄
最佳答案

Htet Aung Shane answer works for my. The proxy_redirect directive should be in the location / nginx context

頭像
捨棄
作者 最佳答案

Thanks for your answer
adding this nginx config line fix me the problem.
proxy_redirect http://yourdomainhere/ https://yourdomainhere/;

頭像
捨棄

Thanks. It's work for me!