build-image
build-image copied to clipboard
Add fonts to build image
Would you be open to adding more fonts to the build image, specifically ttf-mscorefonts-installer would be what I need.
Currently, only the DejaVu family is available. Output from fc-list:
/usr/share/fonts/truetype/dejavu/DejaVuSerif-Bold.ttf: DejaVu Serif:style=Bold
/usr/share/fonts/truetype/dejavu/DejaVuSansMono.ttf: DejaVu Sans Mono:style=Book
/usr/share/fonts/truetype/dejavu/DejaVuSans.ttf: DejaVu Sans:style=Book
/usr/share/fonts/truetype/dejavu/DejaVuSans-Bold.ttf: DejaVu Sans:style=Bold
/usr/share/fonts/truetype/dejavu/DejaVuSansMono-Bold.ttf: DejaVu Sans Mono:style=Bold
/usr/share/fonts/truetype/dejavu/DejaVuSerif.ttf: DejaVu Serif:style=Book
For more on what I'm trying to do, my build process involves generating a pdf version of some of my web pages. But right now they can only render in the DejaVu font.
Please let me know if a PR would be accepted adding this install to the dockerfile. Or if there's a way I can specify the dependency in my repo. Or if there's perhaps another way to solve this entirely! Thanks!
Did you manage to solve this issue on Netlify? - I am having the same issue for generating a PDF version of a documentation page.
Hi there, thanks for asking. I ended up just setting netlify to manual build (unlinking the git repo) and switching to building on travis-ci where I could install the fonts I needed: https://github.com/devm33/devm33.com/blob/master/.travis.yml and deploy to netlify where their cli https://docs.netlify.com/cli/get-started/ authorized with an environment variable set in travis. Cheers!
Hey, thanks for the tip. I used a similar concept now. For anyone interested - this is the github actions equivalent: https://github.com/OpenHPS/openhps.org/blob/master/.github/workflows/main.yml