From 88a1619dd5e4500523cb4fe83f8ca624159065bc Mon Sep 17 00:00:00 2001 From: Michael Jensen Date: Mon, 27 Sep 2021 01:01:41 -0600 Subject: [PATCH] document pre-docker build command (#2164) Co-authored-by: Georg Lauterbach <44545919+georglauterbach@users.noreply.github.com> --- .../examples/tutorials/docker-build.md | 22 +++++++++++++++++++ docs/mkdocs.yml | 3 ++- 2 files changed, 24 insertions(+), 1 deletion(-) create mode 100644 docs/content/examples/tutorials/docker-build.md diff --git a/docs/content/examples/tutorials/docker-build.md b/docs/content/examples/tutorials/docker-build.md new file mode 100644 index 00000000..accc09e7 --- /dev/null +++ b/docs/content/examples/tutorials/docker-build.md @@ -0,0 +1,22 @@ +--- +title: 'Tutorials | Docker Build' +--- + +## Building your own Docker image + +You'll need to retrieve the git submodules prior to building your own Docker image. From within your copy of the git repo run the following to retrieve the submodules and build the Docker image: + +```sh +git submodule update --init --recursive +docker build . +``` + +Or, you can clone and retrieve the submodules in one command: +```sh +git clone --recurse-submodules https://github.com/docker-mailserver/docker-mailserver +``` + +Retrieving the git submodules will fix the error: +``` +COPY failed: file not found in build context or excluded by .dockerignore: stat target/docker-configomat/configomat.sh: file does not exist +``` diff --git a/docs/mkdocs.yml b/docs/mkdocs.yml index c85ce93c..b520737e 100644 --- a/docs/mkdocs.yml +++ b/docs/mkdocs.yml @@ -146,7 +146,8 @@ nav: - 'Examples': - 'Tutorials': - 'Basic Installation': examples/tutorials/basic-installation.md - - 'Mail-Server behind a Proxy': examples/tutorials/mailserver-behind-proxy.md + - 'Mailserver behind Proxy': examples/tutorials/mailserver-behind-proxy.md + - 'Building your own Docker image': examples/tutorials/docker-build.md - 'Blog Posts': examples/tutorials/blog-posts.md - 'Use Cases': - 'Forward-Only Mail-Server with LDAP': examples/uses-cases/forward-only-mailserver-with-ldap-authentication.md