Add dockerfile
This commit is contained in:
parent
4ab6e7053d
commit
dc929e3186
|
@ -0,0 +1,5 @@
|
|||
_doxyxml
|
||||
_build
|
||||
|
||||
.python-version
|
||||
.git
|
|
@ -0,0 +1,27 @@
|
|||
FROM ubuntu:xenial
|
||||
|
||||
RUN apt-get update && apt-get install -y --no-install-recommends \
|
||||
curl \
|
||||
python3 \
|
||||
python3-pip \
|
||||
python3-setuptools \
|
||||
python3-pygments \
|
||||
git \
|
||||
make \
|
||||
doxygen \
|
||||
&& apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/*
|
||||
|
||||
RUN pip3 install --no-cache-dir --no-binary :all: \
|
||||
sphinx \
|
||||
breathe
|
||||
|
||||
RUN curl -sL https://deb.nodesource.com/setup_7.x | bash - && \
|
||||
apt-get install -y nodejs && \
|
||||
npm install -g html-minifier
|
||||
|
||||
VOLUME /data/esphomedocs
|
||||
VOLUME /data/esphomelib
|
||||
EXPOSE 8000
|
||||
WORKDIR /data/esphomedocs
|
||||
|
||||
CMD ["make", "webserver"]
|
18
Makefile
18
Makefile
|
@ -9,12 +9,12 @@ SOURCEDIR = .
|
|||
BUILDDIR = _build
|
||||
ESPHOMELIB_PATH = ../esphomelib
|
||||
|
||||
.PHONY: html cleanhtml minifyhtml doxyg cleandoxyg copypdf fixdeploy releasedeploy help webserver Makefile
|
||||
.PHONY: html cleanhtml minifyhtml doxyg cleandoxyg deploy help webserver Makefile
|
||||
|
||||
html: _doxyxml
|
||||
$(SPHINXBUILD) -M html "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
|
||||
|
||||
cleanhtml: cleandoxy
|
||||
cleanhtml: cleandoxyg
|
||||
rm -rf "$(BUILDDIR)/html/*"
|
||||
|
||||
minifyhtml: html
|
||||
|
@ -28,21 +28,9 @@ cleandoxyg:
|
|||
_doxyxml:
|
||||
ESPHOMELIB_PATH=$(ESPHOMELIB_PATH) doxygen Doxygen
|
||||
|
||||
copypdf:
|
||||
cp $(BUILDDIR)/latex/$(SPHINXPROJ).pdf $(BUILDDIR)/esphomelib.pdf
|
||||
|
||||
fixdeploy: copypdf cleanhtml doxyg html minifyhtml
|
||||
deploy: cleanhtml doxyg html minifyhtml
|
||||
touch "$(BUILDDIR)/html/.nojekyll"
|
||||
echo "esphomelib.com" >"$(BUILDDIR)/html/CNAME"
|
||||
cp $(BUILDDIR)/esphomelib.pdf $(BUILDDIR)/latex/$(SPHINXPROJ).pdf
|
||||
cd "$(BUILDDIR)/html" && git add --all && git commit -m "Deploy to gh-pages"
|
||||
@printf "Run \033[0;36mcd $(BUILDDIR)/html && git push origin gh-pages\033[0m to deploy\n"
|
||||
|
||||
releasedeploy: cleanhtml doxyg html minifyhtml
|
||||
touch "$(BUILDDIR)/html/.nojekyll"
|
||||
echo "esphomelib.com" >"$(BUILDDIR)/html/CNAME"
|
||||
-yes '' | make latexpdf
|
||||
cp $(BUILDDIR)/latex/$(SPHINXPROJ).pdf $(BUILDDIR)/html/_static/esphomelib.pdf
|
||||
cd "$(BUILDDIR)/html" && git add --all && git commit -m "Deploy to gh-pages"
|
||||
@printf "Run \033[0;36mcd $(BUILDDIR)/html && git push origin gh-pages\033[0m to deploy\n"
|
||||
|
||||
|
|
|
@ -540,8 +540,6 @@ This list contains items that are technically already supported by other compone
|
|||
Do you have other awesome automations or 2nd order components? Please feel free to add them to the
|
||||
documentation for others to copy. See :doc:`Contributing <guides/contributing>`.
|
||||
|
||||
`Download the documentation as a PDF </_static/esphomelib.pdf>`__
|
||||
|
||||
.. toctree::
|
||||
:hidden:
|
||||
|
||||
|
|
Loading…
Reference in New Issue