pulumi_wasm_providers_gcp_mini::storage

Module bucket_object

source
Expand description

Creates a new object inside an existing bucket in Google cloud storage service (GCS). ACLs can be applied using the gcp.storage.ObjectACL resource. For more information see the official documentation and API.

§Example Usage

Example creating a public object in an existing image-store bucket.

resources:
  picture:
    type: gcp:storage:BucketObject
    properties:
      name: butterfly01
      source:
        fn::FileAsset: /images/nature/garden-tiger-moth.jpg
      bucket: image-store

Example creating an empty folder in an existing image-store bucket.

use pulumi_wasm_rust::Output;
use pulumi_wasm_rust::{add_export, pulumi_main};
#[pulumi_main]
fn test_main() -> Result<(), Error> {
    let emptyFolder = bucket_object::create(
        "emptyFolder",
        BucketObjectArgs::builder()
            .bucket("image-store")
            .content(" ")
            .name("empty_folder/")
            .build_struct(),
    );
}

§Import

This resource does not support import.

Structs§

Functions§

  • Registers a new resource with the given unique name and arguments