Přejít na obsah
Menu
You need to be registered to interact with the community.
This question has been flagged
2 Odpovědi
5401 Zobrazení

I have successfully installed odoo (11.0 Community Edition) along with wkhtmltopdf on Ubuntu 18.04

The version of wkhtmltopdf is 0.12.5, I get deb package(wkhtmltox_0.12.5-1.bionic_amd64.deb) from download page(https://github.com/wkhtmltopdf/wkhtmltopdf/releases/tag/0.12.5).

The created PDF report is fine with Odoo serve web pages by itself.

However, the report lost its style when set a reverse proxy (Nginx) for this odoo.

The config files for Nginx and Odoo are list blow, are there anyone can give me advise for this issue?

user www-data;
worker_processes auto;
pid /run/nginx.pid;
include /etc/nginx/modules-enabled/*.conf;

events {
worker_connections 768;
# multi_accept on;
}

http {
upstream backend-odoo11 {
server 127.0.0.1:8011;
}
upstream backend-odoo11-im {
server 127.0.0.1:8711;
}

server {
listen 443 ssl;
ssl_certificate pem.crt;
ssl_certificate_key pem.key;
location / {
root html;
index index.html;
}
}

server {
listen 9011 ssl;
ssl_certificate pem.crt;
ssl_certificate_key pem.key;

location / {
proxy_pass http://backend-odoo11;
proxy_read_timeout 600;
client_max_body_size 0;
}

location /longpolling {
proxy_pass http://backend-odoo11-im;
client_max_body_size 0;
}

}
}
[options]
; This is the password that allows database operations:
; admin_passwd = admin
db_host = False
db_port = False
db_user = odoo
db_password = False
;addons_path = /usr/lib/python3/dist-packages/odoo/addons
addons_path = /var/lib/odoo/liontech,/var/lib/odoo/liontech_themes,/var/lib/odoo/auto_backup
http_interface = 127.0.0.1
http_port = 8011
limit_time_real = 1200
logrotate = True
longpolling_port = 8711
proxy_mode = True
workers = 6
Avatar
Zrušit
Nejlepší odpověď

Hi ZQinn,

I suppose the base url is not configured correctly.

Activate the developer mode and then navigate to Settings > Parameters > System Parameters
Set the value of web.base.url to the same address as the one you use to access your odoo instance.

Best regards

Yvan


              
Avatar
Zrušit
Nejlepší odpověď

Hi,

Try to add this parameter :

report.url = http://backend-odoo11:8069

in your Odoo settings

Avatar
Zrušit
Related Posts Odpovědi Zobrazení Aktivita
2
bře 19
6306
0
bře 25
1671
1
bře 25
1760
2
čvc 24
4353
1
kvě 24
2704