adieuadieu / serverless-chrome

🌐 Run headless Chrome/Chromium on AWS Lambda
MIT License
2.86k stars 281 forks source link

@serverless-chrome/lambda Custom font problems #204

Closed ksyke closed 3 years ago

ksyke commented 5 years ago

Good day, this is my very first post here in github. Please excuse me if i did something wrong. Node: nodejs8.10

My question is quite simple. Are fonts treated differently in serverless-chrome launched in lambda than chrome launched locally (Windows10)?

These are samples of images generated from the same page.

This is from lambda: lambdatest

This is done locally: localtest

alixaxel commented 5 years ago

@ksyke Lambda only ships with DejaVu font face, see https://github.com/alixaxel/chrome-aws-lambda/issues/37#issuecomment-493646469

olecom commented 5 years ago

@ksyke if same look is needed then all used fonts should be provided into lambda execution environment for chrome (e.g. in ~/.fonts/ directory), example: https://github.com/adieuadieu/serverless-chrome/issues/184#issuecomment-480028352