From: Suresh Babu Angadi <sureshab(a)in.ibm.com>
added error codes and json attribute for update of 'console'
Signed-off-by: Suresh Babu Angadi <sureshab(a)in.ibm.com>
---
API.json | 24 +++++++++++++++++++++---
i18n.py | 2 ++
2 files changed, 23 insertions(+), 3 deletions(-)
diff --git a/API.json b/API.json
index 9ad60a2..15a348c 100644
--- a/API.json
+++ b/API.json
@@ -414,7 +414,13 @@
}
},
"cpu_info": { "$ref":
"#/kimchitype/cpu_info" },
- "memory": { "$ref": "#/kimchitype/memory"
}
+ "memory": { "$ref": "#/kimchitype/memory"
},
+ "console": {
+ "description": "type of the console attached to the
guest in s390x architecture",
+ "type": "string",
+ "pattern": "^sclp|virtio$",
+ "error": "KCHTMPL0041E"
+ }
},
"additionalProperties": false
},
@@ -671,7 +677,13 @@
"items": { "type": "string" }
},
"graphics": { "$ref":
"#/kimchitype/graphics" },
- "cpu_info": { "$ref":
"#/kimchitype/cpu_info" }
+ "cpu_info": { "$ref":
"#/kimchitype/cpu_info" },
+ "console": {
+ "description": "type of the console attached to the
guest in s390x architecture",
+ "type": "string",
+ "pattern": "^sclp|virtio$",
+ "error": "KCHTMPL0041E"
+ }
},
"additionalProperties": false,
"error": "KCHAPI0001E"
@@ -844,7 +856,13 @@
"items": { "type": "string" }
},
"graphics": { "$ref":
"#/kimchitype/graphics" },
- "cpu_info": { "$ref":
"#/kimchitype/cpu_info" }
+ "cpu_info": { "$ref":
"#/kimchitype/cpu_info" },
+ "console": {
+ "description": "type of the console attached to the
guest in s390x architecture",
+ "type": "string",
+ "pattern": "^sclp|virtio$",
+ "error": "KCHTMPL0041E"
+ }
},
"additionalProperties": false,
"error": "KCHAPI0001E"
diff --git a/i18n.py b/i18n.py
index 47c829e..1684dc4 100644
--- a/i18n.py
+++ b/i18n.py
@@ -203,6 +203,8 @@ messages = {
"KCHTMPL0037E": _("Interfaces should be list of interfaces. Each
interface should have name, type and mode(optional, only applicable for interfcae type
'macvtap'."),
"KCHTMPL0038E": _("Interface expects an object with parameters:
'name', 'type' and 'mode'. Name should be name of host network
interface (Ethernet, Bond, VLAN) for type 'macvtap' or the name of host
openvswitch bridge interface for type 'ovs'. Mode (optional) is only applicable
for interface type 'macvtap' to indicates whether packets will be delivered
directly to target device (bridge) or to the external bridge (vepa-capable
bridge)."),
"KCHTMPL0039E": _("Interfaces parameter only supported on s390x or
s390 architecture."),
+ "KCHTMPL0040E": _("console parameter is only supported for s390x/s390
architecture."),
+ "KCHTMPL0041E": _("invalid console type, supported types are
sclp/virtio."),
"KCHPOOL0001E": _("Storage pool %(name)s already exists"),
"KCHPOOL0002E": _("Storage pool %(name)s does not exist"),
--
2.1.0