mirror of
https://github.com/docker-mailserver/docker-mailserver.git
synced 2026-05-14 00:36:17 +02:00
tests: fix _get_container_ip for docker 29.0 (#4606)
This commit is contained in:
parent
b410e56aa9
commit
5865f546ec
@ -10,6 +10,8 @@ All notable changes to this project will be documented in this file. The format
|
||||
|
||||
- **Internal:**
|
||||
- `ENABLE_QUOTAS=1` - When an alias has multiple addresses, the first local mailbox address found will be used for the Dovecot dummy account workaround ([#4581](https://github.com/docker-mailserver/docker-mailserver/pull/4581))
|
||||
- **Tests:**
|
||||
- Make the helper method `_get_container_ip()` compatible with Docker 29 ([#4606](https://github.com/docker-mailserver/docker-mailserver/pull/4606))
|
||||
|
||||
### Removed
|
||||
|
||||
|
||||
@ -364,11 +364,12 @@ function _reload_postfix() {
|
||||
}
|
||||
|
||||
# Get the IP of the container (${1}).
|
||||
# This uses the "bridge" network IPAddress and doesn't consider other docker networks.
|
||||
#
|
||||
# @param ${1} = container name [OPTIONAL]
|
||||
function _get_container_ip() {
|
||||
local TARGET_CONTAINER_NAME=$(__handle_container_name "${1:-}")
|
||||
docker inspect --format '{{ .NetworkSettings.IPAddress }}' "${TARGET_CONTAINER_NAME}"
|
||||
docker inspect --format '{{ .NetworkSettings.Networks.bridge.IPAddress }}' "${TARGET_CONTAINER_NAME}"
|
||||
}
|
||||
|
||||
# Check if a container is running.
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user