From c122bb196f98660fc3a91948f4047c642f3af222 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebastian=20H=C3=A4t=C3=A4l=C3=A4?= <63060811+sebastian-hatala-leanix@users.noreply.github.com> Date: Fri, 17 Jul 2020 15:49:45 +0200 Subject: [PATCH 1/3] add description for running testcontainers from docker --- README.rst | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/README.rst b/README.rst index 9a8760286..8dc58a69b 100644 --- a/README.rst +++ b/README.rst @@ -51,6 +51,15 @@ The snippet above will spin up a MySql database in a container. The :code:`get_c More extensive documentation can be found at `Read The Docs `_. +Usage within Docker (i.e. in a CI) +---------------------------------- + +When trying to launch a testcontainer from within a Docker container two things have to be provided: + +1. The container has to provide a docker client installation. Either use a container that has docker pre-installed (e.g. https://hub.docker.com/_/docker) or install the client from within the dockerfile specification. +2. Also, the container has to have access to a docker build daemon. For this mount the file /var/run/docker.sock in your docker run command. + + Setting up a development environment ------------------------------------ From e9abf39b188fd572eada3be85fc77e8111ccc3c7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebastian=20H=C3=A4t=C3=A4l=C3=A4?= <63060811+sebastian-hatala-leanix@users.noreply.github.com> Date: Mon, 17 Aug 2020 12:14:07 +0200 Subject: [PATCH 2/3] adapt suggested changes regarding container wording Co-authored-by: Till Hoffmann --- README.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.rst b/README.rst index 8dc58a69b..eb28f2b53 100644 --- a/README.rst +++ b/README.rst @@ -56,7 +56,7 @@ Usage within Docker (i.e. in a CI) When trying to launch a testcontainer from within a Docker container two things have to be provided: -1. The container has to provide a docker client installation. Either use a container that has docker pre-installed (e.g. https://hub.docker.com/_/docker) or install the client from within the dockerfile specification. +1. The container has to provide a docker client installation. Either use an image that has docker pre-installed (e.g. the [official docker images](https://hub.docker.com/_/docker)) or install the client from within the `Dockerfile` specification. 2. Also, the container has to have access to a docker build daemon. For this mount the file /var/run/docker.sock in your docker run command. From 3821515e2c6f1fa207004214451cd4a0ed263114 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebastian=20H=C3=A4t=C3=A4l=C3=A4?= <63060811+sebastian-hatala-leanix@users.noreply.github.com> Date: Mon, 17 Aug 2020 12:14:35 +0200 Subject: [PATCH 3/3] adapt suggested changes regarding build wording Co-authored-by: Till Hoffmann --- README.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.rst b/README.rst index eb28f2b53..5d7e7fbb6 100644 --- a/README.rst +++ b/README.rst @@ -57,7 +57,7 @@ Usage within Docker (i.e. in a CI) When trying to launch a testcontainer from within a Docker container two things have to be provided: 1. The container has to provide a docker client installation. Either use an image that has docker pre-installed (e.g. the [official docker images](https://hub.docker.com/_/docker)) or install the client from within the `Dockerfile` specification. -2. Also, the container has to have access to a docker build daemon. For this mount the file /var/run/docker.sock in your docker run command. +2. The container has to have access to the docker daemon which can be achieved by mounting `/var/run/docker.sock` or setting the `DOCKER_HOST` environment variable as part of your `docker run` command. Setting up a development environment