1
0
mirror of https://github.com/GNS3/gns3-server synced 2024-12-27 09:18:09 +00:00
gns3-server/docs/gns3_file.json

447 lines
20 KiB
JSON
Raw Normal View History

2016-07-11 13:37:57 +00:00
{
2016-08-15 15:39:08 +00:00
"additionalProperties": false,
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "object",
"required": [
"project_id",
"type",
"revision",
"version",
"name",
"topology"
],
2016-07-11 13:37:57 +00:00
"properties": {
2016-07-14 13:31:49 +00:00
"topology": {
2016-08-15 15:39:08 +00:00
"required": [
"nodes",
"links",
"drawings",
"computes"
],
2016-07-11 13:37:57 +00:00
"properties": {
2016-08-15 15:39:08 +00:00
"computes": {
2016-07-11 13:37:57 +00:00
"items": {
2016-08-15 15:39:08 +00:00
"additionalProperties": false,
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "object",
"required": [
"compute_id",
"protocol",
"host",
"port",
"name"
],
2016-07-11 13:37:57 +00:00
"properties": {
2016-08-15 15:39:08 +00:00
"protocol": {
2016-08-15 10:08:59 +00:00
"enum": [
2016-08-15 15:39:08 +00:00
"http",
"https"
2016-07-14 13:31:49 +00:00
],
2016-08-15 15:39:08 +00:00
"description": "Server protocol"
2016-08-15 10:08:59 +00:00
},
2016-08-15 15:39:08 +00:00
"port": {
"description": "Server port",
"type": "integer"
2016-08-15 10:08:59 +00:00
},
"compute_id": {
2016-08-15 15:39:08 +00:00
"description": "Server identifier",
"type": "string"
2016-07-22 11:54:57 +00:00
},
2016-08-15 15:39:08 +00:00
"memory_usage_percent": {
"minimum": 0,
"maximum": 100,
"description": "RAM usage of the compute. Read only",
"type": [
"number",
"null"
]
2016-07-22 11:54:57 +00:00
},
2016-08-15 15:39:08 +00:00
"connected": {
"description": "Whether the controller is connected to the compute server or not",
"type": "boolean"
2016-08-15 10:08:59 +00:00
},
"name": {
2016-08-15 15:39:08 +00:00
"description": "Server name",
"type": "string"
2016-08-15 10:08:59 +00:00
},
2016-08-15 15:39:08 +00:00
"version": {
"description": "Version of the GNS3 remote compute server",
2016-08-15 10:08:59 +00:00
"type": [
2016-08-15 15:39:08 +00:00
"string",
"null"
]
2016-07-22 11:54:57 +00:00
},
2016-08-15 15:39:08 +00:00
"user": {
"description": "User for authentication",
"type": [
"string",
"null"
2016-07-22 11:54:57 +00:00
]
},
2016-08-15 15:39:08 +00:00
"cpu_usage_percent": {
"minimum": 0,
"maximum": 100,
"description": "CPU usage of the compute. Read only",
"type": [
"number",
"null"
]
2016-07-11 13:37:57 +00:00
},
2016-08-15 15:39:08 +00:00
"host": {
"description": "Server host",
"type": "string"
2016-08-15 10:08:59 +00:00
}
},
2016-08-15 15:39:08 +00:00
"description": "Request validation to a GNS3 compute object instance"
2016-08-15 10:08:59 +00:00
},
2016-08-15 15:39:08 +00:00
"description": "Computes servers",
"type": "array"
2016-08-15 10:08:59 +00:00
},
2016-08-15 15:39:08 +00:00
"links": {
2016-08-15 10:08:59 +00:00
"items": {
"additionalProperties": false,
"$schema": "http://json-schema.org/draft-04/schema#",
2016-08-15 15:39:08 +00:00
"type": "object",
"required": [
"nodes"
],
2016-07-22 11:54:57 +00:00
"properties": {
2016-08-15 15:39:08 +00:00
"capture_file_name": {
"description": "Read only property. The name of the capture file if capture is running",
"type": [
"string",
"null"
]
},
"capturing": {
"description": "Read only property. True if a capture running on the link",
"type": "boolean"
},
2016-07-11 13:37:57 +00:00
"nodes": {
"items": {
2016-08-15 15:39:08 +00:00
"required": [
"node_id",
"adapter_number",
"port_number"
],
2016-07-11 13:37:57 +00:00
"properties": {
2016-08-15 10:08:59 +00:00
"adapter_number": {
2016-08-15 15:39:08 +00:00
"description": "Adapter number",
"type": "integer"
2016-08-15 10:08:59 +00:00
},
"node_id": {
2016-08-15 15:39:08 +00:00
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$",
2016-08-15 10:08:59 +00:00
"maxLength": 36,
"minLength": 36,
"description": "Node UUID",
2016-08-15 15:39:08 +00:00
"type": "string"
2016-08-15 10:08:59 +00:00
},
2016-07-11 13:37:57 +00:00
"label": {
2016-08-15 15:39:08 +00:00
"required": [
"text",
"x",
"y"
],
2016-07-11 13:37:57 +00:00
"properties": {
2016-07-14 13:31:49 +00:00
"text": {
2016-07-11 13:37:57 +00:00
"type": "string"
},
2016-08-15 15:39:08 +00:00
"x": {
"description": "Relative X position of the label",
"type": "integer"
2016-08-15 10:08:59 +00:00
},
"y": {
2016-08-15 15:39:08 +00:00
"description": "Relative Y position of the label",
"type": "integer"
2016-07-11 13:37:57 +00:00
},
2016-08-15 15:39:08 +00:00
"rotation": {
"description": "Rotation of the label",
"type": "integer"
2016-07-26 17:57:53 +00:00
},
2016-08-15 15:39:08 +00:00
"style": {
"description": "SVG style attribute",
"type": "string"
2016-07-11 13:37:57 +00:00
}
2016-07-14 13:31:49 +00:00
},
2016-07-22 11:54:57 +00:00
"additionalProperties": false,
2016-08-15 15:39:08 +00:00
"type": "object"
},
"port_number": {
"description": "Port number",
"type": "integer"
2016-07-11 13:37:57 +00:00
}
2016-07-14 13:31:49 +00:00
},
2016-07-22 11:54:57 +00:00
"additionalProperties": false,
2016-08-15 15:39:08 +00:00
"type": "object"
2016-08-15 10:08:59 +00:00
},
2016-08-15 15:39:08 +00:00
"description": "List of the VMS",
"type": "array"
2016-07-11 13:37:57 +00:00
},
2016-08-15 10:08:59 +00:00
"capture_file_path": {
2016-08-15 15:39:08 +00:00
"description": "Read only property. The full path of the capture file if capture is running",
2016-08-15 10:08:59 +00:00
"type": [
"string",
"null"
2016-08-15 15:39:08 +00:00
]
2016-08-15 10:08:59 +00:00
},
2016-07-22 11:54:57 +00:00
"link_id": {
2016-08-15 15:39:08 +00:00
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$",
2016-08-15 10:08:59 +00:00
"maxLength": 36,
"minLength": 36,
2016-07-22 11:54:57 +00:00
"description": "Link UUID",
2016-08-15 15:39:08 +00:00
"type": "string"
2016-08-15 10:08:59 +00:00
},
2016-08-15 15:39:08 +00:00
"project_id": {
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$",
"maxLength": 36,
"minLength": 36,
"description": "Project UUID",
"type": "string"
2016-07-26 17:57:53 +00:00
}
},
2016-08-15 10:08:59 +00:00
"description": "A link object"
},
2016-08-15 15:39:08 +00:00
"description": "Link elements",
"type": "array"
2016-08-15 10:08:59 +00:00
},
2016-08-15 15:39:08 +00:00
"drawings": {
2016-08-15 10:08:59 +00:00
"items": {
2016-08-15 15:39:08 +00:00
"additionalProperties": false,
2016-07-26 17:57:53 +00:00
"properties": {
2016-08-15 15:39:08 +00:00
"svg": {
"description": "SVG content of the drawing",
"type": "string"
2016-08-15 10:08:59 +00:00
},
2016-08-15 15:39:08 +00:00
"project_id": {
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$",
"maxLength": 36,
"minLength": 36,
"description": "Project UUID",
"type": "string"
2016-08-15 10:08:59 +00:00
},
2016-08-15 15:39:08 +00:00
"rotation": {
"minimum": 0,
"maximum": 360,
"description": "Rotation of the element",
"type": "integer"
2016-08-15 10:08:59 +00:00
},
2016-08-15 15:39:08 +00:00
"x": {
"description": "X property",
"type": "integer"
2016-07-11 13:37:57 +00:00
},
2016-08-15 15:39:08 +00:00
"y": {
"description": "Y property",
"type": "integer"
2016-07-26 17:57:53 +00:00
},
2016-08-15 15:39:08 +00:00
"z": {
"description": "Z property",
"type": "integer"
2016-07-26 17:57:53 +00:00
},
2016-08-15 15:39:08 +00:00
"drawing_id": {
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$",
"maxLength": 36,
"minLength": 36,
"description": "Drawing UUID",
"type": "string"
}
},
"description": "An drawing object",
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "object"
},
"description": "Drawings elements",
"type": "array"
},
"nodes": {
"items": {
"additionalProperties": false,
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "object",
"properties": {
"node_type": {
"enum": [
"cloud",
"ethernet_hub",
"ethernet_switch",
"frame_relay_switch",
"atm_switch",
"docker",
"dynamips",
"vpcs",
"virtualbox",
"vmware",
"iou",
"qemu"
2016-07-26 17:57:53 +00:00
],
2016-08-15 15:39:08 +00:00
"description": "Type of node"
2016-07-26 17:57:53 +00:00
},
2016-08-15 15:39:08 +00:00
"symbol": {
"minLength": 1,
"description": "Symbol of the node",
"type": "string"
2016-07-26 17:57:53 +00:00
},
2016-08-15 15:39:08 +00:00
"x": {
"description": "X position of the node",
"type": "integer"
},
"console": {
"minimum": 1,
"maximum": 65535,
"description": "Console TCP port",
2016-07-14 13:31:49 +00:00
"type": [
2016-08-15 15:39:08 +00:00
"integer",
2016-07-14 13:31:49 +00:00
"null"
2016-08-15 15:39:08 +00:00
]
},
"console_type": {
"enum": [
"serial",
"vnc",
"telnet",
null
2016-07-26 17:57:53 +00:00
],
2016-08-15 15:39:08 +00:00
"description": "Console type"
2016-07-26 17:57:53 +00:00
},
2016-08-15 15:39:08 +00:00
"name": {
"minLength": 1,
"description": "Node name",
"type": "string"
},
"status": {
2016-08-15 10:08:59 +00:00
"enum": [
2016-08-15 15:39:08 +00:00
"stopped",
"started",
"suspended"
2016-07-26 17:57:53 +00:00
],
2016-08-15 15:39:08 +00:00
"description": "Status of the node"
},
"project_id": {
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$",
"maxLength": 36,
"minLength": 36,
"description": "Project UUID",
"type": "string"
},
"node_id": {
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$",
"maxLength": 36,
"minLength": 36,
"description": "Node UUID",
"type": "string"
},
"console_host": {
"minLength": 1,
"description": "Console host",
"type": "string"
},
"height": {
"description": "Height of the node",
"type": "integer"
},
"compute_id": {
"description": "Compute identifier",
"type": "string"
},
"width": {
"description": "Width of the node",
"type": "integer"
},
"node_directory": {
"description": "Working directory of the node. Read only",
"type": [
"null",
"string"
]
},
"z": {
"description": "Z position of the node",
"type": "integer"
},
"y": {
"description": "Y position of the node",
"type": "integer"
},
"command_line": {
"description": "Command line use to start the node",
"type": [
"null",
"string"
]
},
"properties": {
"description": "Properties specific to an emulator",
"type": "object"
},
"label": {
"required": [
"text",
"x",
"y"
],
"properties": {
"text": {
"type": "string"
},
"x": {
"description": "Relative X position of the label",
"type": "integer"
},
"y": {
"description": "Relative Y position of the label",
"type": "integer"
},
"rotation": {
"description": "Rotation of the label",
"type": "integer"
},
"style": {
"description": "SVG style attribute",
"type": "string"
}
},
"additionalProperties": false,
"type": "object"
2016-07-11 13:37:57 +00:00
}
},
2016-08-15 15:39:08 +00:00
"description": "A node object"
2016-08-15 10:08:59 +00:00
},
2016-08-15 15:39:08 +00:00
"description": "Nodes elements",
"type": "array"
2016-07-11 13:37:57 +00:00
}
2016-07-14 13:31:49 +00:00
},
2016-08-15 10:08:59 +00:00
"additionalProperties": false,
2016-08-15 15:39:08 +00:00
"description": "The topology content",
"type": "object"
},
"version": {
"description": "Version of the GNS3 software which have update the file for the last time",
"type": "string"
},
"auto_start": {
"description": "Start the topology when opened",
"type": "boolean"
},
"type": {
"enum": [
"topology"
2016-07-26 17:57:53 +00:00
],
2016-08-15 15:39:08 +00:00
"description": "Type of file. It's always topology"
},
"revision": {
"description": "Version of the .gns3 specification.",
"type": "integer"
2016-07-22 11:54:57 +00:00
},
2016-08-15 10:08:59 +00:00
"name": {
2016-08-15 15:39:08 +00:00
"description": "Name of the project",
"type": "string"
},
"project_id": {
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$",
"maxLength": 36,
"minLength": 36,
"description": "Project UUID",
"type": "string"
2016-07-11 13:37:57 +00:00
}
2016-07-22 11:54:57 +00:00
},
2016-07-26 17:57:53 +00:00
"description": "The topology"
2016-07-11 13:37:57 +00:00
}