-
Notifications
You must be signed in to change notification settings - Fork 645
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Does it work with Alpine? #841
Comments
In another issue, someone reported this wkhtmltopdf Alpine Docker container And there are several posts on StackOverflow about it Please come back and let us know what works for you! |
@unixmonkey I've tried almost all suggestions and it doesn't work for me... Unfortunately... I'm going to spend some time to find fix for my issue but seems like I'll migrate to Ubuntu |
I'm running it on
|
If you do not see some fonts in generated PDF, you just need to install them. |
It works on Alpine for us, as well. We've been running this in a production app for a few months. The top of our Dockerfile looks like this:
|
We've migrated to new ruby docker version and started to use wkhtmltopdf from Alpine upstream. So our
and it works fine :) |
It's irrelevant to As per https://pkgs.alpinelinux.org/packages you can see that starting from |
Closing this, as it appears to have been answered. Yes, it works with Alpine. |
I followed instructions here to incorporate WickedPDF in a docker image, but I keep getting this strange error from time to time. Sometimes the PDF is generated, other times it exits with:
Any ideas how to overcome? |
@bo-oz I think you might fix this by either granting write permission to I'm not sure this is the reason the command errors though. This sounds like just a warning, unless it can't write to |
I think this error had to do with the font pack that wasn’t installed. But the issue still persists, it seems that the call that lets WickedPDF write a string to a HTML file to the tmp folder seems to fail from time to time. The error is coming from wkhtmltopdf that isn’t able to access the file or it is missing entirely. Trying to do some more debugging tomorrow. |
After debugging some more, I found that the command that addresses wkhtmltopdf, seems to fail from time to time with signal 11. Any ideas what that could mean? Could it be a rights issue accessing the file in the temp dir? This is the line that sometimes raises the error: |
Ok, finally found the issue. When calling When I "monkeypatch" the method to the following, it does work like a charm:
Is there a reason that you are adding this Edit: Same problems exist when attaching header/footer htlml, since the file:/// is hardcoded in the method |
Created PR #889 to have a way to solve the issue above. |
Simply installing
Instead, I needed to copy from |
I want to build Docker on Alpine image with Rails 5.2 + Ruby 2.6.
But seems like
wkhtmltopdf-binary
isn't compatible with linux Alpine, I installedwkhtmltopdf
from Alpine sources, and it builds PDF, but without styles.Is there any approach to use
wicked_pdf
on linux Alpine?The text was updated successfully, but these errors were encountered: