30
30
create_api_error_from_http_exception
31
31
)
32
32
from ..tls import TLSConfig
33
- from ..transport import SSLAdapter , UnixAdapter
33
+ from ..transport import SSLHTTPAdapter , UnixHTTPAdapter
34
34
from ..utils import utils , check_resource , update_headers , config
35
35
from ..utils .socket import frames_iter , consume_socket_output , demux_adaptor
36
36
from ..utils .json_stream import json_stream
37
37
from ..utils .proxy import ProxyConfig
38
38
try :
39
- from ..transport import NpipeAdapter
39
+ from ..transport import NpipeHTTPAdapter
40
40
except ImportError :
41
41
pass
42
42
43
43
try :
44
- from ..transport import SSHAdapter
44
+ from ..transport import SSHHTTPAdapter
45
45
except ImportError :
46
46
pass
47
47
@@ -137,7 +137,7 @@ def __init__(self, base_url=None, version=None,
137
137
base_url .startswith ('ssh://' ) else DEFAULT_NUM_POOLS
138
138
139
139
if base_url .startswith ('http+unix://' ):
140
- self ._custom_adapter = UnixAdapter (
140
+ self ._custom_adapter = UnixHTTPAdapter (
141
141
base_url , timeout , pool_connections = num_pools
142
142
)
143
143
self .mount ('http+docker://' , self ._custom_adapter )
@@ -151,7 +151,7 @@ def __init__(self, base_url=None, version=None,
151
151
'The npipe:// protocol is only supported on Windows'
152
152
)
153
153
try :
154
- self ._custom_adapter = NpipeAdapter (
154
+ self ._custom_adapter = NpipeHTTPAdapter (
155
155
base_url , timeout , pool_connections = num_pools
156
156
)
157
157
except NameError :
@@ -162,7 +162,7 @@ def __init__(self, base_url=None, version=None,
162
162
self .base_url = 'http+docker://localnpipe'
163
163
elif base_url .startswith ('ssh://' ):
164
164
try :
165
- self ._custom_adapter = SSHAdapter (
165
+ self ._custom_adapter = SSHHTTPAdapter (
166
166
base_url , timeout , pool_connections = num_pools
167
167
)
168
168
except NameError :
@@ -177,7 +177,8 @@ def __init__(self, base_url=None, version=None,
177
177
if isinstance (tls , TLSConfig ):
178
178
tls .configure_client (self )
179
179
elif tls :
180
- self ._custom_adapter = SSLAdapter (pool_connections = num_pools )
180
+ self ._custom_adapter = SSLHTTPAdapter (
181
+ pool_connections = num_pools )
181
182
self .mount ('https://' , self ._custom_adapter )
182
183
self .base_url = base_url
183
184
0 commit comments