1
0
mirror of https://github.com/docker/docs.git synced 2026-10-31 10:34:26 +03:00

Display unpublished ports in 'fig ps'

This commit is contained in:
Aanand Prasad
2014-03-04 18:00:46 +00:00
parent 2d98071e55
commit 5f5fbb3ea4

View File

@@ -70,6 +70,8 @@ class Container(object):
for private, public in list(self.dictionary['NetworkSettings']['Ports'].items()):
if public:
ports.append('%s->%s' % (public[0]['HostPort'], private))
else:
ports.append(private)
return ', '.join(ports)
@property