Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Run Windows CI on every PR #167

Open
iamdanfox opened this issue Mar 1, 2017 · 7 comments
Open

Run Windows CI on every PR #167

iamdanfox opened this issue Mar 1, 2017 · 7 comments

Comments

@iamdanfox
Copy link
Contributor

We're issuing commands which need different escaping on Mac / windows. Let's get some AppVeyor CI going.

#166

@iamdanfox
Copy link
Contributor Author

iamdanfox commented Mar 2, 2017

@samwright I've got AppVeyor approved so we should be unblocked to actually put Windows CI on all PRs for docker compose rule :)

screen shot 2017-03-02 at 13 46 29

screen shot 2017-03-02 at 13 49 19

@samwright
Copy link

That's excellent news! You'll find the build will fail (lots of test failures) until #169 and #171 are merged. You'll also need to set the DOCKER_LOCATION and DOCKER_COMPOSE_LOCATION env variables, or merge #170 (which scans $PATH instead).

It might be easier to merge those before enabling the windows build, but that's your choice.

@samwright
Copy link

I've got just one more test to fix: HostNetworkedPortsIntegrationTest. This tests that having docker use the 'host' network type means the container uses the host's network, so the host can see connect to all container ports on localhost and vice-versa (afaik). I get the following:

java.lang.IllegalStateException: The cluster failed to pass a startup check: DockerPort [ip=127.0.0.1, portMapping=PortMapping [externalPort=5432, internalPort=5432]]was not listening

Since docker on windows/mac is actually running inside a linux VM, the "host" is not 127.0.0.1 but the linux VM (running on 10.0.75.1), and its firewall/docker seems to prevent connecting to these ports (i.e. curl 10.0.75.1:5432 fails). Here is a discussion showing that this is intended behaviour: https://forums.docker.com/t/should-docker-run-net-host-work/14215.

@iamdanfox You mentioned you're on Mac, so if I'm correct you should be having the same problem running HostNetworkedPortsIntegrationTest. Is this correct? If so I guess the best course would be to use JUnit's Assume to skip the test when on Windows/Mac.

@hpryce
Copy link
Contributor

hpryce commented Mar 6, 2017

@samwright you are correct this doesn't work on Mac - I believe when the test was originally written it was before Docker for Mac existed and while the behaviour with docker-machine wasn't great it was at least functional. Using an assume here seems like the best thing to do.

@samwright
Copy link

Just an update, docker-compose-rule now builds on Windows and passes all tests :-D

@hpryce
Copy link
Contributor

hpryce commented Mar 8, 2017

@samwright excellent. Unfortunately appveyor only supports Windows containers so I'm adding a quick smoke test that uses a Windows base image to ensure we don't regress in the future.

@fryz
Copy link
Contributor

fryz commented Apr 30, 2018

@hpryce @iamdanfox - looks like this is resolved - just want to double check and make sure that's the case.

We good to close this out?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants