This is an example of using the Serverless Framework to deploy an AWS lambda which runs a PHP function for converting chess games from lichess into a pretty-printed PDF.
See my blog post here.
Install this serverless project. It will create a new serverless-php folder.
serverless install --url https://github.com/ZeroSharp/serverless-lichess-pdf-exporter
Check the serverless.yml
file and modify region and stage if necessary.
sls deploy
sls invoke local --function Xp9MOs3d > Xp9MOs3d.pdf
sls invoke --function Xp9MOs3d > Xp9MOs3d.pdf
Thanks to James Clarke who wrote the PHP exporter.