diff --git a/lib/ansible/modules/cloud/softlayer/sl_vm.py b/lib/ansible/modules/cloud/softlayer/sl_vm.py index b46704c9e98..f47f0562b5a 100644 --- a/lib/ansible/modules/cloud/softlayer/sl_vm.py +++ b/lib/ansible/modules/cloud/softlayer/sl_vm.py @@ -63,6 +63,10 @@ options: description: - Amount of memory to be assigned to new virtual instance. required: true + flavor: + description: + - Specify which SoftLayer flavor template to use instead of cpus and memory. + version_added: "2.10" disks: description: - List of disk sizes to be assigned to new virtual instance. @@ -263,6 +267,7 @@ def create_virtual_instance(module): domain=module.params.get('domain'), cpus=module.params.get('cpus'), memory=module.params.get('memory'), + flavor=module.params.get('flavor'), hourly=module.params.get('hourly'), datacenter=module.params.get('datacenter'), os_code=module.params.get('os_code'), @@ -338,6 +343,7 @@ def main(): local_disk=dict(type='bool', default=True), cpus=dict(type='int', choices=CPU_SIZES), memory=dict(type='int', choices=MEMORY_SIZES), + flavor=dict(type='str'), disks=dict(type='list', default=[25]), os_code=dict(type='str'), image_id=dict(type='str'),