barryvdh / laravel-dompdf

A DOMPDF Wrapper for Laravel
MIT License
6.62k stars 965 forks source link

oputput() function hangs on local docker environment #965

Open fillobotto opened 1 year ago

fillobotto commented 1 year ago

Describe the bug I've been using this extension for months and it's working perfectly. The only problem is that I cannot make the ->output() function to work on my local environment, using Docker. Specifically, the whole Docker container it is unresponsive once I call the ->output() function. I have to either wait about one minute for it to unlock or restart the container.

Maybe it has something to do with the php.ini parameters set up inside the container?

To Reproduce PHP 8.2 Laravel 9.0 laravel-dompdf 2.0.0 Docker container made with Sail 1.21.2

parallels999 commented 1 year ago

https://github.com/barryvdh/laravel-dompdf/blob/424a223ce80e7afc8bfb6e84449679efe272fbb5/.github/ISSUE_TEMPLATE/bug_report.md?plain=1#L10-L12

This is just a Dompdf wrapper! I understand that this package is just a Laravel wrapper for https://github.com/dompdf/dompdf Any issues with PDF rendering, CSS that is not applied correctly, aligning/fonts/characters etc that are not directly related to this package, should be reported there. When having doubts, please try to reproduce the issue with just dompdf. If it's also present there, do not open an issue here please.

stale[bot] commented 1 year ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Any issues with PDF rendering itself that are not directly related to this package, should be reported on https://github.com/dompdf/dompdf instead. When having doubts, please try to reproduce the issue with just dompdf. If you believe this is an actual issue with the latest version of laravel-dompdf, please reply to this issue so we can investigate further. Thank you for your contribution! Apologies for any delayed response on our side.

salvisb commented 1 year ago

Hi @fillobotto, did you manage to solve this issue?

remiebeling commented 5 months ago

Hi @fillobotto, did you manage to solve this issue?

Hello, i had the Same Issue. Turned out it was a Laravel Sail Configuration Issue.

I got it solved by setting the following config in my .env file:

PHP_CLI_SERVER_WORKERS=3

I found the Solution here:

https://github.com/dompdf/dompdf/issues/3379#issuecomment-1904556295