-
Notifications
You must be signed in to change notification settings - Fork 0
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
PDF generation in local dev environment is broken #102
Comments
Links to things that might be of use |
The pdf generator uses puppeteer to create a pdf. We have an issue in our local environments where the pdf generations is failing. The issue can be found here - DEFRA/water-abstraction-team#102. This change proves the fix works. But does not account for our deployments and so should not be merged. We can look for a solution to support local and a deployed state,
This can be fixed by specifying the chromium path and using the Source - https://pptr.dev/guides/configuration Proposed config change:
Error Chromium install
FixSpecify the path to chromium in the puppeteer config
Error running as root
Fix
We probably only need to set this for local development based on my current understanding. So we can set an env locally of in the docker container to enable this config changes. A spike PR has been created to prove this solution works - DEFRA/water-abstraction-service#2651 |
As a result of this fix a new error occurs
I have assumed this is another error but out side the scope of this issue to fix. |
We've spotted if you try to send a paper form notification the UI will tell you all is well but nothing gets sent to Notify and we see an error in the logs
We think it's because of changes in the latest version of chromium which we install as part of the Docker image we build and use locally. This is the output when connected to the running docker
dev
container and we try and just check the version of Chromium.Initial thoughts were a change in chromium which means we must pass the
--no-sandbox
flag when we call it from puppeteer.We tried that though and got the same error.
So, this is going to need a bit more digging. We've prided ourselves on creating a complete working environment locally taking no shortcuts like disabling ClamAV. But this means we can no longer say that until we get this working again.
The text was updated successfully, but these errors were encountered: