github.com/danp/terraform@v0.9.5-0.20170426144147-39d740081351/website/source/docs/providers/google/r/storage_bucket_object.html.markdown (about)

     1  ---
     2  layout: "google"
     3  page_title: "Google: google_storage_bucket_object"
     4  sidebar_current: "docs-google-storage-bucket-object"
     5  description: |-
     6    Creates a new object inside a specified bucket
     7  ---
     8  
     9  # google\_storage\_bucket\_object
    10  
    11  Creates a new object inside an exisiting bucket in Google cloud storage service (GCS). Currently, it does not support creating custom ACLs. For more information see [the official documentation](https://cloud.google.com/storage/docs/overview) and [API](https://cloud.google.com/storage/docs/json_api).
    12  
    13  
    14  ## Example Usage
    15  
    16  Example creating a public object in an existing `image-store` bucket.
    17  
    18  ```hcl
    19  resource "google_storage_bucket_object" "picture" {
    20    name   = "butterfly01"
    21    source = "/images/nature/garden-tiger-moth.jpg"
    22    bucket = "image-store"
    23  }
    24  ```
    25  
    26  ## Argument Reference
    27  
    28  The following arguments are supported:
    29  
    30  * `bucket` - (Required) The name of the containing bucket.
    31  
    32  * `name` - (Required) The name of the object.
    33  
    34  - - -
    35  
    36  * `content` - (Optional) Data as `string` to be uploaded. Must be defined if
    37      `source` is not.
    38  
    39  * `predefined_acl` - (Optional, Deprecated) The [canned GCS ACL](https://cloud.google.com/storage/docs/access-control#predefined-acl) apply. Please switch
    40  to `google_storage_object_acl.predefined_acl`.
    41  
    42  
    43  * `source` - (Optional) A path to the data you want to upload. Must be defined
    44      if `content` is not.
    45  
    46  ## Attributes Reference
    47  
    48  In addition to the arguments listed above, the following computed attributes are
    49  exported:
    50  
    51  * `crc32c` - (Computed) Base 64 CRC32 hash of the uploaded data.
    52  
    53  * `md5hash` - (Computed) Base 64 MD5 hash of the uploaded data.