-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
Pass env to ComposeDelegate in DockerComposeContainer#stop #8493
Conversation
This fixes issues on stopping when ENV-Variables are used inside the compose file. Issue was introduced in 7112db5. Fixes testcontainers#8492 Signed-off-by: Michael Musenbrock <[email protected]>
This is the same change as in DockerComposeContainer, even though no error is reported here, because COMPOSE_PROJECT_NAME seems sufficient Signed-off-by: Michael Musenbrock <[email protected]>
Signed-off-by: Michael Musenbrock <[email protected]>
Hi @eddumelendez , I need to answer why ComposePassthroughTest is passing with two aspects:
For example having the following yaml: services:
redis:
image: redis
ports:
- ${REDIS_PORT} And then running: Whereas running both commands without So, even with this yaml DockerComposePassthroughTest would pass, BUT not ComposePassthroughTest
For example having the following yaml: services:
redis:
image: redis
environment:
test=${REDIS_PORT} And running WITHOUT |
I have added two tests, as described above, the |
core/src/main/java/org/testcontainers/containers/ComposeContainer.java
Outdated
Show resolved
Hide resolved
core/src/main/java/org/testcontainers/containers/DockerComposeContainer.java
Outdated
Show resolved
Hide resolved
Thanks for your contribution and detailed explanation, @mmusenbr ! |
This fixes issues on stopping when ENV-Variables are used inside the compose file. Issue was introduced in 7112db5.
Fixes #8492