mirror of
https://github.com/GNS3/gns3-server.git
synced 2026-11-03 05:51:15 +02:00
Merge branch '1.5' into 2.0
This commit is contained in:
5 files changed
+27
-8
No files matched your search
@@ -24,6 +24,7 @@ import asyncio
|
||||
import logging
|
||||
import aiohttp
|
||||
import json
|
||||
import sys
|
||||
from gns3server.utils import parse_version
|
||||
|
||||
log = logging.getLogger(__name__)
|
||||
|
||||
@@ -623,7 +623,7 @@ class DockerVM(BaseNode):
|
||||
raise DockerError("Adapter {adapter_number} doesn't exist on Docker container '{name}'".format(name=self.name,
|
||||
adapter_number=adapter_number))
|
||||
|
||||
for index in range(128):
|
||||
for index in range(4096):
|
||||
if "veth-gns3-ext{}".format(index) not in psutil.net_if_addrs():
|
||||
adapter.ifc = "eth{}".format(str(index))
|
||||
adapter.host_ifc = "veth-gns3-ext{}".format(str(index))
|
||||
|
||||
@@ -529,7 +529,6 @@ class Project:
|
||||
"iou": "IOUDevice",
|
||||
"docker": "DockerVM"
|
||||
}
|
||||
|
||||
node_directory = os.path.join(self.path, "servers", "vm", "project-files")
|
||||
vm_server_use = False
|
||||
|
||||
@@ -539,11 +538,11 @@ class Project:
|
||||
os.makedirs(node_directory, exist_ok=True)
|
||||
shutil.move(module_directory, os.path.join(node_directory, module))
|
||||
|
||||
# Patch node to use the GNS3 VM
|
||||
for node in topology["topology"]["nodes"]:
|
||||
if node["type"] == vm_type:
|
||||
node["server_id"] = 2
|
||||
vm_server_use = True
|
||||
# Patch node to use the GNS3 VM
|
||||
for node in topology["topology"]["nodes"]:
|
||||
if node["type"] == vm_type:
|
||||
node["server_id"] = 2
|
||||
vm_server_use = True
|
||||
|
||||
# We use the GNS3 VM. We need to add the server to the list
|
||||
if vm_server_use:
|
||||
|
||||
Reference in new issue
Block a user