wkhtmltopdf and wkhtmltoimage are command line tools to render HTML into PDF and various image formats using the QT Webkit rendering engine. These run entirely "headless" and do not require a display or display service.
See http://wkhtmltopdf.org for updated documentation.
wkhtmltopdf has its own dedicated repository for building and packaging.
Copy the snippet above into CLI.