I need to convert SVG with custom fonts into PNG, I’m using the following Python code for this.
import cairosvg
png = cairosvg.svg2png(bytestring=svg_data)
The code works fine on my local machine (running under Mac OS) with installed fonts. However, when I try to deploy it to remote Ubuntu instance the fonts somehow couldn't be loaded and I end up with PNG having some default fonts in it. The fonts are installed in the system (I've already tried different font folders, also fontconfig has the fonts in the list of available fonts) and the access rights seem to be in order. Any hints what could be going wrong will be useful!
Managed to solve the problem using Wand:
P.S. CairoSVG version still doesn't work.