mirror of
https://github.com/moby/moby.git
synced 2022-11-09 12:21:53 -05:00
Merge pull request #3598 from tianon/fix-vieux-docs-errors-again
Fix odd issues with "make docs", add "make docs-shell", and canonicalize...
This commit is contained in:
commit
cdea7d3b5f
2 changed files with 21 additions and 17 deletions
11
Makefile
11
Makefile
|
@ -1,4 +1,4 @@
|
|||
.PHONY: all binary build cross default docs shell test
|
||||
.PHONY: all binary build cross default docs docs-build docs-shell shell test
|
||||
|
||||
GIT_BRANCH := $(shell git rev-parse --abbrev-ref HEAD)
|
||||
DOCKER_IMAGE := docker:$(GIT_BRANCH)
|
||||
|
@ -16,10 +16,12 @@ binary: build
|
|||
cross: build
|
||||
$(DOCKER_RUN_DOCKER) hack/make.sh binary cross
|
||||
|
||||
docs:
|
||||
docker build -rm -t "$(DOCKER_DOCS_IMAGE)" docs
|
||||
docs: docs-build
|
||||
docker run -rm -i -t -p 8000:8000 "$(DOCKER_DOCS_IMAGE)"
|
||||
|
||||
docs-shell: docs-build
|
||||
docker run -rm -i -t -p 8000:8000 "$(DOCKER_DOCS_IMAGE)" bash
|
||||
|
||||
test: build
|
||||
$(DOCKER_RUN_DOCKER) hack/make.sh test test-integration
|
||||
|
||||
|
@ -29,5 +31,8 @@ shell: build
|
|||
build: bundles
|
||||
docker build -rm -t "$(DOCKER_IMAGE)" .
|
||||
|
||||
docs-build:
|
||||
docker build -rm -t "$(DOCKER_DOCS_IMAGE)" docs
|
||||
|
||||
bundles:
|
||||
mkdir bundles
|
||||
|
|
|
@ -1,20 +1,19 @@
|
|||
from ubuntu:12.04
|
||||
maintainer Nick Stinemates
|
||||
FROM stackbrew/ubuntu:12.04
|
||||
MAINTAINER Nick Stinemates
|
||||
#
|
||||
# docker build -t docker:docs . && docker run -p 8000:8000 docker:docs
|
||||
#
|
||||
|
||||
run apt-get update
|
||||
run apt-get install -y python-setuptools make
|
||||
run easy_install pip
|
||||
#from docs/requirements.txt, but here to increase cacheability
|
||||
run pip install --no-use-wheel Sphinx==1.1.3
|
||||
run pip install --no-use-wheel sphinxcontrib-httpdomain==1.1.9
|
||||
add . /docs
|
||||
run cd /docs; make docs
|
||||
# TODO switch to http://packages.ubuntu.com/trusty/python-sphinxcontrib-httpdomain once trusty is released
|
||||
|
||||
expose 8000
|
||||
RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -yq make python-pip python-setuptools
|
||||
# pip installs from docs/requirements.txt, but here to increase cacheability
|
||||
RUN pip install Sphinx==1.1.3
|
||||
RUN pip install sphinxcontrib-httpdomain==1.1.9
|
||||
ADD . /docs
|
||||
RUN make -C /docs clean docs
|
||||
|
||||
workdir /docs/_build/html
|
||||
|
||||
entrypoint ["python", "-m", "SimpleHTTPServer"]
|
||||
WORKDIR /docs/_build/html
|
||||
CMD ["python", "-m", "SimpleHTTPServer"]
|
||||
# note, EXPOSE is only last because of https://github.com/dotcloud/docker/issues/3525
|
||||
EXPOSE 8000
|
||||
|
|
Loading…
Add table
Reference in a new issue