I have been researching this issue for a few days now without any luck. In summary, PDF attachments fail to attach in sent invoices. I am running a clean install of self-hosted Invoice Ninja and running local phantomjs on a Debian Stretch VM. I downloaded phantomjs via wget, extracted, copied to /usr/bin/phantomjs and chmod 775.
The “Test” link in Email Settings loads for a while then fails with: Failed to load PDF document.
I have tried troubleshooting steps here: https://invoice-ninja.readthedocs.io/en/latest/configure.html#phantomjs
Here is the output of “phantomjs test.pjs” (just where the error occurs): https://pastebin.com/dKjYrc2v
Here is my laravel-error.log: https://pastebin.com/bkWEQUkE
Here is my .env config: https://pastebin.com/fJgXRhYX
Versions:
OS: Debian Stretch 9.9.0 (ESXi virtual machine)
Invoice Ninja: 4.5.12
PhantomJS: 2.1.1
Any suggestions are appreciated.