CloudStorageBucket
A resource of the GCP provider, version 0.2.0, in its Storage group. Import it with:
import CloudStorageBucket from "gcp/storage"Example
resource CloudStorageBucket example {
name = "example-value"
location = "US"
storageClass = "STANDARD"
versioning = false
labels = "..."
uniformBucketLevelAccess = true
}Properties
Set by your code in the resource block. A required one must be set; any other you leave out takes the value under Default, if it has one.
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
name | string | — | No | Globally unique bucket name |
location | string | "US" | No | The location of the bucket (e.g., US, EU, us-central1) |
storageClass | string | "STANDARD" | No | The storage class for the bucket Allowed: "STANDARD", "NEARLINE", "COLDLINE", "ARCHIVE" |
versioning | boolean | false | No | Enable object versioning |
labels | object | — | No | Labels to apply to the bucket |
uniformBucketLevelAccess | boolean | true | No | Whether uniform bucket-level access is enabled |
Set by GCP after the resource is created: your code can read them but not set them. An importable one identifies an existing resource.
| Name | Type | Importable | Description |
|---|---|---|---|
selfLink | string | Yes | The self-link URL of the bucket |
timeCreated | string | No | The creation time of the bucket |