Snappdf Errors On Ubuntu 24.04 Self Hosted

Version 5.11.28
Ubuntu 24.04 self hosted

Have been unable to generate a PDF since installation. Using the hosted version as an example, when an invoice is created, it can be viewed in the lower pane of the screen and also printed. While attempting to do this same thing in our self-hosted, only a blank screen shows. If I try to just print the pdf, a red error flag is displayed. I followed a couple earlier posts & installed what was termed as necessary dependencies but did not seem to help.

Laravel log:
[2025-01-22 20:33:29] production.ERROR: The command “‘/var/www/invoiceninja/vendor/beganovich/snappdf/versions/ungoogled/chrome-linux/chrome’ ‘–headless’ ‘–disable-gpu’ ‘–disable-translate’ ‘–disable-extensions’ ‘–disable-sync’ ‘–disable-background-networking’ ‘–disable-software-rasterizer’ ‘–disable-default-apps’ ‘–disable-dev-shm-usage’ ‘–safebrowsing-disable-auto-update’ ‘–run-all-compositor-stages-before-draw’ ‘–no-first-run’ ‘–no-margins’ ‘–no-sandbox’ ‘–print-to-pdf-no-header’ ‘–no-pdf-header-footer’ ‘–hide-scrollbars’ ‘–ignore-certificate-errors’ ‘–print-to-pdf=/tmp/pdf_QjN2xw.pdf’ ‘/tmp/html_ylJmIF.html’” failed.

Exit Code: 127(Command not found)

Working directory: /var/www/invoiceninja/public

Output:

Error Output:

/var/www/invoiceninja/vendor/beganovich/snappdf/versions/ungoogled/chrome-linux/chrome: error while loading shared libraries: libatk-1.0.so.0: cannot open shared object file: No such file or directory
{“userId”:1,“exception”:"[object] (Exception(code: 0): The command "‘/var/www/invoiceninja/vendor/beganovich/snappdf/versions/ungoogled/chrome-linux/chrome’ ‘–headless’ ‘–disable-gpu’ ‘–disable-translate’ ‘–disable-extensions’ ‘–disable-sync’ ‘–disable-background-networking’ ‘–disable-software-rasterizer’ ‘–disable-default-apps’ ‘–disable-dev-shm-usage’ ‘–safebrowsing-disable-auto-update’ ‘–run-all-compositor-stages-before-draw’ ‘–no-first-run’ ‘–no-margins’ ‘–no-sandbox’ ‘–print-to-pdf-no-header’ ‘–no-pdf-header-footer’ ‘–hide-scrollbars’ ‘–ignore-certificate-errors’ ‘–print-to-pdf=/tmp/pdf_QjN2xw.pdf’ ‘/tmp/html_ylJmIF.html’" failed.

Exit Code: 127(Command not found)

Working directory: /var/www/invoiceninja/public

Output:

Hi,

This may help:

I had already performed this step. I even went as far as setting the entire directory tree with their respective files to across the board rwx after performing the snappdf download --force but still same errors in the laravel.log file.

Try this:

v5.11.28

I reverted back to the default of PDF_GENERATOR=hosted_ninja in the .env file. This works but am interested to correct the problem not allowing Snappdf to work.

As for the included document, I had already installed these dependencies in addition to what gets installed when using the installation instructions.