I have a simple LiveView app that
- write user input to a temporary markup file (
content.typ), - drops to
System.cmd/2to process this markup with a CLI (typst), and - deliver the output (
content.png) to the client
In dev, I specify the path for the temporary files as
Application.app_dir(:typeset, "priv/static/uploads/")
and this works on my machine™.
I then have this dockerized and deployed on Fly, copying the Typst CLI to /bin and verified the CLI works by ssh in.
However, the temp files are now written to a directory that does not exist.
** (File.Error) could not write to file "/app/_build/prod/lib/typeset/priv/static/uploads/content.typ"
What is the proper way of handling temporary files, to be processed with a CLI, when deploying?






















