Skip to content

Commit

Permalink
Adding Windows Subsystem for Linux section to the windows docum… (tes…
Browse files Browse the repository at this point in the history
…tcontainers#2282)

Co-authored-by: Luis Miguel Mejía Suárez <luis.miguel.mejia@hotmail.com>
Co-authored-by: Richard North <rich.north@gmail.com>

Co-authored-by: Luis Miguel Mejía Suárez <BalmungSan@users.noreply.github.com>
Co-authored-by: Kevin Wittek <kiview@users.noreply.github.com>
  • Loading branch information
3 people authored and quincy committed May 28, 2020
1 parent ab0c353 commit da346a0
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 3 deletions.
6 changes: 3 additions & 3 deletions docs/contributing.md
Expand Up @@ -4,9 +4,9 @@
* Join our [Slack group](http://slack.testcontainers.org)
* [Post an issue](https://github.com/testcontainers/testcontainers-java/issues) if you find any bugs
* Contribute improvements or fixes using a [Pull Request](https://github.com/testcontainers/testcontainers-java/pulls). If you're going to contribute, thank you! Please just be sure to:
* discuss with the authors on an issue ticket prior to doing anything big
* follow the style, naming and structure conventions of the rest of the project
* make commits atomic and easy to merge
* discuss with the authors on an issue ticket prior to doing anything big.
* follow the style, naming and structure conventions of the rest of the project.
* make commits atomic and easy to merge.
* when updating documentation, please see [our guidance for documentation contributions](contributing_docs.md).
* verify all tests are passing. Build the project with `./gradlew check` to do this.
**N.B.** Gradle's Build Cache is enabled by default, but you can add `--no-build-cache` flag to disable it.
Expand Down
1 change: 1 addition & 0 deletions docs/supported_docker_environment/index.md
Expand Up @@ -12,6 +12,7 @@
| Mac OS X - Docker for Mac | 1.12.0 | *Support is best-efforts at present*. `getTestHostIpAddress()` is [not currently supported](https://github.com/testcontainers/testcontainers-java/issues/166) due to limitations in Docker for Mac. |
| Windows - Docker Toolbox | | *Support is limited at present and this is not currently tested on a regular basis*. |
| Windows - Docker for Windows | | *Support is best-efforts at present.* Only Linux Containers (LCOW) are supported at the moment. See [Windows Support](windows.md) |
| Windows - Windows Subsystem for Linux (WSL) | Docker v17.06 | *Support is best-efforts at present.* Only Linux Containers (LCOW) are supported at the moment. See [Windows Support](windows.md). |

## Docker environment discovery

Expand Down
19 changes: 19 additions & 0 deletions docs/supported_docker_environment/windows.md
Expand Up @@ -23,6 +23,25 @@ effort.

* WCOW is currently not supported, since Testcontainers uses auxiliary Linux containers for certain tasks and Docker for Windows does not support hybrid engine mode at the time of writing.

## Windows Subsystem for Linux

Testcontainers supports communicating with Docker for Windows within the Windows Subsystem for Linux *([**WSL**](https://docs.microsoft.com/en-us/windows/wsl/about))*.
The following additional configurations steps are required:

+ Expose the Docker for Windows daemon on tcp port `2375` without **TLS**.
*(Right-click the Docker for Windows icon on the task bar, click setting and go to `General`)*.

+ Set the `DOCKER_HOST` environment variable inside the **WSL** shell to `tcp://localhost:2375`.
It is recommended to add this to your `~/.bashrc` file, so it’s available every time you open your terminal.

+ **Optional** - Only if volumes are required:
Inside the **WSL** shell, modify the `/ect/wsl.conf` file to mount the Windows drives on `/` instead of on `/mnt/`.
*(Reboot required after this step)*.
Remember to share the drives, on which you will store your volumes, with Docker for Windows.
*(Right-click the Docker for Windows icon on the task bar, click setting and go to `Shared Drives`)*.

More information about running Docker within the **WSL** can be found [here](https://nickjanetakis.com/blog/setting-up-docker-for-windows-and-wsl-to-work-flawlessly).

## Reporting issues

Please report any issues with the Windows build of Testcontainers [here](https://github.com/testcontainers/testcontainers-java/issues)
Expand Down

0 comments on commit da346a0

Please sign in to comment.