From d70614378177b15767ca473e57878d4afba4a33c Mon Sep 17 00:00:00 2001 From: Brian Rosmaita Date: Fri, 8 Feb 2013 21:18:43 +0000 Subject: [PATCH] Adding new common image properties Revised schema and glance sphinx docs, renamed 'os_arch' to 'architecture' for backwards compatibility, renamed 'os_shortid' to 'os_libosinfo_shortid'. Partially implements blueprint glance-common-image-properties Change-Id: I23d8ba82015f1f53bff65b4fa08463d905eeadd8 --- doc/source/common-image-properties.rst | 66 ++++++++++++++++++++++++++ doc/source/index.rst | 1 + etc/schema-image.json | 16 +++++++ 3 files changed, 83 insertions(+) create mode 100644 doc/source/common-image-properties.rst diff --git a/doc/source/common-image-properties.rst b/doc/source/common-image-properties.rst new file mode 100644 index 0000000000..0d3e1a0324 --- /dev/null +++ b/doc/source/common-image-properties.rst @@ -0,0 +1,66 @@ +.. + Copyright 2013 OpenStack Foundation + All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"); you may + not use this file except in compliance with the License. You may obtain + a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, WITHOUT + WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the + License for the specific language governing permissions and limitations + under the License. + +Common Image Properties +======================= + +When adding an image to Glance, you may specify some common image properties +that may prove useful to consumers of your image. + +This document explains the names of these properties and the expected values. + +The common image properties are also described in a JSON schema, found in +etc/schema-image.json in the Glance source code. + +**architecture** +----------- + +Operating system architecture as specified in +http://docs.openstack.org/trunk/openstack-compute/admin/content/adding-images.html + +**instance_uuid** +----------------- + +The ID of the instance used to create this image. + +**kernel_id** +------------- + +The ID of image stored in Glance that should be used as the kernel when booting +an AMI-style image. + +**ramdisk_id** +-------------- + +The ID of image stored in Glance that should be used as the ramdisk when +booting an AMI-style image. + +**os_distro** +------------- + +The common name of the operating system distribution as specified in +http://docs.openstack.org/trunk/openstack-compute/admin/content/adding-images.html + +**os_libosinfo_shortid** +------------------------- + +The short identifier ('short-id') used by the libosinfo operating system +database. See http://libosinfo.org. + +**os_version** +-------------- + +The operating system version as specified by the distributor. diff --git a/doc/source/index.rst b/doc/source/index.rst index 3a8e16d5e3..842c91e709 100644 --- a/doc/source/index.rst +++ b/doc/source/index.rst @@ -49,6 +49,7 @@ Concepts identifiers statuses formats + common-image-properties Installing/Configuring Glance ============================= diff --git a/etc/schema-image.json b/etc/schema-image.json index 01de2a9702..1eccdd6056 100644 --- a/etc/schema-image.json +++ b/etc/schema-image.json @@ -12,5 +12,21 @@ "instance_uuid": { "type": "string", "description": "ID of instance used to create this image." + }, + "architecture": { + "description": "Operating system architecture as specified in http://docs.openstack.org/trunk/openstack-compute/admin/content/adding-images.html", + "type": "string" + }, + "os_distro": { + "description": "Common name of operating system distribution as specified in http://docs.openstack.org/trunk/openstack-compute/admin/content/adding-images.html", + "type": "string" + }, + "os_libosinfo_shortid": { + "description": "Short identifier ('short-id') used by libosinfo operating system database, http://libosinfo.org", + "type": "string" + }, + "os_version": { + "description": "Operating system version as specified by the distributor", + "type": "string" } }