-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Duplicate image tags in local docker causing cache in LocalImagesCache #2431
Comments
Hi, we faced the same issue recently. Cause of the problem was not the testcontainers configuration, but docker itself. docker system prune -af P.S. Cleaning only containers didn't help |
Hello, We faced the same issue too. The problem seem to be in LocalImagesCache: Stream.of(repoTags).collect(Collectors.toMap(
DockerImageName::new,
it -> ImageData.from(image)
)) No distinct is made there and the Collectors.toMap then crash if there's duplicate in repoTags. Since you're not really supposed to have duplicate entries in the registry, that's why pruning get rid of the problem. I got rid of it by overriding the class definition in my application and adding |
Damn, looks like we have a bug if this is causing us to crash. @Choobz, if you'd care to submit a PR I'd be very grateful! |
Sure, I'll get to it. |
crashing for me too, thanks too look at it @Choobz ! |
…(duplicates repo tags) crashing the image pulling
…testcontainers#2692) * testcontainers#2431 Correction for an edge case in local image repos (duplicates repo tags) crashing the image pulling * Indentation correction * Indentation correction
Hello!
I have 5 spring batch tests I am running on a Jenkins pipeline. I am getting the following error only on ONE of the tests:
It seems like when the JVM terminates it is not properly cleaning up after itself. Thus, when it starts up again it is trying to start the container but it sees a duplicate container there.
Environment:
The text was updated successfully, but these errors were encountered: