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

WIP: Attempt to Reenable TestInet{EndPoint,LayerDNS} for CI #500

Conversation

gerickson
Copy link
Contributor

Problem

TestInet{EndPoint,LayerDNS} needs IPv6 support and Docker on macOS does not support (and has not supported) IPv6.

Summary of Changes

However, now that we have stood up CI against Travis CI and/or GitHub actions with Docker on Linux instances, this may be mitigated and only an issue for local developers on macOS.

Trying moving TestInet{EndPoint,LayerDNS} from noinst_PROGRAMS back to check_PROGRAMS.

Fixes #323 and #329

@gerickson
Copy link
Contributor Author

gerickson commented Apr 24, 2020

Negative. TestInet{EndPoint,LayerDNS} still fail with Docker:

make -C ../../../src/include/ CHIPVersion.h
make -C ../../ .local-version
  CHECK         .local-version
  CHECK         CHIPVersion.h
FAIL: TestInetEndPoint
PASS: TestInetErrorStr
FAIL: TestInetLayerDNS
PASS: TestInetTimer
============================================================================
Testsuite summary for Chip g43992b7
============================================================================
# TOTAL: 6
# PASS:  4
# SKIP:  0
# XFAIL: 0
# FAIL:  2
# XPASS: 0
# ERROR: 0
============================================================================
See src/inet/tests/test-suite.log
Please report to [email protected]
============================================================================
Makefile:1106: recipe for target 'test-suite.log' failed
make[6]: *** [test-suite.log] Error 1
Makefile:1212: recipe for target 'check-TESTS' failed
make[5]: *** [check-TESTS] Error 2
Makefile:1320: recipe for target 'check-am' failed
make[4]: *** [check-am] Error 2
Makefile:1155: recipe for target 'check-recursive' failed
make[3]: *** [check-recursive] Error 1
make[2]: *** [check-recursive] Error 1
Makefile:573: recipe for target 'check-recursive' failed
make[1]: *** [check-recursive] Error 1
Makefile:702: recipe for target 'check-recursive' failed
Makefile:994: recipe for target 'check' failed
make: *** [check] Error 2
make: Leaving directory '/home/travis/build/project-chip/connectedhomeip/build/default'
The command "./integrations/ci-tools/build.sh" exited with 2.

Though for Linux hosts on Travis CI, it looks like it should work if so configured with this: https://docs.docker.com/config/daemon/ipv6/.

@gerickson
Copy link
Contributor Author

Negative. TestInet{EndPoint,LayerDNS} still fail with Docker:

make -C ../../../src/include/ CHIPVersion.h
make -C ../../ .local-version
  CHECK         .local-version
  CHECK         CHIPVersion.h
FAIL: TestInetEndPoint
PASS: TestInetErrorStr
FAIL: TestInetLayerDNS
PASS: TestInetTimer
============================================================================
Testsuite summary for Chip g43992b7
============================================================================
# TOTAL: 6
# PASS:  4
# SKIP:  0
# XFAIL: 0
# FAIL:  2
# XPASS: 0
# ERROR: 0
============================================================================
See src/inet/tests/test-suite.log
Please report to [email protected]
============================================================================
Makefile:1106: recipe for target 'test-suite.log' failed
make[6]: *** [test-suite.log] Error 1
Makefile:1212: recipe for target 'check-TESTS' failed
make[5]: *** [check-TESTS] Error 2
Makefile:1320: recipe for target 'check-am' failed
make[4]: *** [check-am] Error 2
Makefile:1155: recipe for target 'check-recursive' failed
make[3]: *** [check-recursive] Error 1
make[2]: *** [check-recursive] Error 1
Makefile:573: recipe for target 'check-recursive' failed
make[1]: *** [check-recursive] Error 1
Makefile:702: recipe for target 'check-recursive' failed
Makefile:994: recipe for target 'check' failed
make: *** [check] Error 2
make: Leaving directory '/home/travis/build/project-chip/connectedhomeip/build/default'
The command "./integrations/ci-tools/build.sh" exited with 2.

Though for Linux hosts on Travis CI, it looks like it should work if so configured with this: https://docs.docker.com/config/daemon/ipv6/.

Trying 9dcd412 to see if that, at least, addresses the issue in the base Travis CI Linux container. There may still be more Docker configuration required.

@gerickson
Copy link
Contributor Author

Negative. TestInet{EndPoint,LayerDNS} still fail with Docker:

make -C ../../../src/include/ CHIPVersion.h
make -C ../../ .local-version
  CHECK         .local-version
  CHECK         CHIPVersion.h
FAIL: TestInetEndPoint
PASS: TestInetErrorStr
FAIL: TestInetLayerDNS
PASS: TestInetTimer
============================================================================
Testsuite summary for Chip g43992b7
============================================================================
# TOTAL: 6
# PASS:  4
# SKIP:  0
# XFAIL: 0
# FAIL:  2
# XPASS: 0
# ERROR: 0
============================================================================
See src/inet/tests/test-suite.log
Please report to [email protected]
============================================================================
Makefile:1106: recipe for target 'test-suite.log' failed
make[6]: *** [test-suite.log] Error 1
Makefile:1212: recipe for target 'check-TESTS' failed
make[5]: *** [check-TESTS] Error 2
Makefile:1320: recipe for target 'check-am' failed
make[4]: *** [check-am] Error 2
Makefile:1155: recipe for target 'check-recursive' failed
make[3]: *** [check-recursive] Error 1
make[2]: *** [check-recursive] Error 1
Makefile:573: recipe for target 'check-recursive' failed
make[1]: *** [check-recursive] Error 1
Makefile:702: recipe for target 'check-recursive' failed
Makefile:994: recipe for target 'check' failed
make: *** [check] Error 2
make: Leaving directory '/home/travis/build/project-chip/connectedhomeip/build/default'
The command "./integrations/ci-tools/build.sh" exited with 2.

Though for Linux hosts on Travis CI, it looks like it should work if so configured with this: https://docs.docker.com/config/daemon/ipv6/.

Trying 9dcd412 to see if that, at least, addresses the issue in the base Travis CI Linux container. There may still be more Docker configuration required.

No go with that change. Will try something alone these lines.


linux)
# By default, Travis CI does not have IPv6 enabled on
# Linux. Ensure that IPv6 is enabled since Weave, and its unit
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: Change Weave to CHIP

@rwalker-apple
Copy link
Contributor

If you please: ensure unrelated commits you've incorporated have already landed prior to this one landing? This looks blunderbuss-y. I recognize some of the work, but not all.

@gerickson
Copy link
Contributor Author

If you please: ensure unrelated commits you've incorporated have already landed prior to this one landing? This looks blunderbuss-y. I recognize some of the work, but not all.

Yes, this is a WIP PR and should have been a draft as an experiment to try to get IPv6 working in Docker on Travis. I'll mark it as such.

@gerickson gerickson marked this pull request as draft April 27, 2020 19:28
@gerickson gerickson changed the title Attempt to Reenable TestInet{EndPoint,LayerDNS} for CI WIP: Attempt to Reenable TestInet{EndPoint,LayerDNS} for CI Apr 27, 2020
@gerickson gerickson force-pushed the user/gerickson/github-issue-323-and-329 branch from 5abde8e to 6ccf92e Compare April 27, 2020 19:39
@gerickson
Copy link
Contributor Author

We are moving from Travis CI to Circle CI: https://circleci.com/docs/2.0/faq/#can-i-use-ipv6-in-my-tests

@gerickson gerickson force-pushed the user/gerickson/github-issue-323-and-329 branch from 70f5913 to c8166f3 Compare May 14, 2020 04:21
@gerickson
Copy link
Contributor Author

Enabling IPv6 worked here, but failed here because of lack of sudo.

@gerickson
Copy link
Contributor Author

@gerickson
Copy link
Contributor Author

Some possible clues here: https://github.com/prometheus/blackbox_exporter/blob/master/.circleci/config.yml

@woody-apple, based on that example, I think the implication here is that the only way to use Docker is to manually launch Docker containers through the machine executor rather than launching them through the Docker executor.

@woody-apple
Copy link
Contributor

Yeah, once we get our plan upgraded tomorrow so it's not glacially slow, I'll take some stabs at this. Apologies for the delay.

@turon
Copy link
Contributor

turon commented Jun 26, 2020

Here is another article on setting up IPv6 on docker (including minimum version requirements):
https://collabnix.com/enabling-ipv6-functionality-for-docker-and-docker-compose/

And this article describes how to setup Docker in CircleCI within a machine executor so you have access to /etc/docker/daemon.json file:
https://circleci.com/docs/2.0/building-docker-images/

NOTE: currently when you ssh into a fully sandboxed CircleCI docker, there is no /etc/docker folder at all.

It seems #803 is actually a working solution that resolves the issue using machine executor approach.

@woody-apple
Copy link
Contributor

@andy31415 @gerickson - is this OK to close, now that #1372 is in?

@gerickson gerickson closed this Jun 30, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

After Issue #300 Is Addressed, Move TestInetEndPoint from noinst_PROGRAMS Back to check_PROGRAMS
6 participants