testcontainers-go
testcontainers-go copied to clipboard
[Enhancement]: controllable retries for pulling images
Proposal
Heya!
We're using TC 0.34.0, and you know we're huge fans. 👏
Regardless, our CI runs are too flaky lately -- it takes a few retries (manually, via the Github UI) to get them in to a green state. This is not a TC problem. However, looking closely at what goes wrong, I've found a thing that seems avoidable:
lifecycle.go:62: 🐳 Creating container for image gvenzl/oracle-free:slim-faststart
our_test.go:58: create container: container create: Error response from daemon: No such image: gvenzl/oracle-free:slim-faststart
That image most certainly exists. So guessing at what happened, Dockerhub might have had some intermittent issues -- but it would be great if we could have our CI run not fail because of that.
I've found https://github.com/testcontainers/testcontainers-go/issues/2502, which declares "not found" as non-retriable, but I'm wondering if this could be something that's controllable...?
Or maybe some parameter that lets me give the setup more leeway when run on Github actions? 🤔 Maybe something like this already exists -- so I figured I might just raise the question with you. Thanks in advance!