Skip to content
Amy Unger edited this page Aug 31, 2013 · 2 revisions

Use on Engine Yard AppCloud

The Unix packages x11-libs/libXext and x11-libs/libXrender are dependencies needed to use PDFKit. Here are the instructions to get pdfkit up and running in the AppCloud.

  1. On Engine Yard's AppCloud, they use gentoo. Let's install the libs. Type into your console:

     sudo emerge libXext libXrender
    
  2. After you install the Unix packages, complete the following

     cd /usr/local/bin/
    

If you have ran the pdfkit --install-wkthmlpdf already and it isn't working do:

  sudo rm wkhtmltopdf
  1. Lastly type into console:

For 32-bit instance:

    curl http://wkhtmltopdf.googlecode.com/files/wkhtmltopdf-0.10.0_beta5-static-i386.tar.lzma | lzcat - | sudo tar xfv -
    sudo mv wkhtmltopdf-i386 wkhtmltopdf

For 64-bit instance:

    curl http://wkhtmltopdf.googlecode.com/files/wkhtmltopdf-0.10.0_rc2-static-amd64.tar.bz2 | bunzip2 - | sudo tar xvf -
    sudo mv wkhtmltopdf-amd64 wkhtmltopdf

Issue with binary

@emachnic notes in Issue #178 from May 2013:

The instructions for Engine Yard are a bit out-dated. There is now a wkhtmltopdf binary available for 64-bit and 32-bit instances. This can be installed using the "emerge" recipe from https://github.com/engineyard/ey-cloud-recipes. Users should be able to find the package information by running eix wkhtmltopdf which will display the package information:

~ # eix wkhtmltopdf
* app-misc/wkhtmltopdf-bin [1]
     Available versions:  0.10.0_beta5!p!s ~0.10.0_rc1!p!s
     Homepage:            http://code.google.com/p/wkhtmltopdf
     Description:         Simple shell utility to convert html to pdf

[1] "engineyard" /engineyard/portage/engineyard

One thing to note is that if users had previously tried to set it up some other way, it's best to remove the bundled gems and force them to be re-compiled. The location is /data/app_name/shared/bundled_gems and it's safe to just remove that directory and re-deploy.

Clone this wiki locally