1. Packages
  2. UpCloud
  3. API Docs
  4. ManagedObjectStorageBucket
UpCloud v0.1.0 published on Friday, Mar 14, 2025 by UpCloudLtd

upcloud.ManagedObjectStorageBucket

Explore with Pulumi AI

This resource represents an UpCloud Managed Object Storage bucket.

This resource uses the UpCloud API to manage the Managed Object Storage buckets. The main difference to S3 API is that the buckets can be deleted even when the bucket contains objects.

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as upcloud from "@upcloud/pulumi-upcloud";

const example = new upcloud.ManagedObjectStorage("example", {
    name: "bucket-example-objstov2",
    region: "europe-1",
    configuredStatus: "started",
});
const exampleManagedObjectStorageBucket = new upcloud.ManagedObjectStorageBucket("example", {
    serviceUuid: example.id,
    name: "bucket",
});
Copy
import pulumi
import pulumi_upcloud as upcloud

example = upcloud.ManagedObjectStorage("example",
    name="bucket-example-objstov2",
    region="europe-1",
    configured_status="started")
example_managed_object_storage_bucket = upcloud.ManagedObjectStorageBucket("example",
    service_uuid=example.id,
    name="bucket")
Copy
package main

import (
	"github.com/UpCloudLtd/pulumi-upcloud/sdk/go/upcloud"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		example, err := upcloud.NewManagedObjectStorage(ctx, "example", &upcloud.ManagedObjectStorageArgs{
			Name:             pulumi.String("bucket-example-objstov2"),
			Region:           pulumi.String("europe-1"),
			ConfiguredStatus: pulumi.String("started"),
		})
		if err != nil {
			return err
		}
		_, err = upcloud.NewManagedObjectStorageBucket(ctx, "example", &upcloud.ManagedObjectStorageBucketArgs{
			ServiceUuid: example.ID(),
			Name:        pulumi.String("bucket"),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using UpCloud = UpCloud.Pulumi.UpCloud;

return await Deployment.RunAsync(() => 
{
    var example = new UpCloud.ManagedObjectStorage("example", new()
    {
        Name = "bucket-example-objstov2",
        Region = "europe-1",
        ConfiguredStatus = "started",
    });

    var exampleManagedObjectStorageBucket = new UpCloud.ManagedObjectStorageBucket("example", new()
    {
        ServiceUuid = example.Id,
        Name = "bucket",
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.upcloud.ManagedObjectStorage;
import com.pulumi.upcloud.ManagedObjectStorageArgs;
import com.pulumi.upcloud.ManagedObjectStorageBucket;
import com.pulumi.upcloud.ManagedObjectStorageBucketArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;

public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }

    public static void stack(Context ctx) {
        var example = new ManagedObjectStorage("example", ManagedObjectStorageArgs.builder()
            .name("bucket-example-objstov2")
            .region("europe-1")
            .configuredStatus("started")
            .build());

        var exampleManagedObjectStorageBucket = new ManagedObjectStorageBucket("exampleManagedObjectStorageBucket", ManagedObjectStorageBucketArgs.builder()
            .serviceUuid(example.id())
            .name("bucket")
            .build());

    }
}
Copy
resources:
  example:
    type: upcloud:ManagedObjectStorage
    properties:
      name: bucket-example-objstov2
      region: europe-1
      configuredStatus: started
  exampleManagedObjectStorageBucket:
    type: upcloud:ManagedObjectStorageBucket
    name: example
    properties:
      serviceUuid: ${example.id}
      name: bucket
Copy

Create ManagedObjectStorageBucket Resource

Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

Constructor syntax

new ManagedObjectStorageBucket(name: string, args: ManagedObjectStorageBucketArgs, opts?: CustomResourceOptions);
@overload
def ManagedObjectStorageBucket(resource_name: str,
                               args: ManagedObjectStorageBucketArgs,
                               opts: Optional[ResourceOptions] = None)

@overload
def ManagedObjectStorageBucket(resource_name: str,
                               opts: Optional[ResourceOptions] = None,
                               service_uuid: Optional[str] = None,
                               name: Optional[str] = None)
func NewManagedObjectStorageBucket(ctx *Context, name string, args ManagedObjectStorageBucketArgs, opts ...ResourceOption) (*ManagedObjectStorageBucket, error)
public ManagedObjectStorageBucket(string name, ManagedObjectStorageBucketArgs args, CustomResourceOptions? opts = null)
public ManagedObjectStorageBucket(String name, ManagedObjectStorageBucketArgs args)
public ManagedObjectStorageBucket(String name, ManagedObjectStorageBucketArgs args, CustomResourceOptions options)
type: upcloud:ManagedObjectStorageBucket
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

Parameters

name This property is required. string
The unique name of the resource.
args This property is required. ManagedObjectStorageBucketArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name This property is required. str
The unique name of the resource.
args This property is required. ManagedObjectStorageBucketArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name This property is required. string
The unique name of the resource.
args This property is required. ManagedObjectStorageBucketArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name This property is required. string
The unique name of the resource.
args This property is required. ManagedObjectStorageBucketArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name This property is required. String
The unique name of the resource.
args This property is required. ManagedObjectStorageBucketArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

Constructor example

The following reference example uses placeholder values for all input properties.

var managedObjectStorageBucketResource = new UpCloud.ManagedObjectStorageBucket("managedObjectStorageBucketResource", new()
{
    ServiceUuid = "string",
    Name = "string",
});
Copy
example, err := upcloud.NewManagedObjectStorageBucket(ctx, "managedObjectStorageBucketResource", &upcloud.ManagedObjectStorageBucketArgs{
	ServiceUuid: pulumi.String("string"),
	Name:        pulumi.String("string"),
})
Copy
var managedObjectStorageBucketResource = new ManagedObjectStorageBucket("managedObjectStorageBucketResource", ManagedObjectStorageBucketArgs.builder()
    .serviceUuid("string")
    .name("string")
    .build());
Copy
managed_object_storage_bucket_resource = upcloud.ManagedObjectStorageBucket("managedObjectStorageBucketResource",
    service_uuid="string",
    name="string")
Copy
const managedObjectStorageBucketResource = new upcloud.ManagedObjectStorageBucket("managedObjectStorageBucketResource", {
    serviceUuid: "string",
    name: "string",
});
Copy
type: upcloud:ManagedObjectStorageBucket
properties:
    name: string
    serviceUuid: string
Copy

ManagedObjectStorageBucket Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

Inputs

In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

The ManagedObjectStorageBucket resource accepts the following input properties:

ServiceUuid This property is required. string
Managed Object Storage service UUID.
Name string
Name of the bucket.
ServiceUuid This property is required. string
Managed Object Storage service UUID.
Name string
Name of the bucket.
serviceUuid This property is required. String
Managed Object Storage service UUID.
name String
Name of the bucket.
serviceUuid This property is required. string
Managed Object Storage service UUID.
name string
Name of the bucket.
service_uuid This property is required. str
Managed Object Storage service UUID.
name str
Name of the bucket.
serviceUuid This property is required. String
Managed Object Storage service UUID.
name String
Name of the bucket.

Outputs

All input properties are implicitly available as output properties. Additionally, the ManagedObjectStorageBucket resource produces the following output properties:

Id string
The provider-assigned unique ID for this managed resource.
TotalObjects int
Number of objects stored in the bucket.
TotalSizeBytes int
Total size of objects stored in the bucket.
Id string
The provider-assigned unique ID for this managed resource.
TotalObjects int
Number of objects stored in the bucket.
TotalSizeBytes int
Total size of objects stored in the bucket.
id String
The provider-assigned unique ID for this managed resource.
totalObjects Integer
Number of objects stored in the bucket.
totalSizeBytes Integer
Total size of objects stored in the bucket.
id string
The provider-assigned unique ID for this managed resource.
totalObjects number
Number of objects stored in the bucket.
totalSizeBytes number
Total size of objects stored in the bucket.
id str
The provider-assigned unique ID for this managed resource.
total_objects int
Number of objects stored in the bucket.
total_size_bytes int
Total size of objects stored in the bucket.
id String
The provider-assigned unique ID for this managed resource.
totalObjects Number
Number of objects stored in the bucket.
totalSizeBytes Number
Total size of objects stored in the bucket.

Look up Existing ManagedObjectStorageBucket Resource

Get an existing ManagedObjectStorageBucket resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

public static get(name: string, id: Input<ID>, state?: ManagedObjectStorageBucketState, opts?: CustomResourceOptions): ManagedObjectStorageBucket
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        name: Optional[str] = None,
        service_uuid: Optional[str] = None,
        total_objects: Optional[int] = None,
        total_size_bytes: Optional[int] = None) -> ManagedObjectStorageBucket
func GetManagedObjectStorageBucket(ctx *Context, name string, id IDInput, state *ManagedObjectStorageBucketState, opts ...ResourceOption) (*ManagedObjectStorageBucket, error)
public static ManagedObjectStorageBucket Get(string name, Input<string> id, ManagedObjectStorageBucketState? state, CustomResourceOptions? opts = null)
public static ManagedObjectStorageBucket get(String name, Output<String> id, ManagedObjectStorageBucketState state, CustomResourceOptions options)
resources:  _:    type: upcloud:ManagedObjectStorageBucket    get:      id: ${id}
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
resource_name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
The following state arguments are supported:
Name string
Name of the bucket.
ServiceUuid string
Managed Object Storage service UUID.
TotalObjects int
Number of objects stored in the bucket.
TotalSizeBytes int
Total size of objects stored in the bucket.
Name string
Name of the bucket.
ServiceUuid string
Managed Object Storage service UUID.
TotalObjects int
Number of objects stored in the bucket.
TotalSizeBytes int
Total size of objects stored in the bucket.
name String
Name of the bucket.
serviceUuid String
Managed Object Storage service UUID.
totalObjects Integer
Number of objects stored in the bucket.
totalSizeBytes Integer
Total size of objects stored in the bucket.
name string
Name of the bucket.
serviceUuid string
Managed Object Storage service UUID.
totalObjects number
Number of objects stored in the bucket.
totalSizeBytes number
Total size of objects stored in the bucket.
name str
Name of the bucket.
service_uuid str
Managed Object Storage service UUID.
total_objects int
Number of objects stored in the bucket.
total_size_bytes int
Total size of objects stored in the bucket.
name String
Name of the bucket.
serviceUuid String
Managed Object Storage service UUID.
totalObjects Number
Number of objects stored in the bucket.
totalSizeBytes Number
Total size of objects stored in the bucket.

Package Details

Repository
upcloud UpCloudLtd/pulumi-upcloud
License
Apache-2.0
Notes
This Pulumi package is based on the upcloud Terraform Provider.