Skip to Content
Menú
This question has been flagged
1 Respondre
3853 Vistes

Hi 

I Have an odoo 17 CE installed on Ubuntu 22.04 docker environment. This is the installation guide I followed from digital ocean: https://www.digitalocean.com/community/tutorials/how-to-install-odoo-with-docker-on-ubuntu


Now, the issue is when I check the sitemap.xml file, I can see all the URLs are like this instead of my domain name: 

http://localhost:8069/
http://localhost:8069/contactus
http://localhost:8069/about

But I can use the domain to log in to the odoo backend.


I did set up the odoo.conf file in this location /etc/nginx/sites-available/odoo.conf, and it looks like this now:

server {
    server_name  domain.com;

    access_log  /var/log/nginx/odoo.access.log;
    error_log   /var/log/nginx/odoo.error.log;

    location / {
      proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
      proxy_set_header X-Real-IP $remote_addr;
      proxy_set_header X-Forwarded-Host $host;
      proxy_set_header X-Forwarded-Proto https;
      proxy_pass http://localhost:8069;

  }

    listen [::]:443 ssl ipv6only=on; # managed by Certbot
    listen 443 ssl; # managed by Certbot
    ssl_certificate /etc/letsencrypt/live/domain.com/fullchain.pem; # managed by Certbot
    ssl_certificate_key /etc/letsencrypt/live/domain.com/privkey.pem; # managed by Certbot
    include /etc/letsencrypt/options-ssl-nginx.conf; # managed by Certbot
    ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot

}
server {
    if ($host = domain.com) {
        return 301 https://$host$request_uri;
    } # managed by Certbot


    listen       80;
    listen       [::]:80;
    server_name  domain.com;
    return 404; # managed by Certbot


}


What should I do to make the site map from this : 

http://localhost:8069/about-us
http://localhost:8069/contactus
http://localhost:8069/privacy


to this 

https://domain.com/about-us
https://domain.com/contactus
https://domain.com/privacy




Any suggestion? 


Regards

Avatar
Descartar
Best Answer

Hi,

Please go through our blog How to Configure Odoo with Nginx as Reverse Proxy

https://www.cybrosys.com/blog/how-to-configure-odoo-with-nginx-as-reverse-proxy


Hope it helps

Avatar
Descartar
Autor

Thanks for your reply. But I checked and tried this blog post before even posting here. This solution does not work in my case, more specifically in the Docker environment.

Related Posts Respostes Vistes Activitat
2
d’ag. 24
2575
25
de juny 20
69212
0
d’ag. 25
131
4
de maig 25
2726
2
de maig 25
6160