diff options
Diffstat (limited to 'examples')
-rw-r--r-- | examples/demo.py | 5 | ||||
-rw-r--r-- | examples/launch.py | 7 |
2 files changed, 7 insertions, 5 deletions
diff --git a/examples/demo.py b/examples/demo.py index faf6459..8837bd2 100644 --- a/examples/demo.py +++ b/examples/demo.py @@ -34,9 +34,10 @@ network.create() # Flavors -from snaps.openstack.create_flavor import FlavorSettings, OpenStackFlavor +from snaps.config.flavor import FlavorConfig +from snaps.openstack.create_flavor import OpenStackFlavor -flavor_settings = FlavorSettings(name='test-flavor', ram=256, disk=10, vcpus=2) +flavor_settings = FlavorConfig(name='test-flavor', ram=256, disk=10, vcpus=2) flavor = OpenStackFlavor(os_creds, flavor_settings) flavor.create() diff --git a/examples/launch.py b/examples/launch.py index debb52f..499d259 100644 --- a/examples/launch.py +++ b/examples/launch.py @@ -26,9 +26,10 @@ import os import yaml from snaps import file_utils -from snaps.openstack.create_flavor import FlavorSettings, OpenStackFlavor -from snaps.openstack.create_image import OpenStackImage +from snaps.config.flavor import FlavorConfig from snaps.config.image import ImageConfig +from snaps.openstack.create_flavor import OpenStackFlavor +from snaps.openstack.create_image import OpenStackImage from snaps.openstack.create_instance import VmInstanceSettings from snaps.openstack.create_keypairs import KeypairSettings, OpenStackKeypair from snaps.openstack.create_network import ( @@ -635,7 +636,7 @@ def main(arguments): # Create flavors flavors_dict = __create_instances( - os_creds_dict, OpenStackFlavor, FlavorSettings, + os_creds_dict, OpenStackFlavor, FlavorConfig, os_config.get('flavors'), 'flavor', clean, users_dict) creators.append(flavors_dict) |