github.com/sixgill/terraform@v0.9.0-beta2.0.20170316214032-033f6226ae50/website/source/docs/providers/google/r/compute_disk.html.markdown (about)

     1  ---
     2  layout: "google"
     3  page_title: "Google: google_compute_disk"
     4  sidebar_current: "docs-google-compute-disk"
     5  description: |-
     6    Creates a new persistent disk within GCE, based on another disk.
     7  ---
     8  
     9  # google\_compute\_disk
    10  
    11  Creates a new persistent disk within GCE, based on another disk.
    12  
    13  ## Example Usage
    14  
    15  ```js
    16  resource "google_compute_disk" "default" {
    17    name  = "test-disk"
    18    type  = "pd-ssd"
    19    zone  = "us-central1-a"
    20    image = "debian7-wheezy"
    21  }
    22  ```
    23  
    24  ## Argument Reference
    25  
    26  The following arguments are supported:
    27  
    28  * `name` - (Required) A unique name for the resource, required by GCE.
    29      Changing this forces a new resource to be created.
    30  
    31  * `zone` - (Required) The zone where this disk will be available.
    32  
    33  - - -
    34  
    35  * `disk_encryption_key_raw` - (Optional) A 256-bit [customer-supplied encryption key]
    36      (https://cloud.google.com/compute/docs/disks/customer-supplied-encryption),
    37      encoded in [RFC 4648 base64](https://tools.ietf.org/html/rfc4648#section-4)
    38      to encrypt this disk.
    39  
    40  * `image` - (Optional) The image from which to initialize this disk. This can be
    41      one of: the image's `self_link`, `projects/{project}/global/images/{image}`,
    42      `projects/{project}/global/images/family/{family}`, `global/images/{image}`,
    43      `global/images/family/{family}`, `family/{family}`, `{project}/{family}`,
    44      `{project}/{image}`, `{family}`, or `{image}`.
    45  
    46  * `project` - (Optional) The project in which the resource belongs. If it
    47      is not provided, the provider project is used.
    48  
    49  * `size` - (Optional) The size of the image in gigabytes. If not specified, it
    50      will inherit the size of its base image.
    51  
    52  * `snapshot` - (Optional) Name of snapshot from which to initialize this disk.
    53  
    54  * `type` - (Optional) The GCE disk type.
    55  
    56  ## Attributes Reference
    57  
    58  In addition to the arguments listed above, the following computed attributes are
    59  exported:
    60  
    61  * `disk_encryption_key_sha256` - The [RFC 4648 base64]
    62      (https://tools.ietf.org/html/rfc4648#section-4) encoded SHA-256 hash of the
    63      [customer-supplied encryption key](https://cloud.google.com/compute/docs/disks/customer-supplied-encryption)
    64      that protects this resource.
    65  
    66  * `self_link` - The URI of the created resource.