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

Simplify internals #655

Open
kegsay opened this issue Oct 2, 2023 · 3 comments
Open

Simplify internals #655

kegsay opened this issue Oct 2, 2023 · 3 comments
Milestone

Comments

@kegsay
Copy link
Member

kegsay commented Oct 2, 2023

The idea of running docker containers in Go tests isn't new. It was reasonably new back when Complement started, but now there are libraries we could use instead, notably https://github.com/testcontainers/testcontainers-go

We should consider using this internally. This would be transparent to tests as they have a separate API shape, and greatly simplify the burden of maintaining Complement internals, as the cost of an extra dependency. This dependency though is backed by a number of companies and does test containers for other languages as well, not just Go.

@kegsay kegsay added this to the v1 milestone Oct 2, 2023
@mdelapenya
Copy link

Hi from Testcontaines for Go! 👋 I landed here after a quick search on Github. Please let us know if we can help out adopting the project.

@kegsay
Copy link
Member Author

kegsay commented Jan 21, 2025

I've extensively used testcontainers for other end-to-end style tests in CI and it seems for the most part to work well, though ryuk seems a little too eager in terminating running containers for some reason. Nonetheless, the original issue still stands, it reduces the complexity burden of maintaining Complement, it's just something we need to actually get around to doing.

@mdelapenya
Copy link

Thanks for letting me know! We worked in having a more robust Ryuk in terms of how it prunes containers. You probably want to give it a try to the latest version of testcontainers-go, which includes the ability to use the settings described in here: https://github.com/testcontainers/moby-ryuk?tab=readme-ov-file#ryuk-configuration

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

No branches or pull requests

2 participants