fix: docker ports — replace 0.0.0.0 with * (standard docker ps notation)
This commit is contained in:
parent
175d3dfd90
commit
f07e4be94c
1 changed files with 3 additions and 2 deletions
|
|
@ -63,8 +63,9 @@ const getHealthColor = (health: string) => {
|
|||
const formatPorts = (ports: any[]): string => {
|
||||
if (!ports || ports.length === 0) return '—';
|
||||
return ports.map(p => {
|
||||
const host = p.host_port ? `:${p.host_port}` : '';
|
||||
return `${p.container_port}${host}/${p.protocol}`;
|
||||
const host = p.host_ip === '0.0.0.0' ? '*' : (p.host_ip || '');
|
||||
const port = host ? `${host}:${p.container_port}` : `${p.container_port}`;
|
||||
return `${port}/${p.protocol}`;
|
||||
}).join(', ');
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue