跳至内容
菜单
此问题已终结
2 回复
5402 查看

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
形象
丢弃
最佳答案

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


              
形象
丢弃
最佳答案

Hi,

Try to add this parameter :

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

in your Odoo settings

形象
丢弃
相关帖文 回复 查看 活动
2
3月 19
6306
0
3月 25
1672
1
3月 25
1762
2
7月 24
4354
1
5月 24
2705