Skip to content

Commit 3d79ce8

Browse files
authored
Merge pull request #3231 from vvoland/engine-25
Bump default API version to 1.44 (Moby 25.0)
2 parents bd164f9 + dd82f9a commit 3d79ce8

File tree

4 files changed

+15
-11
lines changed

4 files changed

+15
-11
lines changed

Makefile

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
TEST_API_VERSION ?= 1.43
2-
TEST_ENGINE_VERSION ?= 24.0
1+
TEST_API_VERSION ?= 1.44
2+
TEST_ENGINE_VERSION ?= 25.0
33

44
ifeq ($(OS),Windows_NT)
55
PLATFORM := Windows

docker/constants.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
import sys
22
from .version import __version__
33

4-
DEFAULT_DOCKER_API_VERSION = '1.43'
5-
MINIMUM_DOCKER_API_VERSION = '1.21'
4+
DEFAULT_DOCKER_API_VERSION = '1.44'
5+
MINIMUM_DOCKER_API_VERSION = '1.24'
66
DEFAULT_TIMEOUT_SECONDS = 60
77
STREAM_HEADER_SIZE_BYTES = 8
88
CONTAINER_LIMITS_KEYS = [

tests/Dockerfile-ssh-dind

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# syntax=docker/dockerfile:1
22

3-
ARG API_VERSION=1.43
4-
ARG ENGINE_VERSION=24.0
3+
ARG API_VERSION=1.44
4+
ARG ENGINE_VERSION=25.0
55

66
FROM docker:${ENGINE_VERSION}-dind
77

tests/integration/models_containers_test.py

+9-5
Original file line numberDiff line numberDiff line change
@@ -110,12 +110,12 @@ def test_run_with_networking_config(self):
110110
client.networks.create(net_name)
111111
self.tmp_networks.append(net_name)
112112

113-
test_aliases = ['hello']
113+
test_alias = 'hello'
114114
test_driver_opt = {'key1': 'a'}
115115

116116
networking_config = {
117117
net_name: client.api.create_endpoint_config(
118-
aliases=test_aliases,
118+
aliases=[test_alias],
119119
driver_opt=test_driver_opt
120120
)
121121
}
@@ -132,8 +132,10 @@ def test_run_with_networking_config(self):
132132
assert 'NetworkSettings' in attrs
133133
assert 'Networks' in attrs['NetworkSettings']
134134
assert list(attrs['NetworkSettings']['Networks'].keys()) == [net_name]
135-
assert attrs['NetworkSettings']['Networks'][net_name]['Aliases'] == \
136-
test_aliases
135+
# Expect Aliases to list 'test_alias' and the container's short-id.
136+
# In API version 1.45, the short-id will be removed.
137+
assert attrs['NetworkSettings']['Networks'][net_name]['Aliases'] \
138+
== [test_alias, attrs['Id'][:12]]
137139
assert attrs['NetworkSettings']['Networks'][net_name]['DriverOpts'] \
138140
== test_driver_opt
139141

@@ -190,7 +192,9 @@ def test_run_with_networking_config_only_undeclared_network(self):
190192
assert 'NetworkSettings' in attrs
191193
assert 'Networks' in attrs['NetworkSettings']
192194
assert list(attrs['NetworkSettings']['Networks'].keys()) == [net_name]
193-
assert attrs['NetworkSettings']['Networks'][net_name]['Aliases'] is None
195+
# Aliases should include the container's short-id (but it will be removed
196+
# in API v1.45).
197+
assert attrs['NetworkSettings']['Networks'][net_name]['Aliases'] == [attrs["Id"][:12]]
194198
assert (attrs['NetworkSettings']['Networks'][net_name]['DriverOpts']
195199
is None)
196200

0 commit comments

Comments
 (0)