Class: Ansible::Ruby::Modules::Gcp_compute_disk
- Inherits:
-
Base
- Object
- Ansible::Ruby::Models::Base
- Base
- Ansible::Ruby::Modules::Gcp_compute_disk
- Defined in:
- lib/ansible/ruby/modules/generated/cloud/google/gcp_compute_disk.rb
Overview
Persistent disks are durable storage devices that function similarly to the physical disks in a desktop or a server. Compute Engine manages the hardware behind these devices to ensure data redundancy and optimize performance for you. Persistent disks are available as either standard hard disk drives (HDD) or solid-state drives (SSD). Persistent disks are located independently from your virtual machine instances, so you can detach or move persistent disks to keep your data even after you delete your instances. Persistent disk performance scales automatically with size, so you can resize your existing persistent disks or add more persistent disks to an instance to meet your performance and storage space requirements. Add a persistent disk to your instance when you need reliable and affordable storage with consistent performance characteristics.
Instance Method Summary collapse
-
#description ⇒ Object?
An optional description of this resource.
-
#disk_encryption_key ⇒ Hash?
Encrypts the disk using a customer-supplied encryption key.,After you encrypt a disk with a customer-supplied key, you must provide the same key if you use the disk later (e.g. to create a disk snapshot or an image, or to attach the disk to a virtual machine).,Customer-supplied encryption keys do not protect access to metadata of the disk.,If you do not provide an encryption key when creating the disk, then the disk will be encrypted using an automatically generated key and you do not need to provide a key to use the disk later.
-
#labels ⇒ Object?
Labels to apply to this disk.
-
#licenses ⇒ Object?
Any applicable publicly visible licenses.
-
#name ⇒ String
Name of the resource.
-
#size_gb ⇒ Integer?
Size of the persistent disk, specified in GB.
-
#source_image ⇒ Object?
The source image used to create this disk.
-
#source_image_encryption_key ⇒ Object?
The customer-supplied encryption key of the source image.
-
#source_snapshot ⇒ Object?
The source snapshot used to create this disk.
-
#source_snapshot_encryption_key ⇒ Object?
The customer-supplied encryption key of the source snapshot.
-
#state ⇒ :present, ...
Whether the given object should exist in GCP.
-
#type ⇒ Object?
URL of the disk type resource describing which disk type to use to create the disk.
-
#zone ⇒ String
A reference to the zone where the disk resides.
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
#description ⇒ Object?
Returns An optional description of this resource. Provide this property when you create the resource.
18 |
# File 'lib/ansible/ruby/modules/generated/cloud/google/gcp_compute_disk.rb', line 18 attribute :description |
#disk_encryption_key ⇒ Hash?
Returns Encrypts the disk using a customer-supplied encryption key.,After you encrypt a disk with a customer-supplied key, you must provide the same key if you use the disk later (e.g. to create a disk snapshot or an image, or to attach the disk to a virtual machine).,Customer-supplied encryption keys do not protect access to metadata of the disk.,If you do not provide an encryption key when creating the disk, then the disk will be encrypted using an automatically generated key and you do not need to provide a key to use the disk later.
48 |
# File 'lib/ansible/ruby/modules/generated/cloud/google/gcp_compute_disk.rb', line 48 attribute :disk_encryption_key |
#labels ⇒ Object?
Returns Labels to apply to this disk. A list of key->value pairs.
21 |
# File 'lib/ansible/ruby/modules/generated/cloud/google/gcp_compute_disk.rb', line 21 attribute :labels |
#licenses ⇒ Object?
Returns Any applicable publicly visible licenses.
24 |
# File 'lib/ansible/ruby/modules/generated/cloud/google/gcp_compute_disk.rb', line 24 attribute :licenses |
#name ⇒ String
Returns Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression ‘[a-z](*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
27 |
# File 'lib/ansible/ruby/modules/generated/cloud/google/gcp_compute_disk.rb', line 27 attribute :name |
#size_gb ⇒ Integer?
Returns Size of the persistent disk, specified in GB. You can specify this field when creating a persistent disk using the sourceImage or sourceSnapshot parameter, or specify it alone to create an empty persistent disk.,If you specify this field along with sourceImage or sourceSnapshot, the value of sizeGb must not be less than the size of the sourceImage or the size of the snapshot.
31 |
# File 'lib/ansible/ruby/modules/generated/cloud/google/gcp_compute_disk.rb', line 31 attribute :size_gb |
#source_image ⇒ Object?
Returns The source image used to create this disk. If the source image is deleted, this field will not be set.,To create a disk with one of the public operating system images, specify the image by its family name. For example, specify family/debian-8 to use the latest Debian 8 image: projects/debian-cloud/global/images/family/debian-8 Alternatively, use a specific version of a public operating system image: projects/debian-cloud/global/images/debian-8-jessie-vYYYYMMDD To create a disk with a private image that you created, specify the image name in the following format: global/images/my-private-image You can also specify a private image by its image family, which returns the latest version of the image in that family. Replace the image name with family/family-name: global/images/family/my-private-family .
38 |
# File 'lib/ansible/ruby/modules/generated/cloud/google/gcp_compute_disk.rb', line 38 attribute :source_image |
#source_image_encryption_key ⇒ Object?
Returns The customer-supplied encryption key of the source image. Required if the source image is protected by a customer-supplied encryption key.
45 |
# File 'lib/ansible/ruby/modules/generated/cloud/google/gcp_compute_disk.rb', line 45 attribute :source_image_encryption_key |
#source_snapshot ⇒ Object?
Returns The source snapshot used to create this disk. You can provide this as a partial or full URL to the resource. For example, the following are valid values: * ‘U(www.googleapis.com/compute/v1/projects/project/global/snapshots/snapshot`) * `projects/project/global/snapshots/snapshot` * `global/snapshots/snapshot` .
52 |
# File 'lib/ansible/ruby/modules/generated/cloud/google/gcp_compute_disk.rb', line 52 attribute :source_snapshot |
#source_snapshot_encryption_key ⇒ Object?
Returns The customer-supplied encryption key of the source snapshot. Required if the source snapshot is protected by a customer-supplied encryption key.
55 |
# File 'lib/ansible/ruby/modules/generated/cloud/google/gcp_compute_disk.rb', line 55 attribute :source_snapshot_encryption_key |
#state ⇒ :present, ...
Returns Whether the given object should exist in GCP.
14 |
# File 'lib/ansible/ruby/modules/generated/cloud/google/gcp_compute_disk.rb', line 14 attribute :state |
#type ⇒ Object?
Returns URL of the disk type resource describing which disk type to use to create the disk. Provide this when creating the disk.
35 |
# File 'lib/ansible/ruby/modules/generated/cloud/google/gcp_compute_disk.rb', line 35 attribute :type |
#zone ⇒ String
Returns A reference to the zone where the disk resides.
41 |
# File 'lib/ansible/ruby/modules/generated/cloud/google/gcp_compute_disk.rb', line 41 attribute :zone |