#512: only use --net when bridge

This commit is contained in:
Muayyad alsadi 2022-06-29 11:55:39 +03:00
parent 265e0ca32a
commit f674ab8cfb

View File

@ -757,12 +757,12 @@ def get_net_args(compose, cnt):
other_cnt = net.split(":", 1)[1].strip()
net_args.extend(["--network", f"container:{other_cnt}"])
elif net.startswith("bridge"):
is_bridge=True
is_bridge = True
else:
print(f"unknown network_mode [{net}]")
sys.exit(1)
else:
is_bridge=True
is_bridge = True
proj_name = compose.project_name
default_net = compose.default_net
nets = compose.networks