Class: Ansible::Ruby::Modules::Ovirt_disk
- Inherits:
-
Base
- Object
- Ansible::Ruby::Models::Base
- Base
- Ansible::Ruby::Modules::Ovirt_disk
- Defined in:
- lib/ansible/ruby/modules/generated/cloud/ovirt/ovirt_disk.rb,
lib/ansible/ruby/modules/generated/cloud/ovirt/ovirt_disks.rb
Overview
Module to manage Virtual Machine and floating disks in oVirt/RHV.
Instance Method Summary collapse
-
#bootable ⇒ Object?
I(True) if the disk should be bootable.
-
#description ⇒ String?
Description of the disk image to manage.
-
#download_image_path ⇒ String?
Path on a file system where disk should be downloaded.,Note that you must have an valid oVirt/RHV engine CA in your system trust store or you must provide it in C(ca_file) parameter.,Note that the disk is not downloaded when the file already exists, but you can forcibly download the disk when using C(force) I (true).
-
#force ⇒ Object?
Please take a look at C(image_path) documentation to see the correct usage of this parameter.
-
#format ⇒ :raw, ...
Specify format of the disk.,Note that this option isn’t idempotent as it’s not currently possible to change format of the disk via API.
-
#id ⇒ String?
ID of the disk to manage.
-
#image_provider ⇒ String?
When C(state) is I(exported) disk is exported to given Glance image provider.,C(IMPORTANT),There is no reliable way to achieve idempotency, so every time you specify this parameter the disk is exported, so please handle your playbook accordingly to not export the disk all the time.
-
#interface ⇒ :virtio, ...
Driver of the storage interface.,It’s required parameter when creating the new disk.
-
#logical_unit ⇒ Hash?
Dictionary which describes LUN to be directly attached to VM:,C(address) - Address of the storage server.
-
#name ⇒ String?
Name of the disk to manage.
-
#openstack_volume_type ⇒ Object?
Name of the openstack volume type.
-
#profile ⇒ Object?
Disk profile name to be attached to disk.
-
#quota_id ⇒ String?
Disk quota ID to be used for disk.
-
#shareable ⇒ Object?
I(True) if the disk should be shareable.
-
#size ⇒ String?
Size of the disk.
-
#sparse ⇒ Object?
I(True) if the disk should be sparse (also known as I(thin provision)).
-
#sparsify ⇒ Object?
I(True) if the disk should be sparsified.,Sparsification frees space in the disk image that is not used by its filesystem.
-
#state ⇒ :present, ...
Should the Virtual Machine disk be present/absent/attached/detached.
-
#storage_domain ⇒ String?
Storage domain name where disk should be created.
-
#storage_domains ⇒ Object?
Storage domain names where disk should be copied.,C(IMPORTANT),There is no reliable way to achieve idempotency, so every time you specify this parameter the disks are copied, so please handle your playbook accordingly to not copy the disks all the time.
-
#upload_image_path ⇒ Object?
Path to disk image, which should be uploaded.,Note that currently we support only compatibility version 0.10 of the qcow disk.,Note that you must have an valid oVirt/RHV engine CA in your system trust store or you must provide it in C(ca_file) parameter.,Note that there is no reliable way to achieve idempotency, so if you want to upload the disk even if the disk with C(id) or C(name) exists, then please use C(force) I(true).
-
#vm_id ⇒ Object?
ID of the Virtual Machine to manage.
-
#vm_name ⇒ String?
Name of the Virtual Machine to manage.
Methods inherited from Base
Methods inherited from Ansible::Ruby::Models::Base
attr_option, attr_options, attribute, fix_inclusion, #initialize, remove_existing_validations, #to_h, validates
Constructor Details
This class inherits a constructor from Ansible::Ruby::Models::Base
Instance Method Details
#bootable ⇒ Object?
Returns I(True) if the disk should be bootable. By default when disk is created it isn’t bootable.
74 |
# File 'lib/ansible/ruby/modules/generated/cloud/ovirt/ovirt_disk.rb', line 74 attribute :bootable |
#description ⇒ String?
Returns Description of the disk image to manage.
20 |
# File 'lib/ansible/ruby/modules/generated/cloud/ovirt/ovirt_disk.rb', line 20 attribute :description |
#download_image_path ⇒ String?
Returns Path on a file system where disk should be downloaded.,Note that you must have an valid oVirt/RHV engine CA in your system trust store or you must provide it in C(ca_file) parameter.,Note that the disk is not downloaded when the file already exists, but you can forcibly download the disk when using C(force) I (true).
35 |
# File 'lib/ansible/ruby/modules/generated/cloud/ovirt/ovirt_disk.rb', line 35 attribute :download_image_path |
#force ⇒ Object?
Returns Please take a look at C(image_path) documentation to see the correct usage of this parameter.
64 |
# File 'lib/ansible/ruby/modules/generated/cloud/ovirt/ovirt_disk.rb', line 64 attribute :force |
#format ⇒ :raw, ...
Returns Specify format of the disk.,Note that this option isn’t idempotent as it’s not currently possible to change format of the disk via API.
50 |
# File 'lib/ansible/ruby/modules/generated/cloud/ovirt/ovirt_disk.rb', line 50 attribute :format |
#id ⇒ String?
Returns ID of the disk to manage. Either C(id) or C(name) is required.
12 |
# File 'lib/ansible/ruby/modules/generated/cloud/ovirt/ovirt_disk.rb', line 12 attribute :id |
#image_provider ⇒ String?
Returns When C(state) is I(exported) disk is exported to given Glance image provider.,C(IMPORTANT),There is no reliable way to achieve idempotency, so every time you specify this parameter the disk is exported, so please handle your playbook accordingly to not export the disk all the time. This option is valid only for template disks.
90 |
# File 'lib/ansible/ruby/modules/generated/cloud/ovirt/ovirt_disk.rb', line 90 attribute :image_provider |
#interface ⇒ :virtio, ...
Returns Driver of the storage interface.,It’s required parameter when creating the new disk.
46 |
# File 'lib/ansible/ruby/modules/generated/cloud/ovirt/ovirt_disk.rb', line 46 attribute :interface |
#logical_unit ⇒ Hash?
Returns Dictionary which describes LUN to be directly attached to VM:,C(address) - Address of the storage server. Used by iSCSI.,C(port) - Port of the storage server. Used by iSCSI.,C(target) - iSCSI target.,C(lun_id) - LUN id.,C(username) - CHAP Username to be used to access storage server. Used by iSCSI.,C(password) - CHAP Password of the user to be used to access storage server. Used by iSCSI.,C(storage_type) - Storage type either I(fcp) or I(iscsi).
80 |
# File 'lib/ansible/ruby/modules/generated/cloud/ovirt/ovirt_disk.rb', line 80 attribute :logical_unit |
#name ⇒ String?
Returns Name of the disk to manage. Either C(id) or C(name)/C(alias) is required.
16 |
# File 'lib/ansible/ruby/modules/generated/cloud/ovirt/ovirt_disk.rb', line 16 attribute :name |
#openstack_volume_type ⇒ Object?
Returns Name of the openstack volume type. This is valid when working with cinder.
87 |
# File 'lib/ansible/ruby/modules/generated/cloud/ovirt/ovirt_disk.rb', line 87 attribute :openstack_volume_type |
#profile ⇒ Object?
Returns Disk profile name to be attached to disk. By default profile is chosen by oVirt/RHV engine.
67 |
# File 'lib/ansible/ruby/modules/generated/cloud/ovirt/ovirt_disk.rb', line 67 attribute :profile |
#quota_id ⇒ String?
Returns Disk quota ID to be used for disk. By default quota is chosen by oVirt/RHV engine.
70 |
# File 'lib/ansible/ruby/modules/generated/cloud/ovirt/ovirt_disk.rb', line 70 attribute :quota_id |
#shareable ⇒ Object?
Returns I(True) if the disk should be shareable. By default when disk is created it isn’t shareable.
77 |
# File 'lib/ansible/ruby/modules/generated/cloud/ovirt/ovirt_disk.rb', line 77 attribute :shareable |
#size ⇒ String?
Returns Size of the disk. Size should be specified using IEC standard units. For example 10GiB, 1024MiB, etc.,Size can be only increased, not decreased.
42 |
# File 'lib/ansible/ruby/modules/generated/cloud/ovirt/ovirt_disk.rb', line 42 attribute :size |
#sparse ⇒ Object?
Returns I(True) if the disk should be sparse (also known as I(thin provision)). If the parameter is omitted, cow disks will be created as sparse and raw disks as I(preallocated),Note that this option isn’t idempotent as it’s not currently possible to change sparseness of the disk via API.
54 |
# File 'lib/ansible/ruby/modules/generated/cloud/ovirt/ovirt_disk.rb', line 54 attribute :sparse |
#sparsify ⇒ Object?
Returns I(True) if the disk should be sparsified.,Sparsification frees space in the disk image that is not used by its filesystem. As a result, the image will occupy less space on the storage.,Note that this parameter isn’t idempotent, as it’s not possible to check if the disk should be or should not be sparsified.
84 |
# File 'lib/ansible/ruby/modules/generated/cloud/ovirt/ovirt_disk.rb', line 84 attribute :sparsify |
#state ⇒ :present, ...
Returns Should the Virtual Machine disk be present/absent/attached/detached.
31 |
# File 'lib/ansible/ruby/modules/generated/cloud/ovirt/ovirt_disk.rb', line 31 attribute :state |
#storage_domain ⇒ String?
Returns Storage domain name where disk should be created. By default storage is chosen by oVirt/RHV engine.
57 |
# File 'lib/ansible/ruby/modules/generated/cloud/ovirt/ovirt_disk.rb', line 57 attribute :storage_domain |
#storage_domains ⇒ Object?
Returns Storage domain names where disk should be copied.,C(IMPORTANT),There is no reliable way to achieve idempotency, so every time you specify this parameter the disks are copied, so please handle your playbook accordingly to not copy the disks all the time. This is valid only for VM and floating disks, template disks works as expected.
61 |
# File 'lib/ansible/ruby/modules/generated/cloud/ovirt/ovirt_disk.rb', line 61 attribute :storage_domains |
#upload_image_path ⇒ Object?
Returns Path to disk image, which should be uploaded.,Note that currently we support only compatibility version 0.10 of the qcow disk.,Note that you must have an valid oVirt/RHV engine CA in your system trust store or you must provide it in C(ca_file) parameter.,Note that there is no reliable way to achieve idempotency, so if you want to upload the disk even if the disk with C(id) or C(name) exists, then please use C(force) I(true). If you will use C(force) I(false), which is default, then the disk image won’t be uploaded.
39 |
# File 'lib/ansible/ruby/modules/generated/cloud/ovirt/ovirt_disk.rb', line 39 attribute :upload_image_path |
#vm_id ⇒ Object?
Returns ID of the Virtual Machine to manage. Either C(vm_id) or C(vm_name) is required if C(state) is I(attached) or I(detached).
28 |
# File 'lib/ansible/ruby/modules/generated/cloud/ovirt/ovirt_disk.rb', line 28 attribute :vm_id |
#vm_name ⇒ String?
Returns Name of the Virtual Machine to manage. Either C(vm_id) or C(vm_name) is required if C(state) is I(attached) or I(detached).
24 |
# File 'lib/ansible/ruby/modules/generated/cloud/ovirt/ovirt_disk.rb', line 24 attribute :vm_name |