diff options
author | 2017-11-16 16:07:47 -0700 | |
---|---|---|
committer | 2017-11-16 16:07:47 -0700 | |
commit | 4cad4f7d1f53189900f9024fa5478e98a64d3760 (patch) | |
tree | a7a7161386d67b6a0214d7f802a5132b58ad2e71 /docs/how-to-use/LibraryUsage.rst | |
parent | 792a01b6592b320b80bdc7465247b0fcb19f1264 (diff) |
Refactoring of ImageSettings to extend ImageConfig
ImageSettings and glance_utils have a runtime cyclical
dependency. This patch reduces this dependency and
deprecates the ImageSettings class.
JIRA: SNAPS-217
Change-Id: I09f34531366f2a5bd3202c9cbbdef878b2542abe
Signed-off-by: spisarski <s.pisarski@cablelabs.com>
Diffstat (limited to 'docs/how-to-use/LibraryUsage.rst')
-rw-r--r-- | docs/how-to-use/LibraryUsage.rst | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/docs/how-to-use/LibraryUsage.rst b/docs/how-to-use/LibraryUsage.rst index 9518c2b..a842be0 100644 --- a/docs/how-to-use/LibraryUsage.rst +++ b/docs/how-to-use/LibraryUsage.rst @@ -170,7 +170,7 @@ Create Image ------------ - ImageĀ - snaps.openstack.create\_image.OpenStackImage - - snaps.openstack.create\_image.ImageSettings + - snaps.config.image.ImageConfig - name - the image name (required) - image\_user - the default image user generally used by @@ -193,9 +193,10 @@ Create Image .. code:: python - from snaps.openstack.create_image import ImageSettings, OpenStackImage - image_settings = ImageSettings(name='image-name', image_user='ubuntu', img_format='qcow2', - url='http://uec-images.ubuntu.com/releases/trusty/14.04/ubuntu-14.04-server-cloudimg-amd64-disk1.img') + from snaps.openstack.create_image import OpenStackImage + from snaps.config.image import ImageConfig + image_settings = ImageConfig(name='image-name', image_user='ubuntu', img_format='qcow2', + url='http://uec-images.ubuntu.com/releases/trusty/14.04/ubuntu-14.04-server-cloudimg-amd64-disk1.img') image_creator = OpenStackImage(os_creds, image_settings) image_creator.create() @@ -571,7 +572,7 @@ Create VM Instance - userdata - the cloud-init script to execute after VM has been started - - image\_settings - see snaps.openstack.create\_image.ImageSettings + - image\_settings - see snaps.config.image.ImageConfig above (required) - keypair\_settings - see snaps.openstack.create\_keypairs.KeypairSettings above (optional) |