Closed ronaldtse closed 3 years ago
When in the Docker environment, we can't necessarily store the fonts inside the host homedir because the docker volume may not be shared with local disk.
That's why we need to make the container's ~/.metanorma/fonts
a volume and install the fonts there. If the user chooses to mount his real ~/.metanorma/fonts
dir to the container's identical path, that's fine.
Otherwise, this docker mechanism will allow caching across metanorma runs.
@ronaldtse @abunashir as far as I understood this ticket blocked by https://github.com/metanorma/metanorma/issues/95 , can you confirm this?
@CAMOBAP795 yes.
This is relevant to #73 .
Already done
When using the new PDF functionality, the docker container will need to have fonts downloaded before running some PDF layouts or the output will not have the proper fonts (e.g. ISO flavor requires Cambria).
When using the docker container, there should be a command to setup fonts in a volume before
metanorma
command runs.These 3 cases need to be supported:
~/.metanorma
when doing step 2. This allows the user to share the fonts between the metanorma installed in the local (host) system and the docker metanorma.We can setup a docker volume to store fonts, e.g.
/config/fonts
. The user can map his/her own~/.metanorma
directory to/config
in order not to re-download fonts too.