Replace use of wicked_pdf gem which used the now defunct wkhtmltopdf package with the grover gem which uses puppeteer and headless chrome. This occurs in the following files: plan_exports_controller.rb, pdf_publisher_job.rb and public_pages_controller
Updated Gemfile to remove the aforementioned gems and add grover
Removed wkhtmltopdf from Rails config
Added an initializer to setup grover properly
Add the publisher_job_status field to the templates table and added narrative to the template model so that we can store the PDF version of a template in ActiveStorage
Update the Template publication workflow so that it pre-renders the template as a PDF and stores it in ActiveStorage
Update both the public facing "Funder Requirements" and "Public Plans" pages to return the pre-rendered PDFs from ActiveStorage when available.
Update the PdfPublisherJob to use Grover to build PDFs
Added Roboto and Tinos fonts
Added new tasks for Capistrano so that it will install Chrome on the server if it does not already exist and will also install the Roboto and Tinos fonts
Added Rake task to pre-render all public templates
Fixes #604.
Changes proposed in this PR:
wicked_pdf
gem which used the now defunctwkhtmltopdf
package with thegrover
gem which usespuppeteer
and headlesschrome
. This occurs in the following files:plan_exports_controller.rb
,pdf_publisher_job.rb
andpublic_pages_controller
grover
publisher_job_status
field to thetemplates
table and addednarrative
to thetemplate
model so that we can store the PDF version of a template in ActiveStoragePdfPublisherJob
to use Grover to build PDFsRoboto
andTinos
fonts