【问题标题】:WickedPDF not working in production serverWickedPDF 在生产服务器中不起作用
【发布时间】:2015-06-09 05:02:12
【问题描述】:

我正在使用 wicked_pdf gem,它在本地机器上工作正常,但在服务器上它不工作。

我检查了wkhtmltopdf的进程,它试图运行以下命令

/usr/local/bin/wkhtmltopdf -q file:///tmp/wicked_pdf20150609-25535-im12hx.html tmp/wicked_pdf_xxx.pdf

当我在服务器中运行这个命令时,我得到了这个异常

Unable to load library icui18n "Cannot load library icui18n: (icui18n: cannot open shared object file: No such file or directory)"

我从这里https://launchpad.net/ubuntu/trusty/amd64/libicu48/4.8.1.1-13+nmu1ubuntu1安装了libicu48包

以下命令需要很长时间后

/usr/local/bin/wkhtmltopdf -q file:///tmp/wicked_pdf20150609-25535-im12hx.html tmp/wicked_pdf_xxx.pdf

【问题讨论】:

    标签: ruby-on-rails ruby rubygems wkhtmltopdf


    【解决方案1】:

    我已从 PDF 生成中删除“bootstrap.css”。现在它工作正常

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2019-01-27
      • 1970-01-01
      • 1970-01-01
      • 2016-05-15
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多