mirror of
https://github.com/GNS3/gns3-server.git
synced 2026-11-05 14:51:13 +02:00
appliance: close the v8 gaps for Docker vendor appliances
DockerPropertiesV8 now accepts custom_adapters (already available to v1-6 top-level appliances and to Qemu v8 properties), so port-named Docker appliances (XRd, SR Linux) can move to the v8 format without losing their interface naming. Appliance.type resolves the node type from the v8 settings template_type (default set first) instead of misclassifying every v8 appliance as qemu, and _get_default_symbol applies the docker guest symbol to v8 Docker guest appliances.
This commit is contained in:
4 files changed
+149
-1
No files matched your search
@@ -362,7 +362,14 @@ class ApplianceManager:
|
||||
symbol_theme = controller.symbols.theme
|
||||
category = appliance["category"]
|
||||
if category == "guest":
|
||||
if "docker" in appliance:
|
||||
if appliance.get("registry_version", 0) >= 8:
|
||||
# registry version 8: look for a Docker settings set instead of a top-level block
|
||||
settings_types = [
|
||||
settings.get("template_type") for settings in appliance.get("settings") or []
|
||||
]
|
||||
if "docker" in settings_types:
|
||||
return controller.symbols.get_default_symbol("docker_guest", symbol_theme)
|
||||
elif "docker" in appliance:
|
||||
return controller.symbols.get_default_symbol("docker_guest", symbol_theme)
|
||||
elif "qemu" in appliance:
|
||||
return controller.symbols.get_default_symbol("qemu_guest", symbol_theme)
|
||||
|
||||
Reference in new issue
Block a user