Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
D
docker-py
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
docker-py
Commits
abd5370d
Kaydet (Commit)
abd5370d
authored
Nis 07, 2017
tarafından
Santhosh Manohar
Kaydeden (comit)
Joffrey F
Nis 10, 2017
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Add 'verbose' option for network inspect api
Signed-off-by:
Santhosh Manohar
<
santhosh@docker.com
>
üst
ffc37699
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
2 deletions
+11
-2
network.py
docker/api/network.py
+11
-2
No files found.
docker/api/network.py
Dosyayı görüntüle @
abd5370d
...
...
@@ -168,14 +168,23 @@ class NetworkApiMixin(object):
self
.
_raise_for_status
(
res
)
@minimum_version
(
'1.21'
)
def
inspect_network
(
self
,
net_id
):
def
inspect_network
(
self
,
net_id
,
verbose
=
False
):
"""
Get detailed information about a network.
Args:
net_id (str): ID of network
verbose (bool): If set shows the service details across the cluster
in swarm mode
"""
url
=
self
.
_url
(
"/networks/{0}"
,
net_id
)
if
verbose
is
True
:
if
version_lt
(
self
.
_version
,
'1.28'
):
raise
InvalidVersion
(
'Verbose option was introduced in API 1.28'
)
url
=
self
.
_url
(
"/networks/{0}?verbose=true"
,
net_id
)
else
:
url
=
self
.
_url
(
"/networks/{0}"
,
net_id
)
res
=
self
.
_get
(
url
)
return
self
.
_result
(
res
,
json
=
True
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment