mirror of
https://github.com/ldericher/autodoc.git
synced 2025-12-06 15:43:01 +00:00
experimental alpine support for diagram feature (sometimes hangs?)
This commit is contained in:
parent
91699e95ca
commit
5b8786fb33
1 changed files with 27 additions and 1 deletions
|
|
@ -1,4 +1,4 @@
|
|||
FROM pandoc/extra:latest
|
||||
FROM pandoc/extra:latest AS stage-base
|
||||
|
||||
RUN set -ex; \
|
||||
\
|
||||
|
|
@ -20,3 +20,29 @@ COPY src/usr /usr
|
|||
WORKDIR /docs
|
||||
ENTRYPOINT ["autodoc"]
|
||||
CMD ["-bw"]
|
||||
|
||||
FROM stage-base AS stage-diagram
|
||||
|
||||
ENV PUPPETEER_CACHE_DIR="/usr/local/share/puppeteer/cache" \
|
||||
PUPPETEER_EXECUTABLE_PATH="/usr/bin/chromium-browser" \
|
||||
PUPPETEER_SKIP_CHROMIUM_DOWNLOAD="true"
|
||||
|
||||
COPY src/diagram.lua.patch /usr/local/src/autodoc/diagram.lua.patch
|
||||
|
||||
RUN set -ex; \
|
||||
\
|
||||
apk add --no-cache \
|
||||
chromium \
|
||||
npm \
|
||||
patch \
|
||||
; \
|
||||
\
|
||||
npm install --global @mermaid-js/mermaid-cli; \
|
||||
# rm -rf /root/.cache/puppeteer; \
|
||||
\
|
||||
wget \
|
||||
--output-document='/usr/local/share/pandoc/filters/diagram.lua' \
|
||||
'https://raw.githubusercontent.com/pandoc-ext/diagram/refs/heads/main/_extensions/diagram/diagram.lua' \
|
||||
; \
|
||||
patch /usr/local/share/pandoc/filters/diagram.lua < /usr/local/src/autodoc/diagram.lua.patch; \
|
||||
rm /usr/local/src/autodoc/diagram.lua.patch;
|
||||
|
|
|
|||
Loading…
Reference in a new issue