Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

467
Visualizações
Installing wkhtmltopdf on Python 3.6 Alpine

Has anyone been able to install wkhtmltopdf on python:3.6.0-alpine.

I have tried all the solutions present on the internet. I need to use pdfkit which internally uses wkhtmltopython to convert html to pdf.

over 4 years ago · Santiago Trujillo
2 Respostas
Responde à pergunta

0

You might need wkhtmltopdf and xvfb to run on a server:

apk add wkhtmltopdf xvfb
over 4 years ago · Santiago Trujillo Relatório

0

In case someone would like to have the full line that needs to be added to the Dockerfile:

RUN apk update && apk add wkhtmltopdf

or:

RUN apt-get update && apt-get install -y wkhtmltopdf

You can then use the following code in your "Dockerized" Python script:

import pdfkit
path_wkhtmltopdf = '/usr/bin/wkhtmltopdf'
config = pdfkit.configuration(wkhtmltopdf=path_wkhtmltopdf)
pdfkit.from_string(html, '<direction/of/the/report.pdf>', configuration=config)
over 4 years ago · Santiago Trujillo Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda