I am using wkhtml2pdf to generate pdf files, the local binaries work just fine, but i don't know why i'm having this problem when deploying to heroku. I get this error
The exit status code '127' says something went wrong: stderr: "/app/vendor/h4cc/wkhtmltopdf-amd64/bin/wkhtmltopdf-amd64: error while loading shared libraries: libjpeg.so.8: cannot open shared object file: No such file or directory " stdout: ""
My composer.json includes these 3 files i need
"h4cc/wkhtmltopdf-amd64": "0.12.x",
"h4cc/wkhtmltoimage-amd64": "0.12.x",
"barryvdh/laravel-snappy": "0.1.x"
Where snappy is the class that handles wkhtml2pdf binaries.
Snappy is correctly configured to load the binaries from the vendors folder
'pdf' => array(
'enabled' => true,
'binary' => base_path('vendor/h4cc/wkhtmltopdf-amd64/bin/wkhtmltopdf-amd64'),
'options' => array(),
),
'image' => array(
'enabled' => true,
'binary' => base_path('vendor/h4cc/wkhtmltopdf-amd64/bin/wkhtmltopdf-amd64'),
'options' => array(),
),
But the problem is, when i'm trying to generate a pdf, in the moment i call wkhtml2pdf it stops with an error about libjpeg.so.8 that is something i know nothing about.
php -r 'print_r(gd_info());'
andrpm -qa | egrep 'jpg|png'
andlocate libjpeg.so
. – rajesh ujade