Container structure test binary is only available for OSX or Linux (https://github.com/GoogleCloudPlatform/container-structure-test). Using this Docker image, tests can be launched on a Windows host.
docker run --rm -v "<path-to-tests-config-file>:/test-config/tests_config.yaml" \
-v /var/run/docker.sock:/var/run/docker.sock flopes/container-structure-test-docker "test --image <image-to-test> --config tests_config.yaml"
docker-compose.yml
template:
version: '3'
services:
docker:
image: flopes/container-structure-test-docker
volumes:
- ".tests_config.yaml:/test-config/tests_config.yaml"
- "/var/run/docker.sock:/var/run/docker.sock"
command: test --image ${YOUR_IMAGE} --config tests_config.yaml
.env
COMPOSE_CONVERT_WINDOWS_PATHS=1
More info on container-structure-test usage: https://github.com/GoogleCloudPlatform/container-structure-test.
CONTAINER_STRUCTURE_TEST_DOWNLOAD_URL
: URL where to download container-structure-test binary