utils/Dockerfile
2023-08-18 18:23:46 -07:00

25 lines
713 B
Docker

ARG NODE_VERSION
FROM node:${NODE_VERSION}-alpine
WORKDIR /doc-utils
RUN apk add --no-cache \
python3 \
g++ \
make \
bash \
git
COPY package.json package-lock.json /doc-utils/
RUN --mount=type=secret,id=npmrc,target=/root/.npmrc npm ci
RUN ln -s /doc-utils/node_modules/@doc-utils/docs2website/bin/docs2website /bin/docs2website
RUN ln -s /doc-utils/node_modules/@doc-utils/jsonschema2markdown/bin/jsonschema2markdown /bin/jsonschema2markdown
RUN ln -s /doc-utils/node_modules/@doc-utils/markdown2html/bin/markdown2html /bin/markdown2html
RUN ln -s /doc-utils/node_modules/@doc-utils/markdown2html/bin/strip-frontmatter /bin/strip-frontmatter
WORKDIR /workspace
ENTRYPOINT [ "/bin/bash", "-l", "-c" ]