Browse Source

Allow ramdisk_id, kernel_id to be null on schema

Since is possible to create images with no
ramdisk_id, kernel_id parameters on glance v1,
then the schema-image.json needs to be modified to
allow null, string values for both attributes
and prevent LP #1447193 to happen with a glance v2
client.

APIImpact

Closes-Bug: #1447215
Related-Bug: #1447193

Change-Id: I645c797553ccaa84062f9ad28f2349ae738a0c96
Signed-off-by: Jorge Niedbalski <jorge.niedbalski@canonical.com>
(cherry picked from commit 82c63b1df4)
tags/2015.1.2
Jorge Niedbalski 4 years ago
parent
commit
4b26977596
1 changed files with 2 additions and 2 deletions
  1. 2
    2
      etc/schema-image.json

+ 2
- 2
etc/schema-image.json View File

@@ -1,11 +1,11 @@
1 1
 {
2 2
     "kernel_id": {
3
-        "type": "string",
3
+        "type": ["null", "string"],
4 4
         "pattern": "^([0-9a-fA-F]){8}-([0-9a-fA-F]){4}-([0-9a-fA-F]){4}-([0-9a-fA-F]){4}-([0-9a-fA-F]){12}$",
5 5
         "description": "ID of image stored in Glance that should be used as the kernel when booting an AMI-style image."
6 6
     },
7 7
     "ramdisk_id": {
8
-        "type": "string",
8
+        "type": ["null", "string"],
9 9
         "pattern": "^([0-9a-fA-F]){8}-([0-9a-fA-F]){4}-([0-9a-fA-F]){4}-([0-9a-fA-F]){4}-([0-9a-fA-F]){12}$",
10 10
         "description": "ID of image stored in Glance that should be used as the ramdisk when booting an AMI-style image."
11 11
     },

Loading…
Cancel
Save