mirror of
https://github.com/CiscoDevNet/cml-community.git
synced 2025-10-22 23:32:01 +00:00
1061 lines
38 KiB
JSON
1061 lines
38 KiB
JSON
{
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"required": [
|
|
"id",
|
|
"boot",
|
|
"sim",
|
|
"general",
|
|
"configuration",
|
|
"device",
|
|
"ui"
|
|
],
|
|
"properties": {
|
|
"id": {
|
|
"$ref": "#/schemas/DefinitionID",
|
|
"description": "A symbolic name used to identify this node definition, such as `iosv` or `asav`."
|
|
},
|
|
"boot": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"required": [
|
|
"timeout"
|
|
],
|
|
"properties": {
|
|
"timeout": {
|
|
"type": "integer",
|
|
"maximum": 86400,
|
|
"description": "Timeout (seconds).",
|
|
"example": 60
|
|
},
|
|
"completed": {
|
|
"type": "array",
|
|
"minItems": 1,
|
|
"description": "A list of strings which should be matched to determine when the node is \"ready\".",
|
|
"example": null,
|
|
"items": {
|
|
"type": "string",
|
|
"maxLength": 128
|
|
}
|
|
},
|
|
"uses_regex": {
|
|
"type": "boolean",
|
|
"description": "Whether the strings in `completed` should be treated as regular expressions or not."
|
|
}
|
|
}
|
|
},
|
|
"sim": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"description": "Simulation parameters.",
|
|
"properties": {
|
|
"linux_native": {
|
|
"$ref": "#/schemas/LinuxNativeSimulation"
|
|
},
|
|
"parameters": {
|
|
"$ref": "#/schemas/NodeParameters"
|
|
}
|
|
},
|
|
"required": [
|
|
"linux_native"
|
|
]
|
|
},
|
|
"general": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"description": "General information for the node type.",
|
|
"required": [
|
|
"nature",
|
|
"read_only"
|
|
],
|
|
"properties": {
|
|
"description": {
|
|
"type": "string",
|
|
"maxLength": 4096,
|
|
"description": "A description of the node type."
|
|
},
|
|
"nature": {
|
|
"type": "string",
|
|
"description": "The \"nature\" / kind of the node type defined here.",
|
|
"enum": [
|
|
"router",
|
|
"switch",
|
|
"server",
|
|
"host",
|
|
"cloud",
|
|
"firewall",
|
|
"external_connector"
|
|
]
|
|
},
|
|
"read_only": {
|
|
"type": "boolean",
|
|
"description": "Whether the node definition can be deleted or not."
|
|
}
|
|
}
|
|
},
|
|
"configuration": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"required": [
|
|
"generator"
|
|
],
|
|
"properties": {
|
|
"generator": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"required": [
|
|
"driver"
|
|
],
|
|
"properties": {
|
|
"driver": {
|
|
"type": [
|
|
"null",
|
|
"string"
|
|
],
|
|
"description": "Configuration Driver.",
|
|
"enum": [
|
|
"asav",
|
|
"alpine",
|
|
"cat9000v",
|
|
"coreos",
|
|
"csr1000v",
|
|
"desktop",
|
|
"iosv",
|
|
"iosvl2",
|
|
"iosxrv",
|
|
"iosxrv9000",
|
|
"lxc",
|
|
"nxosv",
|
|
"nxosv9000",
|
|
"pagent",
|
|
"sdwan",
|
|
"sdwan_edge",
|
|
"sdwan_manager",
|
|
"server",
|
|
"trex",
|
|
"ubuntu",
|
|
"wan_emulator",
|
|
null
|
|
]
|
|
}
|
|
}
|
|
},
|
|
"provisioning": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"required": [
|
|
"files",
|
|
"media_type",
|
|
"volume_name"
|
|
],
|
|
"properties": {
|
|
"files": {
|
|
"type": "array",
|
|
"description": "List of node configuration file objects.",
|
|
"minItems": 1,
|
|
"items": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"required": [
|
|
"editable",
|
|
"name"
|
|
],
|
|
"properties": {
|
|
"content": {
|
|
"$ref": "#/schemas/NodeConfiguration"
|
|
},
|
|
"editable": {
|
|
"type": "boolean",
|
|
"description": "Is the configuration file editable?"
|
|
},
|
|
"name": {
|
|
"type": "string",
|
|
"minLength": 1,
|
|
"maxLength": 64,
|
|
"description": "The ame of the configuration file."
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"media_type": {
|
|
"type": "string",
|
|
"description": "The type of the configuration media.",
|
|
"enum": [
|
|
"iso",
|
|
"fat",
|
|
"ext4"
|
|
]
|
|
},
|
|
"volume_name": {
|
|
"type": "string",
|
|
"minLength": 1,
|
|
"maxLength": 32,
|
|
"description": "The volume name of the configuration media."
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"device": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"required": [
|
|
"interfaces"
|
|
],
|
|
"properties": {
|
|
"interfaces": {
|
|
"$ref": "#/schemas/Interfaces"
|
|
}
|
|
}
|
|
},
|
|
"ui": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"required": [
|
|
"icon",
|
|
"visible",
|
|
"label",
|
|
"label_prefix"
|
|
],
|
|
"properties": {
|
|
"visible": {
|
|
"type": "boolean",
|
|
"description": "Determines visibility in the UI for this node type."
|
|
},
|
|
"group": {
|
|
"type": "string",
|
|
"description": "Intended to group similar node types (unused).",
|
|
"enum": [
|
|
"Cisco",
|
|
"Others"
|
|
]
|
|
},
|
|
"description": {
|
|
"type": "string",
|
|
"maxLength": 4096,
|
|
"description": "The description of the node type (can be Markdown)."
|
|
},
|
|
"label_prefix": {
|
|
"type": "string",
|
|
"minLength": 1,
|
|
"maxLength": 32,
|
|
"description": "The textual prefix for node labels."
|
|
},
|
|
"icon": {
|
|
"type": "string",
|
|
"description": "The icon to use with this node type.",
|
|
"enum": [
|
|
"router",
|
|
"switch",
|
|
"server",
|
|
"host",
|
|
"cloud",
|
|
"firewall",
|
|
"access_point",
|
|
"wlc"
|
|
]
|
|
},
|
|
"label": {
|
|
"type": "string",
|
|
"minLength": 1,
|
|
"maxLength": 32,
|
|
"description": "The node label."
|
|
}
|
|
}
|
|
},
|
|
"inherited": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"required": [
|
|
"image",
|
|
"node"
|
|
],
|
|
"properties": {
|
|
"image": {
|
|
"$ref": "#/schemas/VMProperties"
|
|
},
|
|
"node": {
|
|
"$ref": "#/schemas/VMProperties"
|
|
}
|
|
}
|
|
},
|
|
"pyats": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"required": [
|
|
"os"
|
|
],
|
|
"properties": {
|
|
"os": {
|
|
"type": "string",
|
|
"minLength": 1,
|
|
"maxLength": 32,
|
|
"description": "The operating system as defined / understood by pyATS."
|
|
},
|
|
"series": {
|
|
"minLength": 1,
|
|
"maxLength": 32,
|
|
"type": "string",
|
|
"description": "The device series as defined by pyATS / Unicon."
|
|
},
|
|
"model": {
|
|
"minLength": 1,
|
|
"maxLength": 32,
|
|
"type": "string",
|
|
"description": "The device model as defined by pyATS / Unicon."
|
|
},
|
|
"use_in_testbed": {
|
|
"type": "boolean",
|
|
"description": "Use this device in an exported testbed?"
|
|
},
|
|
"username": {
|
|
"minLength": 1,
|
|
"maxLength": 64,
|
|
"type": [
|
|
"null",
|
|
"string"
|
|
],
|
|
"description": "Use this username with pyATS / Unicon when interacting with this node type."
|
|
},
|
|
"password": {
|
|
"minLength": 1,
|
|
"maxLength": 128,
|
|
"type": [
|
|
"null",
|
|
"string"
|
|
],
|
|
"description": "Use this password with pyATS / Unicon when interacting with this node type."
|
|
},
|
|
"config_extract_command": {
|
|
"maxLength": 4096,
|
|
"type": [
|
|
"null",
|
|
"string"
|
|
],
|
|
"description": "This is the CLI command to use when configurations should be extracted from a device of this node type."
|
|
}
|
|
}
|
|
},
|
|
"schema_version": {
|
|
"type": "string",
|
|
"minLength": 1,
|
|
"maxLength": 32,
|
|
"description": "The schema version used for this node type.",
|
|
"example": "0.0.1"
|
|
}
|
|
},
|
|
"schemas": {
|
|
"LinuxNativeSimulation": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"description": "Base for simulation objects.",
|
|
"required": [
|
|
"libvirt_domain_driver",
|
|
"driver"
|
|
],
|
|
"properties": {
|
|
"libvirt_domain_driver": {
|
|
"type": "string",
|
|
"description": "Domain Driver.",
|
|
"enum": [
|
|
"iol",
|
|
"kvm",
|
|
"lxc",
|
|
"none"
|
|
]
|
|
},
|
|
"driver": {
|
|
"type": "string",
|
|
"description": "Simulation Driver.",
|
|
"enum": [
|
|
"asav",
|
|
"alpine",
|
|
"cat9k",
|
|
"coreos",
|
|
"csr1000v",
|
|
"external_connector",
|
|
"iol",
|
|
"iol-l2",
|
|
"iosv",
|
|
"iosvl2",
|
|
"iosxrv",
|
|
"iosxrv9000",
|
|
"lxc",
|
|
"nxosv",
|
|
"nxosv9000",
|
|
"pagent",
|
|
"server",
|
|
"trex",
|
|
"ubuntu",
|
|
"unmanaged_switch",
|
|
"wan_emulator"
|
|
]
|
|
},
|
|
"disk_driver": {
|
|
"type": "string",
|
|
"description": "Disk Driver.",
|
|
"enum": [
|
|
"ide",
|
|
"sata",
|
|
"virtio"
|
|
]
|
|
},
|
|
"efi_boot": {
|
|
"type": "boolean",
|
|
"description": "If set, use EFI boot for the VM."
|
|
},
|
|
"efi_code": {
|
|
"$ref": "#/schemas/FilePath",
|
|
"description": "EFI code file path; if unset, use default."
|
|
},
|
|
"efi_vars": {
|
|
"$ref": "#/schemas/FilePath",
|
|
"description": "EFI var file path; if unset, use no variable file."
|
|
},
|
|
"machine_type": {
|
|
"type": "string",
|
|
"minLength": 1,
|
|
"maxLength": 32,
|
|
"description": "QEMU machine type, defaults to pc; q35 is more modern."
|
|
},
|
|
"ram": {
|
|
"type": "integer",
|
|
"minimum": 1,
|
|
"maximum": 1048576,
|
|
"description": "Memory in MB."
|
|
},
|
|
"cpus": {
|
|
"type": "integer",
|
|
"minimum": 1,
|
|
"maximum": 128,
|
|
"description": "CPUs."
|
|
},
|
|
"cpu_limit": {
|
|
"type": "integer",
|
|
"description": "CPU Limit.",
|
|
"minimum": 20,
|
|
"maximum": 100
|
|
},
|
|
"cpu_model": {
|
|
"type": "string",
|
|
"minLength": 1,
|
|
"maxLength": 64,
|
|
"pattern": "^[a-zA-Z\\d-]{1,32}(,[+!?^-][a-z\\d._]{1,16})*(?![\\n\\t])$"
|
|
},
|
|
"nic_driver": {
|
|
"type": "string",
|
|
"description": "Network Driver.",
|
|
"enum": [
|
|
"virtio",
|
|
"e1000",
|
|
"rtl8139",
|
|
"vmxnet3",
|
|
"e1000e",
|
|
"e1000-82544gc",
|
|
"e1000-82545em",
|
|
"i82550",
|
|
"i82551",
|
|
"i82557a",
|
|
"i82557b",
|
|
"i82557c",
|
|
"i82558a",
|
|
"i82558b",
|
|
"i82559a",
|
|
"i82559b",
|
|
"i82559c",
|
|
"i82559er",
|
|
"i82562",
|
|
"i82801"
|
|
]
|
|
},
|
|
"data_volume": {
|
|
"type": "integer",
|
|
"minimum": 0,
|
|
"maximum": 4096,
|
|
"description": "Data Disk Size in GiB."
|
|
},
|
|
"boot_disk_size": {
|
|
"type": "integer",
|
|
"minimum": 0,
|
|
"maximum": 4096,
|
|
"description": "Boot Disk Size in GiB."
|
|
},
|
|
"video": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"description": "If present, then VNC can be used with the node VM.",
|
|
"required": [
|
|
"memory"
|
|
],
|
|
"properties": {
|
|
"model": {
|
|
"type": "string",
|
|
"description": "Video Model.",
|
|
"enum": [
|
|
"cirrus",
|
|
"qxl",
|
|
"xen",
|
|
"virtio",
|
|
"none",
|
|
"vga",
|
|
"vmvga"
|
|
]
|
|
},
|
|
"memory": {
|
|
"type": "integer",
|
|
"minimum": 1,
|
|
"maximum": 128,
|
|
"description": "Video Memory."
|
|
}
|
|
}
|
|
},
|
|
"enable_rng": {
|
|
"type": "boolean",
|
|
"description": "If set, use a random number generator."
|
|
},
|
|
"enable_tpm": {
|
|
"type": "boolean",
|
|
"description": "If set, enable an emulated TPM 2.0."
|
|
}
|
|
},
|
|
"oneOf": [
|
|
{
|
|
"properties": {
|
|
"libvirt_domain_driver": {
|
|
"enum": [
|
|
"kvm",
|
|
"docker",
|
|
"iol",
|
|
"lxc",
|
|
"none"
|
|
]
|
|
}
|
|
},
|
|
"required": [
|
|
"cpus",
|
|
"ram",
|
|
"nic_driver",
|
|
"disk_driver"
|
|
]
|
|
},
|
|
{
|
|
"properties": {
|
|
"libvirt_domain_driver": {
|
|
"enum": [
|
|
"lxc"
|
|
]
|
|
}
|
|
},
|
|
"required": [
|
|
"ram"
|
|
]
|
|
},
|
|
{
|
|
"properties": {
|
|
"libvirt_domain_driver": {
|
|
"enum": [
|
|
"none"
|
|
]
|
|
}
|
|
}
|
|
}
|
|
]
|
|
},
|
|
"NodeParameters": {
|
|
"type": "object",
|
|
"additionalProperties": {
|
|
"type": "string",
|
|
"nullable": true
|
|
},
|
|
"description": "Key-value pairs of custom node SMBIOS parameters.",
|
|
"example": {"smbios.bios.vendor": "Lenovo"}
|
|
},
|
|
"Interfaces": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"required": [
|
|
"serial_ports",
|
|
"physical",
|
|
"has_loopback_zero"
|
|
],
|
|
"properties": {
|
|
"has_loopback_zero": {
|
|
"type": "boolean",
|
|
"description": "Has `loopback0` interface (used with ANK)."
|
|
},
|
|
"serial_ports": {
|
|
"type": "integer",
|
|
"minimum": 0,
|
|
"maximum": 64,
|
|
"description": "Number of serial Ports."
|
|
},
|
|
"default_count": {
|
|
"type": "integer",
|
|
"minimum": 1,
|
|
"maximum": 64,
|
|
"description": "Default number of physical interfaces."
|
|
},
|
|
"min_count": {
|
|
"type": "integer",
|
|
"minimum": 1,
|
|
"maximum": 64,
|
|
"description": "Minimal number of physical interfaces."
|
|
},
|
|
"loopback": {
|
|
"type": "array",
|
|
"description": "List of loopback interfaces.",
|
|
"minItems": 1,
|
|
"items": {
|
|
"type": "string",
|
|
"minLength": 1,
|
|
"maxLength": 32
|
|
}
|
|
},
|
|
"management": {
|
|
"type": "array",
|
|
"description": "List of management interfaces.",
|
|
"minItems": 1,
|
|
"items": {
|
|
"type": "string",
|
|
"minLength": 1,
|
|
"maxLength": 32
|
|
}
|
|
},
|
|
"physical": {
|
|
"type": "array",
|
|
"description": "List of physical interfaces.",
|
|
"minItems": 1,
|
|
"items": {
|
|
"type": "string",
|
|
"minLength": 1,
|
|
"maxLength": 32
|
|
}
|
|
}
|
|
},
|
|
"oneOf": [
|
|
{
|
|
"properties": {
|
|
"has_loopback_zero": {
|
|
"enum": [
|
|
true
|
|
]
|
|
}
|
|
},
|
|
"required": [
|
|
"loopback"
|
|
]
|
|
},
|
|
{
|
|
"properties": {
|
|
"has_loopback_zero": {
|
|
"enum": [
|
|
false
|
|
]
|
|
}
|
|
}
|
|
}
|
|
]
|
|
},
|
|
"VMProperties": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"description": "Virtual Machine properties.",
|
|
"required": [
|
|
"ram",
|
|
"cpus",
|
|
"data_volume",
|
|
"boot_disk_size"
|
|
],
|
|
"properties": {
|
|
"ram": {
|
|
"type": "boolean",
|
|
"description": "RAM."
|
|
},
|
|
"cpus": {
|
|
"type": "boolean",
|
|
"description": "CPU Count."
|
|
},
|
|
"cpu_limit": {
|
|
"type": "boolean",
|
|
"description": "CPU Limit."
|
|
},
|
|
"data_volume": {
|
|
"type": "boolean",
|
|
"description": "Data Disk Size."
|
|
},
|
|
"boot_disk_size": {
|
|
"type": "boolean",
|
|
"description": "Boot Disk Size."
|
|
}
|
|
}
|
|
},
|
|
"NodeDefinition": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"required": [
|
|
"id",
|
|
"boot",
|
|
"sim",
|
|
"general",
|
|
"configuration",
|
|
"device",
|
|
"ui"
|
|
],
|
|
"properties": {
|
|
"id": {
|
|
"$ref": "#/schemas/DefinitionID",
|
|
"description": "A symbolic name used to identify this node definition, such as `iosv` or `asav`."
|
|
},
|
|
"boot": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"required": [
|
|
"timeout"
|
|
],
|
|
"properties": {
|
|
"timeout": {
|
|
"type": "integer",
|
|
"maximum": 86400,
|
|
"description": "Timeout (seconds).",
|
|
"example": 60
|
|
},
|
|
"completed": {
|
|
"type": "array",
|
|
"minItems": 1,
|
|
"description": "A list of strings which should be matched to determine when the node is \"ready\".",
|
|
"example": null,
|
|
"items": {
|
|
"type": "string",
|
|
"maxLength": 128
|
|
}
|
|
},
|
|
"uses_regex": {
|
|
"type": "boolean",
|
|
"description": "Whether the strings in `completed` should be treated as regular expressions or not."
|
|
}
|
|
}
|
|
},
|
|
"sim": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"description": "Simulation parameters.",
|
|
"properties": {
|
|
"linux_native": {
|
|
"$ref": "#/schemas/LinuxNativeSimulation"
|
|
}
|
|
},
|
|
"required": [
|
|
"linux_native"
|
|
]
|
|
},
|
|
"general": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"description": "General information for the node type.",
|
|
"required": [
|
|
"nature",
|
|
"read_only"
|
|
],
|
|
"properties": {
|
|
"description": {
|
|
"type": "string",
|
|
"maxLength": 4096,
|
|
"description": "A description of the node type."
|
|
},
|
|
"nature": {
|
|
"type": "string",
|
|
"description": "The \"nature\" / kind of the node type defined here.",
|
|
"enum": [
|
|
"router",
|
|
"switch",
|
|
"server",
|
|
"host",
|
|
"cloud",
|
|
"firewall",
|
|
"external_connector"
|
|
]
|
|
},
|
|
"read_only": {
|
|
"type": "boolean",
|
|
"description": "Whether the node definition can be deleted or not."
|
|
}
|
|
}
|
|
},
|
|
"configuration": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"required": [
|
|
"generator"
|
|
],
|
|
"properties": {
|
|
"generator": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"required": [
|
|
"driver"
|
|
],
|
|
"properties": {
|
|
"driver": {
|
|
"type": [
|
|
"null",
|
|
"string"
|
|
],
|
|
"description": "Configuration Driver.",
|
|
"enum": [
|
|
"asav",
|
|
"alpine",
|
|
"cat9k",
|
|
"coreos",
|
|
"csr1000v",
|
|
"desktop",
|
|
"iol",
|
|
"iol-l2",
|
|
"iosv",
|
|
"iosvl2",
|
|
"iosxrv",
|
|
"iosxrv9000",
|
|
"lxc",
|
|
"nxosv",
|
|
"nxosv9000",
|
|
"pagent",
|
|
"server",
|
|
"trex",
|
|
"ubuntu",
|
|
"wan_emulator"
|
|
]
|
|
}
|
|
}
|
|
},
|
|
"provisioning": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"required": [
|
|
"files",
|
|
"media_type",
|
|
"volume_name"
|
|
],
|
|
"properties": {
|
|
"files": {
|
|
"type": "array",
|
|
"description": "List of node configuration file objects.",
|
|
"minItems": 1,
|
|
"items": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"required": [
|
|
"editable",
|
|
"name"
|
|
],
|
|
"properties": {
|
|
"content": {
|
|
"$ref": "#/schemas/NodeConfiguration"
|
|
},
|
|
"editable": {
|
|
"type": "boolean",
|
|
"description": "Is the configuration file editable?"
|
|
},
|
|
"name": {
|
|
"type": "string",
|
|
"minLength": 1,
|
|
"maxLength": 64,
|
|
"description": "The ame of the configuration file."
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"media_type": {
|
|
"type": "string",
|
|
"description": "The type of the configuration media.",
|
|
"enum": [
|
|
"iso",
|
|
"fat",
|
|
"raw",
|
|
"ext4"
|
|
]
|
|
},
|
|
"volume_name": {
|
|
"type": "string",
|
|
"minLength": 1,
|
|
"maxLength": 32,
|
|
"description": "The volume name of the configuration media."
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"device": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"required": [
|
|
"interfaces"
|
|
],
|
|
"properties": {
|
|
"interfaces": {
|
|
"$ref": "#/schemas/Interfaces"
|
|
}
|
|
}
|
|
},
|
|
"ui": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"required": [
|
|
"icon",
|
|
"visible",
|
|
"label",
|
|
"label_prefix"
|
|
],
|
|
"properties": {
|
|
"visible": {
|
|
"type": "boolean",
|
|
"description": "Determines visibility in the UI for this node type."
|
|
},
|
|
"group": {
|
|
"type": "string",
|
|
"description": "Intended to group similar node types (unused).",
|
|
"enum": [
|
|
"Cisco",
|
|
"Others"
|
|
]
|
|
},
|
|
"description": {
|
|
"type": "string",
|
|
"maxLength": 4096,
|
|
"description": "The description of the node type (can be Markdown)."
|
|
},
|
|
"label_prefix": {
|
|
"type": "string",
|
|
"minLength": 1,
|
|
"maxLength": 32,
|
|
"description": "The textual prefix for node labels."
|
|
},
|
|
"icon": {
|
|
"type": "string",
|
|
"description": "The icon to use with this node type.",
|
|
"enum": [
|
|
"router",
|
|
"switch",
|
|
"server",
|
|
"host",
|
|
"cloud",
|
|
"firewall",
|
|
"access_point",
|
|
"wl"
|
|
]
|
|
},
|
|
"label": {
|
|
"type": "string",
|
|
"minLength": 1,
|
|
"maxLength": 32,
|
|
"description": "The node label."
|
|
}
|
|
}
|
|
},
|
|
"inherited": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"required": [
|
|
"image",
|
|
"node"
|
|
],
|
|
"properties": {
|
|
"image": {
|
|
"$ref": "#/schemas/VMProperties"
|
|
},
|
|
"node": {
|
|
"$ref": "#/schemas/VMProperties"
|
|
}
|
|
}
|
|
},
|
|
"pyats": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"required": [
|
|
"os"
|
|
],
|
|
"properties": {
|
|
"os": {
|
|
"type": "string",
|
|
"minLength": 1,
|
|
"maxLength": 32,
|
|
"description": "The operating system as defined / understood by pyATS."
|
|
},
|
|
"series": {
|
|
"minLength": 1,
|
|
"maxLength": 32,
|
|
"type": "string",
|
|
"description": "The device series as defined by pyATS / Unicon."
|
|
},
|
|
"model": {
|
|
"minLength": 1,
|
|
"maxLength": 32,
|
|
"type": "string",
|
|
"description": "The device model as defined by pyATS / Unicon."
|
|
},
|
|
"use_in_testbed": {
|
|
"type": "boolean",
|
|
"description": "Use this device in an exported testbed?"
|
|
},
|
|
"username": {
|
|
"minLength": 1,
|
|
"maxLength": 64,
|
|
"type": [
|
|
"null",
|
|
"string"
|
|
],
|
|
"description": "Use this username with pyATS / Unicon when interacting with this node type."
|
|
},
|
|
"password": {
|
|
"minLength": 1,
|
|
"maxLength": 128,
|
|
"type": [
|
|
"null",
|
|
"string"
|
|
],
|
|
"description": "Use this password with pyATS / Unicon when interacting with this node type."
|
|
},
|
|
"config_extract_command": {
|
|
"maxLength": 4096,
|
|
"type": [
|
|
"null",
|
|
"string"
|
|
],
|
|
"description": "This is the CLI command to use when configurations should be extracted from a device of this node type."
|
|
}
|
|
}
|
|
},
|
|
"schema_version": {
|
|
"type": "string",
|
|
"minLength": 1,
|
|
"maxLength": 32,
|
|
"description": "The schema version used for this node type.",
|
|
"example": "0.0.1"
|
|
}
|
|
}
|
|
},
|
|
"NodeDefinitionList": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/schemas/NodeDefinition"
|
|
}
|
|
},
|
|
"FilePath": {
|
|
"type": "string",
|
|
"minLength": 1,
|
|
"maxLength": 255,
|
|
"pattern": "^(?![.])[^!@#%^&*();$\\n\\r\\t)/\\\\]{1,255}(?![\\n\\t])$"
|
|
},
|
|
"DefinitionID": {
|
|
"type": "string",
|
|
"description": "Name of the node or image definition (max 250 UTF-8 bytes).",
|
|
"minLength": 1,
|
|
"maxLength": 250,
|
|
"pattern": "^(?![.])[^!@#%^&*();$\\n\\r\\t)/\\\\]{1,250}(?![\\n\\t])$",
|
|
"example": "server"
|
|
},
|
|
"NodeConfiguration": {
|
|
"type": "string",
|
|
"description": "Node configuration (no more than 20MB)."
|
|
}
|
|
}
|
|
}
|