CreateBucket
Create a GCS bucket or update if it already exists.
type: "io.kestra.plugin.gcp.gcs.CreateBucket"
Examples
Create a new bucket with some options
id: gcp_gcs_create_bucket
namespace: company.team
tasks:
- id: create_bucket
type: io.kestra.plugin.gcp.gcs.CreateBucket
name: "my-bucket"
versioningEnabled: true
labels:
my-label: my-value
Properties
name *Requiredstring
Bucket's unique name
acl Non-dynamicarray
The bucket's access control configuration
cors Non-dynamicarray
The bucket's Cross-Origin Resource Sharing (CORS) configuration
defaultAcl Non-dynamicarray
The default access control configuration
The access control configuration to apply to bucket's blobs when no other configuration is specified. See About Access Control Lists
defaultEventBasedHold booleanstring
The default event-based hold for this bucket
defaultKmsKeyName string
The default Cloud KMS key name for this bucket
iamConfiguration Non-dynamicIamConfiguration
The Bucket's IAM Configuration
ifExists string
ERROR
ERROR
UPDATE
SKIP
Policy to apply if a bucket already exists.
impersonatedServiceAccount string
The GCP service account to impersonate.
indexPage string
The bucket's website index page
Behaves as the bucket's directory index where missing blobs are treated as potential directories.
labels object
The labels of this bucket
lifecycleRules Non-dynamicarray
The bucket's lifecycle configuration
This configuration is expressed as a number of lifecycle rules, consisting of an action and a condition. See Object Lifecycle Management Only the age condition is supported. Only the delete and SetStorageClass actions are supported
location string
The bucket's location
Data for blobs in the bucket resides in physical storage within this region. A list of supported values is available here.
logging Non-dynamicLogging
The bucket's logging configuration
This configuration defines the destination bucket and optional name prefix for the current bucket's logs.
notFoundPage string
The custom object to return when a requested resource is not found
projectId string
The GCP project ID.
requesterPays booleanstring
Whether the requester pays or not.
Whether a user accessing the bucket or an object it contains should assume the transit costs related to the access.
retentionPeriod integerstring
Retention period
If policy is not locked this value can be cleared, increased, and decreased. If policy is locked the retention period can only be increased.
scopes array
["https://www.googleapis.com/auth/cloud-platform"]
The GCP scopes to be used.
serviceAccount string
The GCP service account.
storageClass string
REGIONAL
MULTI_REGIONAL
NEARLINE
COLDLINE
STANDARD
ARCHIVE
DURABLE_REDUCED_AVAILABILITY
The bucket's storage class
This defines how blobs in the bucket are stored and determines the SLA and the cost of storage. A list of supported values is available here.
versioningEnabled booleanstring
Whether versioning should be enabled for this bucket
When set to true, versioning is fully enabled.
Outputs
bucket Bucket
The bucket's info
created boolean
false
If the bucket was created.
updated boolean
false
If the bucket was updated.
Definitions
io.kestra.plugin.gcp.gcs.models.BucketLifecycleRule-Condition
age *Requiredintegerstring
The Age condition is satisfied when an object reaches the specified age (in days). Age is measured from the object's creation time.
io.kestra.plugin.gcp.gcs.models.IamConfiguration
publicAccessPrevention string
ENFORCED
UNSPECIFIED
UNKNOWN
INHERITED
uniformBucketLevelAccessEnabled boolean
io.kestra.plugin.gcp.gcs.models.Entity
type *Requiredstring
DOMAIN
GROUP
USER
The type of the entity (USER, GROUP or DOMAIN)
value *Requiredstring
The value for the entity (ex : user email if the type is USER ...)
com.google.cloud.storage.Cors-Origin
value string
io.kestra.plugin.gcp.gcs.models.Cors
io.kestra.plugin.gcp.gcs.models.AccessControl
entity *RequiredEntity
The entity
role *Requiredstring
READER
WRITER
OWNER
The role to assign to the entity
io.kestra.plugin.gcp.gcs.models.BucketLifecycleRule
action *RequiredBucketLifecycleRule-Action
The action to take when a lifecycle condition is met
condition *RequiredBucketLifecycleRule-Condition
The condition
io.kestra.plugin.gcp.gcs.models.BucketLifecycleRule-Action
type *Requiredstring
DELETE
SET_STORAGE_CLASS
The type of the action (DELETE ...)
value string
The value for the action (if any)
io.kestra.plugin.gcp.gcs.models.Logging
logBucket string
logObjectPrefix string
io.kestra.plugin.gcp.gcs.models.Bucket
indexPage string
The bucket's website index page.
location string
The bucket's location
name string
The bucket's unique name
notFoundPage string
The custom object to return when a requested resource is not found.
uri string
uri
The bucket's URI.