From 049e5cd4985a04c45c97eb5f1241f476ec173da5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?St=C3=A9phane=20Goetz?= Date: Tue, 5 Jun 2018 22:40:38 +0200 Subject: [PATCH] Document how you can create a docker image with the documentation inside. Fixes #37 --- Dockerfile | 1 + docs/01_Features/Live_mode.md | 18 ++++++++++++++++++ 2 files changed, 19 insertions(+) diff --git a/Dockerfile b/Dockerfile index 692f5f2..d6728a7 100644 --- a/Dockerfile +++ b/Dockerfile @@ -16,6 +16,7 @@ COPY tipuesearch/ /daux/tipuesearch/ COPY global.json /daux/global.json COPY composer.json /daux/composer.json COPY composer.lock /daux/composer.lock +COPY index.php /daux/index.php # Composer install RUN cd /daux && php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');" \ diff --git a/docs/01_Features/Live_mode.md b/docs/01_Features/Live_mode.md index d884928..343f044 100644 --- a/docs/01_Features/Live_mode.md +++ b/docs/01_Features/Live_mode.md @@ -97,3 +97,21 @@ The `web.config` needs an entry for `` under ``: ``` To use clean URLs on IIS 6, you will need to use a custom URL rewrite module, such as [URL Rewriter](http://urlrewriter.net/). + +## Docker + +This is not meant for production use, but you can bundle your documentation in Daux's docker container + +``` +FROM daux/daux.io + +WORKDIR /daux/ +COPY docs/ /daux/docs/ + +EXPOSE 80 +ENTRYPOINT [ "php", "-S", "0.0.0.0:80", "index.php" ] +``` + +When you add this to a `Dockerfile` and run `docker build --name my-daux-doc .` and then `docker --rm run -p 8000:80 my-daux-doc` + +You can access your documentation at `localhost:8000` \ No newline at end of file