Skip to content

Commit 0a4da83

Browse files
fallback to gateway address (#96)
Co-authored-by: Till Hoffmann <[email protected]>
1 parent 1c3d537 commit 0a4da83

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

testcontainers/core/container.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,7 @@ def get_container_host_ip(self) -> str:
9393

9494
if gateway_ip == host:
9595
return self.get_docker_client().bridge_ip(self._container.id)
96+
return gateway_ip
9697
return host
9798

9899
def get_exposed_port(self, port) -> str:

0 commit comments

Comments
 (0)