Dockerfile.docs 916 B

1234567891011121314151617181920212223242526272829
  1. ARG PYVER=3.8
  2. FROM python:${PYVER}-alpine
  3. WORKDIR /netdata
  4. # These scripts use Bash(ism) so install Bash
  5. # TODO: Maybe rewrite the link checker in something more sane
  6. RUN apk add --no-cache -U bash
  7. # The scripts also clone the netdata/netdata repo using git
  8. # TODO: Maybe also optionally support bind-mounted sources
  9. RUN apk add --no-cache -U git
  10. # The scripts also use GNU find options
  11. RUN apk add --no-cache -U findutils
  12. # (20200415) Some Python dependnecy now requires gcc as part of its build step.
  13. RUN apk add --no-cache -U build-base
  14. # Copy and Install build dependencies first to cache them so we don't have to
  15. # do this every single time we want to rebuild the docs. The cache is busted
  16. # when/if the SHA of the requirements.txt is changed.
  17. COPY docs/generator /netdata/docs/generator
  18. RUN pip install -r /netdata/docs/generator/requirements.txt
  19. COPY . .
  20. CMD ["/netdata/docs/generator/buildhtml.sh"]