ionoscloud.S3Object
Explore with Pulumi AI
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as ionoscloud from "@pulumi/ionoscloud";
const exampleS3Bucket = new ionoscloud.S3Bucket("exampleS3Bucket", {objectLockEnabled: true});
const exampleS3Object = new ionoscloud.S3Object("exampleS3Object", {
bucket: exampleS3Bucket.name,
key: "object",
content: "body",
contentType: "text/plain",
cacheControl: "no-cache",
contentDisposition: "attachment",
contentEncoding: "identity",
contentLanguage: "en-GB",
expires: "2024-10-07T12:34:56Z",
websiteRedirect: "https://www.ionos.com",
serverSideEncryption: "AES256",
objectLockMode: "GOVERNANCE",
objectLockRetainUntilDate: "2024-10-07T12:34:56Z",
objectLockLegalHold: "ON",
tags: {
tk: "tv",
},
metadata: {
mk: "mv",
},
forceDestroy: true,
});
// Upload from file
const exampleIndex_s3ObjectS3Object = new ionoscloud.S3Object("exampleIndex/s3ObjectS3Object", {
bucket: exampleS3Bucket.name,
key: "file-object",
source: "path/to/file",
});
import pulumi
import pulumi_ionoscloud as ionoscloud
example_s3_bucket = ionoscloud.S3Bucket("exampleS3Bucket", object_lock_enabled=True)
example_s3_object = ionoscloud.S3Object("exampleS3Object",
bucket=example_s3_bucket.name,
key="object",
content="body",
content_type="text/plain",
cache_control="no-cache",
content_disposition="attachment",
content_encoding="identity",
content_language="en-GB",
expires="2024-10-07T12:34:56Z",
website_redirect="https://www.ionos.com",
server_side_encryption="AES256",
object_lock_mode="GOVERNANCE",
object_lock_retain_until_date="2024-10-07T12:34:56Z",
object_lock_legal_hold="ON",
tags={
"tk": "tv",
},
metadata={
"mk": "mv",
},
force_destroy=True)
# Upload from file
example_index_s3_object_s3_object = ionoscloud.S3Object("exampleIndex/s3ObjectS3Object",
bucket=example_s3_bucket.name,
key="file-object",
source="path/to/file")
package main
import (
"github.com/pulumi/pulumi-terraform-provider/sdks/go/ionoscloud/v6/ionoscloud"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
exampleS3Bucket, err := ionoscloud.NewS3Bucket(ctx, "exampleS3Bucket", &ionoscloud.S3BucketArgs{
ObjectLockEnabled: pulumi.Bool(true),
})
if err != nil {
return err
}
_, err = ionoscloud.NewS3Object(ctx, "exampleS3Object", &ionoscloud.S3ObjectArgs{
Bucket: exampleS3Bucket.Name,
Key: pulumi.String("object"),
Content: pulumi.String("body"),
ContentType: pulumi.String("text/plain"),
CacheControl: pulumi.String("no-cache"),
ContentDisposition: pulumi.String("attachment"),
ContentEncoding: pulumi.String("identity"),
ContentLanguage: pulumi.String("en-GB"),
Expires: pulumi.String("2024-10-07T12:34:56Z"),
WebsiteRedirect: pulumi.String("https://www.ionos.com"),
ServerSideEncryption: pulumi.String("AES256"),
ObjectLockMode: pulumi.String("GOVERNANCE"),
ObjectLockRetainUntilDate: pulumi.String("2024-10-07T12:34:56Z"),
ObjectLockLegalHold: pulumi.String("ON"),
Tags: pulumi.StringMap{
"tk": pulumi.String("tv"),
},
Metadata: pulumi.StringMap{
"mk": pulumi.String("mv"),
},
ForceDestroy: pulumi.Bool(true),
})
if err != nil {
return err
}
// Upload from file
_, err = ionoscloud.NewS3Object(ctx, "exampleIndex/s3ObjectS3Object", &ionoscloud.S3ObjectArgs{
Bucket: exampleS3Bucket.Name,
Key: pulumi.String("file-object"),
Source: pulumi.String("path/to/file"),
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Ionoscloud = Pulumi.Ionoscloud;
return await Deployment.RunAsync(() =>
{
var exampleS3Bucket = new Ionoscloud.S3Bucket("exampleS3Bucket", new()
{
ObjectLockEnabled = true,
});
var exampleS3Object = new Ionoscloud.S3Object("exampleS3Object", new()
{
Bucket = exampleS3Bucket.Name,
Key = "object",
Content = "body",
ContentType = "text/plain",
CacheControl = "no-cache",
ContentDisposition = "attachment",
ContentEncoding = "identity",
ContentLanguage = "en-GB",
Expires = "2024-10-07T12:34:56Z",
WebsiteRedirect = "https://www.ionos.com",
ServerSideEncryption = "AES256",
ObjectLockMode = "GOVERNANCE",
ObjectLockRetainUntilDate = "2024-10-07T12:34:56Z",
ObjectLockLegalHold = "ON",
Tags =
{
{ "tk", "tv" },
},
Metadata =
{
{ "mk", "mv" },
},
ForceDestroy = true,
});
// Upload from file
var exampleIndex_s3ObjectS3Object = new Ionoscloud.S3Object("exampleIndex/s3ObjectS3Object", new()
{
Bucket = exampleS3Bucket.Name,
Key = "file-object",
Source = "path/to/file",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.ionoscloud.S3Bucket;
import com.pulumi.ionoscloud.S3BucketArgs;
import com.pulumi.ionoscloud.S3Object;
import com.pulumi.ionoscloud.S3ObjectArgs;
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 exampleS3Bucket = new S3Bucket("exampleS3Bucket", S3BucketArgs.builder()
.objectLockEnabled(true)
.build());
var exampleS3Object = new S3Object("exampleS3Object", S3ObjectArgs.builder()
.bucket(exampleS3Bucket.name())
.key("object")
.content("body")
.contentType("text/plain")
.cacheControl("no-cache")
.contentDisposition("attachment")
.contentEncoding("identity")
.contentLanguage("en-GB")
.expires("2024-10-07T12:34:56Z")
.websiteRedirect("https://www.ionos.com")
.serverSideEncryption("AES256")
.objectLockMode("GOVERNANCE")
.objectLockRetainUntilDate("2024-10-07T12:34:56Z")
.objectLockLegalHold("ON")
.tags(Map.of("tk", "tv"))
.metadata(Map.of("mk", "mv"))
.forceDestroy(true)
.build());
// Upload from file
var exampleIndex_s3ObjectS3Object = new S3Object("exampleIndex/s3ObjectS3Object", S3ObjectArgs.builder()
.bucket(exampleS3Bucket.name())
.key("file-object")
.source("path/to/file")
.build());
}
}
resources:
exampleS3Bucket:
type: ionoscloud:S3Bucket
properties:
objectLockEnabled: true
exampleS3Object:
type: ionoscloud:S3Object
properties:
bucket: ${exampleS3Bucket.name}
key: object
content: body
contentType: text/plain
cacheControl: no-cache
contentDisposition: attachment
contentEncoding: identity
contentLanguage: en-GB
expires: 2024-10-07T12:34:56Z
websiteRedirect: https://www.ionos.com
serverSideEncryption: AES256
objectLockMode: GOVERNANCE
objectLockRetainUntilDate: 2024-10-07T12:34:56Z
objectLockLegalHold: ON
tags:
tk: tv
metadata:
mk: mv
forceDestroy: true
# Upload from file
exampleIndex/s3ObjectS3Object:
type: ionoscloud:S3Object
properties:
bucket: ${exampleS3Bucket.name}
key: file-object
source: path/to/file
Create S3Object Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new S3Object(name: string, args: S3ObjectArgs, opts?: CustomResourceOptions);
@overload
def S3Object(resource_name: str,
args: S3ObjectArgs,
opts: Optional[ResourceOptions] = None)
@overload
def S3Object(resource_name: str,
opts: Optional[ResourceOptions] = None,
key: Optional[str] = None,
bucket: Optional[str] = None,
object_lock_legal_hold: Optional[str] = None,
metadata: Optional[Mapping[str, str]] = None,
content_encoding: Optional[str] = None,
content_language: Optional[str] = None,
content_type: Optional[str] = None,
expires: Optional[str] = None,
force_destroy: Optional[bool] = None,
object_lock_retain_until_date: Optional[str] = None,
object_lock_mode: Optional[str] = None,
mfa: Optional[str] = None,
content_disposition: Optional[str] = None,
cache_control: Optional[str] = None,
content: Optional[str] = None,
request_payer: Optional[str] = None,
server_side_encryption: Optional[str] = None,
server_side_encryption_context: Optional[str] = None,
server_side_encryption_customer_algorithm: Optional[str] = None,
server_side_encryption_customer_key: Optional[str] = None,
server_side_encryption_customer_key_md5: Optional[str] = None,
source: Optional[str] = None,
storage_class: Optional[str] = None,
tags: Optional[Mapping[str, str]] = None,
website_redirect: Optional[str] = None)
func NewS3Object(ctx *Context, name string, args S3ObjectArgs, opts ...ResourceOption) (*S3Object, error)
public S3Object(string name, S3ObjectArgs args, CustomResourceOptions? opts = null)
public S3Object(String name, S3ObjectArgs args)
public S3Object(String name, S3ObjectArgs args, CustomResourceOptions options)
type: ionoscloud:S3Object
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args S3ObjectArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args S3ObjectArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args S3ObjectArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args S3ObjectArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args S3ObjectArgs
- 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 s3objectResource = new Ionoscloud.S3Object("s3objectResource", new()
{
Key = "string",
Bucket = "string",
ObjectLockLegalHold = "string",
Metadata =
{
{ "string", "string" },
},
ContentEncoding = "string",
ContentLanguage = "string",
ContentType = "string",
Expires = "string",
ForceDestroy = false,
ObjectLockRetainUntilDate = "string",
ObjectLockMode = "string",
Mfa = "string",
ContentDisposition = "string",
CacheControl = "string",
Content = "string",
RequestPayer = "string",
ServerSideEncryption = "string",
ServerSideEncryptionContext = "string",
ServerSideEncryptionCustomerAlgorithm = "string",
ServerSideEncryptionCustomerKey = "string",
ServerSideEncryptionCustomerKeyMd5 = "string",
Source = "string",
StorageClass = "string",
Tags =
{
{ "string", "string" },
},
WebsiteRedirect = "string",
});
example, err := ionoscloud.NewS3Object(ctx, "s3objectResource", &ionoscloud.S3ObjectArgs{
Key: pulumi.String("string"),
Bucket: pulumi.String("string"),
ObjectLockLegalHold: pulumi.String("string"),
Metadata: pulumi.StringMap{
"string": pulumi.String("string"),
},
ContentEncoding: pulumi.String("string"),
ContentLanguage: pulumi.String("string"),
ContentType: pulumi.String("string"),
Expires: pulumi.String("string"),
ForceDestroy: pulumi.Bool(false),
ObjectLockRetainUntilDate: pulumi.String("string"),
ObjectLockMode: pulumi.String("string"),
Mfa: pulumi.String("string"),
ContentDisposition: pulumi.String("string"),
CacheControl: pulumi.String("string"),
Content: pulumi.String("string"),
RequestPayer: pulumi.String("string"),
ServerSideEncryption: pulumi.String("string"),
ServerSideEncryptionContext: pulumi.String("string"),
ServerSideEncryptionCustomerAlgorithm: pulumi.String("string"),
ServerSideEncryptionCustomerKey: pulumi.String("string"),
ServerSideEncryptionCustomerKeyMd5: pulumi.String("string"),
Source: pulumi.String("string"),
StorageClass: pulumi.String("string"),
Tags: pulumi.StringMap{
"string": pulumi.String("string"),
},
WebsiteRedirect: pulumi.String("string"),
})
var s3objectResource = new S3Object("s3objectResource", S3ObjectArgs.builder()
.key("string")
.bucket("string")
.objectLockLegalHold("string")
.metadata(Map.of("string", "string"))
.contentEncoding("string")
.contentLanguage("string")
.contentType("string")
.expires("string")
.forceDestroy(false)
.objectLockRetainUntilDate("string")
.objectLockMode("string")
.mfa("string")
.contentDisposition("string")
.cacheControl("string")
.content("string")
.requestPayer("string")
.serverSideEncryption("string")
.serverSideEncryptionContext("string")
.serverSideEncryptionCustomerAlgorithm("string")
.serverSideEncryptionCustomerKey("string")
.serverSideEncryptionCustomerKeyMd5("string")
.source("string")
.storageClass("string")
.tags(Map.of("string", "string"))
.websiteRedirect("string")
.build());
s3object_resource = ionoscloud.S3Object("s3objectResource",
key="string",
bucket="string",
object_lock_legal_hold="string",
metadata={
"string": "string",
},
content_encoding="string",
content_language="string",
content_type="string",
expires="string",
force_destroy=False,
object_lock_retain_until_date="string",
object_lock_mode="string",
mfa="string",
content_disposition="string",
cache_control="string",
content="string",
request_payer="string",
server_side_encryption="string",
server_side_encryption_context="string",
server_side_encryption_customer_algorithm="string",
server_side_encryption_customer_key="string",
server_side_encryption_customer_key_md5="string",
source="string",
storage_class="string",
tags={
"string": "string",
},
website_redirect="string")
const s3objectResource = new ionoscloud.S3Object("s3objectResource", {
key: "string",
bucket: "string",
objectLockLegalHold: "string",
metadata: {
string: "string",
},
contentEncoding: "string",
contentLanguage: "string",
contentType: "string",
expires: "string",
forceDestroy: false,
objectLockRetainUntilDate: "string",
objectLockMode: "string",
mfa: "string",
contentDisposition: "string",
cacheControl: "string",
content: "string",
requestPayer: "string",
serverSideEncryption: "string",
serverSideEncryptionContext: "string",
serverSideEncryptionCustomerAlgorithm: "string",
serverSideEncryptionCustomerKey: "string",
serverSideEncryptionCustomerKeyMd5: "string",
source: "string",
storageClass: "string",
tags: {
string: "string",
},
websiteRedirect: "string",
});
type: ionoscloud:S3Object
properties:
bucket: string
cacheControl: string
content: string
contentDisposition: string
contentEncoding: string
contentLanguage: string
contentType: string
expires: string
forceDestroy: false
key: string
metadata:
string: string
mfa: string
objectLockLegalHold: string
objectLockMode: string
objectLockRetainUntilDate: string
requestPayer: string
serverSideEncryption: string
serverSideEncryptionContext: string
serverSideEncryptionCustomerAlgorithm: string
serverSideEncryptionCustomerKey: string
serverSideEncryptionCustomerKeyMd5: string
source: string
storageClass: string
tags:
string: string
websiteRedirect: string
S3Object 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 S3Object resource accepts the following input properties:
- Bucket string
- [string] The name of the bucket where the object will be stored. Must be between 3 and 63 characters.
- Key string
- [string] The key of the object. Must be at least 1 character long.
- Cache
Control string - [string] Specifies caching behavior along the request/reply chain.
- Content string
- [string] Inline content of the object.
- Content
Disposition string - [string] Specifies presentational information for the object.
- Content
Encoding string - [string] Specifies what content encodings have been applied to the object.
- Content
Language string - [string] The natural language or languages of the intended audience for the object.
- Content
Type string - [string] A standard MIME type describing the format of the contents.
- Expires string
- [string] The date and time at which the object is no longer cacheable.
- Force
Destroy bool - [bool] If true, the object will be destroyed if versioning is enabled then all versions will be destroyed. Default is
false
. - Metadata Dictionary<string, string>
- [map] A map of metadata to store with the object in IONOS Object Storage. Metadata keys must be lowercase alphanumeric characters.
- Mfa string
- [string]The concatenation of the authentication device's serial number, a space, and the value displayed on your authentication device.
- Object
Lock stringLegal Hold - [string] Indicates whether a legal hold is in effect for the object. Valid values are
ON
andOFF
. - Object
Lock stringMode - [string] The object lock mode that you want to apply to the object. Valid values are
GOVERNANCE
andCOMPLIANCE
. - Object
Lock stringRetain Until Date - [string] The date and time when the object lock retention expires.Must be in RFC3999 format
- Request
Payer string - [string] Confirms that the requester knows that they will be charged for the request.
- Server
Side stringEncryption - [string] The server-side encryption algorithm used when storing this object in IONOS Object Storage. Valid value is AES256.
- Server
Side stringEncryption Context - [string] Specifies the IONOS Object Storage Encryption Context for object encryption.
- Server
Side stringEncryption Customer Algorithm - [string] Specifies the algorithm to use for encrypting the object. Valid value is AES256.
- Server
Side stringEncryption Customer Key - [string] Specifies the 256-bit, base64-encoded encryption key to use to encrypt and decrypt your data.
- Server
Side stringEncryption Customer Key Md5 - [string] Specifies the 128-bit MD5 digest of the encryption key.
- Source string
- [string] The path to the file to upload.
- Storage
Class string - [string] The storage class of the object. Valid value is STANDARD. Default is STANDARD.
- Dictionary<string, string>
- [map] The tag-set for the object.
- Website
Redirect string - [string] Redirects requests for this object to another object in the same bucket or to an external URL.
- Bucket string
- [string] The name of the bucket where the object will be stored. Must be between 3 and 63 characters.
- Key string
- [string] The key of the object. Must be at least 1 character long.
- Cache
Control string - [string] Specifies caching behavior along the request/reply chain.
- Content string
- [string] Inline content of the object.
- Content
Disposition string - [string] Specifies presentational information for the object.
- Content
Encoding string - [string] Specifies what content encodings have been applied to the object.
- Content
Language string - [string] The natural language or languages of the intended audience for the object.
- Content
Type string - [string] A standard MIME type describing the format of the contents.
- Expires string
- [string] The date and time at which the object is no longer cacheable.
- Force
Destroy bool - [bool] If true, the object will be destroyed if versioning is enabled then all versions will be destroyed. Default is
false
. - Metadata map[string]string
- [map] A map of metadata to store with the object in IONOS Object Storage. Metadata keys must be lowercase alphanumeric characters.
- Mfa string
- [string]The concatenation of the authentication device's serial number, a space, and the value displayed on your authentication device.
- Object
Lock stringLegal Hold - [string] Indicates whether a legal hold is in effect for the object. Valid values are
ON
andOFF
. - Object
Lock stringMode - [string] The object lock mode that you want to apply to the object. Valid values are
GOVERNANCE
andCOMPLIANCE
. - Object
Lock stringRetain Until Date - [string] The date and time when the object lock retention expires.Must be in RFC3999 format
- Request
Payer string - [string] Confirms that the requester knows that they will be charged for the request.
- Server
Side stringEncryption - [string] The server-side encryption algorithm used when storing this object in IONOS Object Storage. Valid value is AES256.
- Server
Side stringEncryption Context - [string] Specifies the IONOS Object Storage Encryption Context for object encryption.
- Server
Side stringEncryption Customer Algorithm - [string] Specifies the algorithm to use for encrypting the object. Valid value is AES256.
- Server
Side stringEncryption Customer Key - [string] Specifies the 256-bit, base64-encoded encryption key to use to encrypt and decrypt your data.
- Server
Side stringEncryption Customer Key Md5 - [string] Specifies the 128-bit MD5 digest of the encryption key.
- Source string
- [string] The path to the file to upload.
- Storage
Class string - [string] The storage class of the object. Valid value is STANDARD. Default is STANDARD.
- map[string]string
- [map] The tag-set for the object.
- Website
Redirect string - [string] Redirects requests for this object to another object in the same bucket or to an external URL.
- bucket String
- [string] The name of the bucket where the object will be stored. Must be between 3 and 63 characters.
- key String
- [string] The key of the object. Must be at least 1 character long.
- cache
Control String - [string] Specifies caching behavior along the request/reply chain.
- content String
- [string] Inline content of the object.
- content
Disposition String - [string] Specifies presentational information for the object.
- content
Encoding String - [string] Specifies what content encodings have been applied to the object.
- content
Language String - [string] The natural language or languages of the intended audience for the object.
- content
Type String - [string] A standard MIME type describing the format of the contents.
- expires String
- [string] The date and time at which the object is no longer cacheable.
- force
Destroy Boolean - [bool] If true, the object will be destroyed if versioning is enabled then all versions will be destroyed. Default is
false
. - metadata Map<String,String>
- [map] A map of metadata to store with the object in IONOS Object Storage. Metadata keys must be lowercase alphanumeric characters.
- mfa String
- [string]The concatenation of the authentication device's serial number, a space, and the value displayed on your authentication device.
- object
Lock StringLegal Hold - [string] Indicates whether a legal hold is in effect for the object. Valid values are
ON
andOFF
. - object
Lock StringMode - [string] The object lock mode that you want to apply to the object. Valid values are
GOVERNANCE
andCOMPLIANCE
. - object
Lock StringRetain Until Date - [string] The date and time when the object lock retention expires.Must be in RFC3999 format
- request
Payer String - [string] Confirms that the requester knows that they will be charged for the request.
- server
Side StringEncryption - [string] The server-side encryption algorithm used when storing this object in IONOS Object Storage. Valid value is AES256.
- server
Side StringEncryption Context - [string] Specifies the IONOS Object Storage Encryption Context for object encryption.
- server
Side StringEncryption Customer Algorithm - [string] Specifies the algorithm to use for encrypting the object. Valid value is AES256.
- server
Side StringEncryption Customer Key - [string] Specifies the 256-bit, base64-encoded encryption key to use to encrypt and decrypt your data.
- server
Side StringEncryption Customer Key Md5 - [string] Specifies the 128-bit MD5 digest of the encryption key.
- source String
- [string] The path to the file to upload.
- storage
Class String - [string] The storage class of the object. Valid value is STANDARD. Default is STANDARD.
- Map<String,String>
- [map] The tag-set for the object.
- website
Redirect String - [string] Redirects requests for this object to another object in the same bucket or to an external URL.
- bucket string
- [string] The name of the bucket where the object will be stored. Must be between 3 and 63 characters.
- key string
- [string] The key of the object. Must be at least 1 character long.
- cache
Control string - [string] Specifies caching behavior along the request/reply chain.
- content string
- [string] Inline content of the object.
- content
Disposition string - [string] Specifies presentational information for the object.
- content
Encoding string - [string] Specifies what content encodings have been applied to the object.
- content
Language string - [string] The natural language or languages of the intended audience for the object.
- content
Type string - [string] A standard MIME type describing the format of the contents.
- expires string
- [string] The date and time at which the object is no longer cacheable.
- force
Destroy boolean - [bool] If true, the object will be destroyed if versioning is enabled then all versions will be destroyed. Default is
false
. - metadata {[key: string]: string}
- [map] A map of metadata to store with the object in IONOS Object Storage. Metadata keys must be lowercase alphanumeric characters.
- mfa string
- [string]The concatenation of the authentication device's serial number, a space, and the value displayed on your authentication device.
- object
Lock stringLegal Hold - [string] Indicates whether a legal hold is in effect for the object. Valid values are
ON
andOFF
. - object
Lock stringMode - [string] The object lock mode that you want to apply to the object. Valid values are
GOVERNANCE
andCOMPLIANCE
. - object
Lock stringRetain Until Date - [string] The date and time when the object lock retention expires.Must be in RFC3999 format
- request
Payer string - [string] Confirms that the requester knows that they will be charged for the request.
- server
Side stringEncryption - [string] The server-side encryption algorithm used when storing this object in IONOS Object Storage. Valid value is AES256.
- server
Side stringEncryption Context - [string] Specifies the IONOS Object Storage Encryption Context for object encryption.
- server
Side stringEncryption Customer Algorithm - [string] Specifies the algorithm to use for encrypting the object. Valid value is AES256.
- server
Side stringEncryption Customer Key - [string] Specifies the 256-bit, base64-encoded encryption key to use to encrypt and decrypt your data.
- server
Side stringEncryption Customer Key Md5 - [string] Specifies the 128-bit MD5 digest of the encryption key.
- source string
- [string] The path to the file to upload.
- storage
Class string - [string] The storage class of the object. Valid value is STANDARD. Default is STANDARD.
- {[key: string]: string}
- [map] The tag-set for the object.
- website
Redirect string - [string] Redirects requests for this object to another object in the same bucket or to an external URL.
- bucket str
- [string] The name of the bucket where the object will be stored. Must be between 3 and 63 characters.
- key str
- [string] The key of the object. Must be at least 1 character long.
- cache_
control str - [string] Specifies caching behavior along the request/reply chain.
- content str
- [string] Inline content of the object.
- content_
disposition str - [string] Specifies presentational information for the object.
- content_
encoding str - [string] Specifies what content encodings have been applied to the object.
- content_
language str - [string] The natural language or languages of the intended audience for the object.
- content_
type str - [string] A standard MIME type describing the format of the contents.
- expires str
- [string] The date and time at which the object is no longer cacheable.
- force_
destroy bool - [bool] If true, the object will be destroyed if versioning is enabled then all versions will be destroyed. Default is
false
. - metadata Mapping[str, str]
- [map] A map of metadata to store with the object in IONOS Object Storage. Metadata keys must be lowercase alphanumeric characters.
- mfa str
- [string]The concatenation of the authentication device's serial number, a space, and the value displayed on your authentication device.
- object_
lock_ strlegal_ hold - [string] Indicates whether a legal hold is in effect for the object. Valid values are
ON
andOFF
. - object_
lock_ strmode - [string] The object lock mode that you want to apply to the object. Valid values are
GOVERNANCE
andCOMPLIANCE
. - object_
lock_ strretain_ until_ date - [string] The date and time when the object lock retention expires.Must be in RFC3999 format
- request_
payer str - [string] Confirms that the requester knows that they will be charged for the request.
- server_
side_ strencryption - [string] The server-side encryption algorithm used when storing this object in IONOS Object Storage. Valid value is AES256.
- server_
side_ strencryption_ context - [string] Specifies the IONOS Object Storage Encryption Context for object encryption.
- server_
side_ strencryption_ customer_ algorithm - [string] Specifies the algorithm to use for encrypting the object. Valid value is AES256.
- server_
side_ strencryption_ customer_ key - [string] Specifies the 256-bit, base64-encoded encryption key to use to encrypt and decrypt your data.
- server_
side_ strencryption_ customer_ key_ md5 - [string] Specifies the 128-bit MD5 digest of the encryption key.
- source str
- [string] The path to the file to upload.
- storage_
class str - [string] The storage class of the object. Valid value is STANDARD. Default is STANDARD.
- Mapping[str, str]
- [map] The tag-set for the object.
- website_
redirect str - [string] Redirects requests for this object to another object in the same bucket or to an external URL.
- bucket String
- [string] The name of the bucket where the object will be stored. Must be between 3 and 63 characters.
- key String
- [string] The key of the object. Must be at least 1 character long.
- cache
Control String - [string] Specifies caching behavior along the request/reply chain.
- content String
- [string] Inline content of the object.
- content
Disposition String - [string] Specifies presentational information for the object.
- content
Encoding String - [string] Specifies what content encodings have been applied to the object.
- content
Language String - [string] The natural language or languages of the intended audience for the object.
- content
Type String - [string] A standard MIME type describing the format of the contents.
- expires String
- [string] The date and time at which the object is no longer cacheable.
- force
Destroy Boolean - [bool] If true, the object will be destroyed if versioning is enabled then all versions will be destroyed. Default is
false
. - metadata Map<String>
- [map] A map of metadata to store with the object in IONOS Object Storage. Metadata keys must be lowercase alphanumeric characters.
- mfa String
- [string]The concatenation of the authentication device's serial number, a space, and the value displayed on your authentication device.
- object
Lock StringLegal Hold - [string] Indicates whether a legal hold is in effect for the object. Valid values are
ON
andOFF
. - object
Lock StringMode - [string] The object lock mode that you want to apply to the object. Valid values are
GOVERNANCE
andCOMPLIANCE
. - object
Lock StringRetain Until Date - [string] The date and time when the object lock retention expires.Must be in RFC3999 format
- request
Payer String - [string] Confirms that the requester knows that they will be charged for the request.
- server
Side StringEncryption - [string] The server-side encryption algorithm used when storing this object in IONOS Object Storage. Valid value is AES256.
- server
Side StringEncryption Context - [string] Specifies the IONOS Object Storage Encryption Context for object encryption.
- server
Side StringEncryption Customer Algorithm - [string] Specifies the algorithm to use for encrypting the object. Valid value is AES256.
- server
Side StringEncryption Customer Key - [string] Specifies the 256-bit, base64-encoded encryption key to use to encrypt and decrypt your data.
- server
Side StringEncryption Customer Key Md5 - [string] Specifies the 128-bit MD5 digest of the encryption key.
- source String
- [string] The path to the file to upload.
- storage
Class String - [string] The storage class of the object. Valid value is STANDARD. Default is STANDARD.
- Map<String>
- [map] The tag-set for the object.
- website
Redirect String - [string] Redirects requests for this object to another object in the same bucket or to an external URL.
Outputs
All input properties are implicitly available as output properties. Additionally, the S3Object resource produces the following output properties:
- etag str
- [string] An entity tag (ETag) is an opaque identifier assigned by a web server to a specific version of a resource found at a URL.
- id str
- The provider-assigned unique ID for this managed resource.
- version_
id str - [string] The version of the object.
Look up Existing S3Object Resource
Get an existing S3Object 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?: S3ObjectState, opts?: CustomResourceOptions): S3Object
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
bucket: Optional[str] = None,
cache_control: Optional[str] = None,
content: Optional[str] = None,
content_disposition: Optional[str] = None,
content_encoding: Optional[str] = None,
content_language: Optional[str] = None,
content_type: Optional[str] = None,
etag: Optional[str] = None,
expires: Optional[str] = None,
force_destroy: Optional[bool] = None,
key: Optional[str] = None,
metadata: Optional[Mapping[str, str]] = None,
mfa: Optional[str] = None,
object_lock_legal_hold: Optional[str] = None,
object_lock_mode: Optional[str] = None,
object_lock_retain_until_date: Optional[str] = None,
request_payer: Optional[str] = None,
server_side_encryption: Optional[str] = None,
server_side_encryption_context: Optional[str] = None,
server_side_encryption_customer_algorithm: Optional[str] = None,
server_side_encryption_customer_key: Optional[str] = None,
server_side_encryption_customer_key_md5: Optional[str] = None,
source: Optional[str] = None,
storage_class: Optional[str] = None,
tags: Optional[Mapping[str, str]] = None,
version_id: Optional[str] = None,
website_redirect: Optional[str] = None) -> S3Object
func GetS3Object(ctx *Context, name string, id IDInput, state *S3ObjectState, opts ...ResourceOption) (*S3Object, error)
public static S3Object Get(string name, Input<string> id, S3ObjectState? state, CustomResourceOptions? opts = null)
public static S3Object get(String name, Output<String> id, S3ObjectState state, CustomResourceOptions options)
resources: _: type: ionoscloud:S3Object get: id: ${id}
- name
- The unique name of the resulting resource.
- id
- 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
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- 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
- The unique name of the resulting resource.
- id
- 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
- The unique name of the resulting resource.
- id
- 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.
- Bucket string
- [string] The name of the bucket where the object will be stored. Must be between 3 and 63 characters.
- Cache
Control string - [string] Specifies caching behavior along the request/reply chain.
- Content string
- [string] Inline content of the object.
- Content
Disposition string - [string] Specifies presentational information for the object.
- Content
Encoding string - [string] Specifies what content encodings have been applied to the object.
- Content
Language string - [string] The natural language or languages of the intended audience for the object.
- Content
Type string - [string] A standard MIME type describing the format of the contents.
- Etag string
- [string] An entity tag (ETag) is an opaque identifier assigned by a web server to a specific version of a resource found at a URL.
- Expires string
- [string] The date and time at which the object is no longer cacheable.
- Force
Destroy bool - [bool] If true, the object will be destroyed if versioning is enabled then all versions will be destroyed. Default is
false
. - Key string
- [string] The key of the object. Must be at least 1 character long.
- Metadata Dictionary<string, string>
- [map] A map of metadata to store with the object in IONOS Object Storage. Metadata keys must be lowercase alphanumeric characters.
- Mfa string
- [string]The concatenation of the authentication device's serial number, a space, and the value displayed on your authentication device.
- Object
Lock stringLegal Hold - [string] Indicates whether a legal hold is in effect for the object. Valid values are
ON
andOFF
. - Object
Lock stringMode - [string] The object lock mode that you want to apply to the object. Valid values are
GOVERNANCE
andCOMPLIANCE
. - Object
Lock stringRetain Until Date - [string] The date and time when the object lock retention expires.Must be in RFC3999 format
- Request
Payer string - [string] Confirms that the requester knows that they will be charged for the request.
- Server
Side stringEncryption - [string] The server-side encryption algorithm used when storing this object in IONOS Object Storage. Valid value is AES256.
- Server
Side stringEncryption Context - [string] Specifies the IONOS Object Storage Encryption Context for object encryption.
- Server
Side stringEncryption Customer Algorithm - [string] Specifies the algorithm to use for encrypting the object. Valid value is AES256.
- Server
Side stringEncryption Customer Key - [string] Specifies the 256-bit, base64-encoded encryption key to use to encrypt and decrypt your data.
- Server
Side stringEncryption Customer Key Md5 - [string] Specifies the 128-bit MD5 digest of the encryption key.
- Source string
- [string] The path to the file to upload.
- Storage
Class string - [string] The storage class of the object. Valid value is STANDARD. Default is STANDARD.
- Dictionary<string, string>
- [map] The tag-set for the object.
- Version
Id string - [string] The version of the object.
- Website
Redirect string - [string] Redirects requests for this object to another object in the same bucket or to an external URL.
- Bucket string
- [string] The name of the bucket where the object will be stored. Must be between 3 and 63 characters.
- Cache
Control string - [string] Specifies caching behavior along the request/reply chain.
- Content string
- [string] Inline content of the object.
- Content
Disposition string - [string] Specifies presentational information for the object.
- Content
Encoding string - [string] Specifies what content encodings have been applied to the object.
- Content
Language string - [string] The natural language or languages of the intended audience for the object.
- Content
Type string - [string] A standard MIME type describing the format of the contents.
- Etag string
- [string] An entity tag (ETag) is an opaque identifier assigned by a web server to a specific version of a resource found at a URL.
- Expires string
- [string] The date and time at which the object is no longer cacheable.
- Force
Destroy bool - [bool] If true, the object will be destroyed if versioning is enabled then all versions will be destroyed. Default is
false
. - Key string
- [string] The key of the object. Must be at least 1 character long.
- Metadata map[string]string
- [map] A map of metadata to store with the object in IONOS Object Storage. Metadata keys must be lowercase alphanumeric characters.
- Mfa string
- [string]The concatenation of the authentication device's serial number, a space, and the value displayed on your authentication device.
- Object
Lock stringLegal Hold - [string] Indicates whether a legal hold is in effect for the object. Valid values are
ON
andOFF
. - Object
Lock stringMode - [string] The object lock mode that you want to apply to the object. Valid values are
GOVERNANCE
andCOMPLIANCE
. - Object
Lock stringRetain Until Date - [string] The date and time when the object lock retention expires.Must be in RFC3999 format
- Request
Payer string - [string] Confirms that the requester knows that they will be charged for the request.
- Server
Side stringEncryption - [string] The server-side encryption algorithm used when storing this object in IONOS Object Storage. Valid value is AES256.
- Server
Side stringEncryption Context - [string] Specifies the IONOS Object Storage Encryption Context for object encryption.
- Server
Side stringEncryption Customer Algorithm - [string] Specifies the algorithm to use for encrypting the object. Valid value is AES256.
- Server
Side stringEncryption Customer Key - [string] Specifies the 256-bit, base64-encoded encryption key to use to encrypt and decrypt your data.
- Server
Side stringEncryption Customer Key Md5 - [string] Specifies the 128-bit MD5 digest of the encryption key.
- Source string
- [string] The path to the file to upload.
- Storage
Class string - [string] The storage class of the object. Valid value is STANDARD. Default is STANDARD.
- map[string]string
- [map] The tag-set for the object.
- Version
Id string - [string] The version of the object.
- Website
Redirect string - [string] Redirects requests for this object to another object in the same bucket or to an external URL.
- bucket String
- [string] The name of the bucket where the object will be stored. Must be between 3 and 63 characters.
- cache
Control String - [string] Specifies caching behavior along the request/reply chain.
- content String
- [string] Inline content of the object.
- content
Disposition String - [string] Specifies presentational information for the object.
- content
Encoding String - [string] Specifies what content encodings have been applied to the object.
- content
Language String - [string] The natural language or languages of the intended audience for the object.
- content
Type String - [string] A standard MIME type describing the format of the contents.
- etag String
- [string] An entity tag (ETag) is an opaque identifier assigned by a web server to a specific version of a resource found at a URL.
- expires String
- [string] The date and time at which the object is no longer cacheable.
- force
Destroy Boolean - [bool] If true, the object will be destroyed if versioning is enabled then all versions will be destroyed. Default is
false
. - key String
- [string] The key of the object. Must be at least 1 character long.
- metadata Map<String,String>
- [map] A map of metadata to store with the object in IONOS Object Storage. Metadata keys must be lowercase alphanumeric characters.
- mfa String
- [string]The concatenation of the authentication device's serial number, a space, and the value displayed on your authentication device.
- object
Lock StringLegal Hold - [string] Indicates whether a legal hold is in effect for the object. Valid values are
ON
andOFF
. - object
Lock StringMode - [string] The object lock mode that you want to apply to the object. Valid values are
GOVERNANCE
andCOMPLIANCE
. - object
Lock StringRetain Until Date - [string] The date and time when the object lock retention expires.Must be in RFC3999 format
- request
Payer String - [string] Confirms that the requester knows that they will be charged for the request.
- server
Side StringEncryption - [string] The server-side encryption algorithm used when storing this object in IONOS Object Storage. Valid value is AES256.
- server
Side StringEncryption Context - [string] Specifies the IONOS Object Storage Encryption Context for object encryption.
- server
Side StringEncryption Customer Algorithm - [string] Specifies the algorithm to use for encrypting the object. Valid value is AES256.
- server
Side StringEncryption Customer Key - [string] Specifies the 256-bit, base64-encoded encryption key to use to encrypt and decrypt your data.
- server
Side StringEncryption Customer Key Md5 - [string] Specifies the 128-bit MD5 digest of the encryption key.
- source String
- [string] The path to the file to upload.
- storage
Class String - [string] The storage class of the object. Valid value is STANDARD. Default is STANDARD.
- Map<String,String>
- [map] The tag-set for the object.
- version
Id String - [string] The version of the object.
- website
Redirect String - [string] Redirects requests for this object to another object in the same bucket or to an external URL.
- bucket string
- [string] The name of the bucket where the object will be stored. Must be between 3 and 63 characters.
- cache
Control string - [string] Specifies caching behavior along the request/reply chain.
- content string
- [string] Inline content of the object.
- content
Disposition string - [string] Specifies presentational information for the object.
- content
Encoding string - [string] Specifies what content encodings have been applied to the object.
- content
Language string - [string] The natural language or languages of the intended audience for the object.
- content
Type string - [string] A standard MIME type describing the format of the contents.
- etag string
- [string] An entity tag (ETag) is an opaque identifier assigned by a web server to a specific version of a resource found at a URL.
- expires string
- [string] The date and time at which the object is no longer cacheable.
- force
Destroy boolean - [bool] If true, the object will be destroyed if versioning is enabled then all versions will be destroyed. Default is
false
. - key string
- [string] The key of the object. Must be at least 1 character long.
- metadata {[key: string]: string}
- [map] A map of metadata to store with the object in IONOS Object Storage. Metadata keys must be lowercase alphanumeric characters.
- mfa string
- [string]The concatenation of the authentication device's serial number, a space, and the value displayed on your authentication device.
- object
Lock stringLegal Hold - [string] Indicates whether a legal hold is in effect for the object. Valid values are
ON
andOFF
. - object
Lock stringMode - [string] The object lock mode that you want to apply to the object. Valid values are
GOVERNANCE
andCOMPLIANCE
. - object
Lock stringRetain Until Date - [string] The date and time when the object lock retention expires.Must be in RFC3999 format
- request
Payer string - [string] Confirms that the requester knows that they will be charged for the request.
- server
Side stringEncryption - [string] The server-side encryption algorithm used when storing this object in IONOS Object Storage. Valid value is AES256.
- server
Side stringEncryption Context - [string] Specifies the IONOS Object Storage Encryption Context for object encryption.
- server
Side stringEncryption Customer Algorithm - [string] Specifies the algorithm to use for encrypting the object. Valid value is AES256.
- server
Side stringEncryption Customer Key - [string] Specifies the 256-bit, base64-encoded encryption key to use to encrypt and decrypt your data.
- server
Side stringEncryption Customer Key Md5 - [string] Specifies the 128-bit MD5 digest of the encryption key.
- source string
- [string] The path to the file to upload.
- storage
Class string - [string] The storage class of the object. Valid value is STANDARD. Default is STANDARD.
- {[key: string]: string}
- [map] The tag-set for the object.
- version
Id string - [string] The version of the object.
- website
Redirect string - [string] Redirects requests for this object to another object in the same bucket or to an external URL.
- bucket str
- [string] The name of the bucket where the object will be stored. Must be between 3 and 63 characters.
- cache_
control str - [string] Specifies caching behavior along the request/reply chain.
- content str
- [string] Inline content of the object.
- content_
disposition str - [string] Specifies presentational information for the object.
- content_
encoding str - [string] Specifies what content encodings have been applied to the object.
- content_
language str - [string] The natural language or languages of the intended audience for the object.
- content_
type str - [string] A standard MIME type describing the format of the contents.
- etag str
- [string] An entity tag (ETag) is an opaque identifier assigned by a web server to a specific version of a resource found at a URL.
- expires str
- [string] The date and time at which the object is no longer cacheable.
- force_
destroy bool - [bool] If true, the object will be destroyed if versioning is enabled then all versions will be destroyed. Default is
false
. - key str
- [string] The key of the object. Must be at least 1 character long.
- metadata Mapping[str, str]
- [map] A map of metadata to store with the object in IONOS Object Storage. Metadata keys must be lowercase alphanumeric characters.
- mfa str
- [string]The concatenation of the authentication device's serial number, a space, and the value displayed on your authentication device.
- object_
lock_ strlegal_ hold - [string] Indicates whether a legal hold is in effect for the object. Valid values are
ON
andOFF
. - object_
lock_ strmode - [string] The object lock mode that you want to apply to the object. Valid values are
GOVERNANCE
andCOMPLIANCE
. - object_
lock_ strretain_ until_ date - [string] The date and time when the object lock retention expires.Must be in RFC3999 format
- request_
payer str - [string] Confirms that the requester knows that they will be charged for the request.
- server_
side_ strencryption - [string] The server-side encryption algorithm used when storing this object in IONOS Object Storage. Valid value is AES256.
- server_
side_ strencryption_ context - [string] Specifies the IONOS Object Storage Encryption Context for object encryption.
- server_
side_ strencryption_ customer_ algorithm - [string] Specifies the algorithm to use for encrypting the object. Valid value is AES256.
- server_
side_ strencryption_ customer_ key - [string] Specifies the 256-bit, base64-encoded encryption key to use to encrypt and decrypt your data.
- server_
side_ strencryption_ customer_ key_ md5 - [string] Specifies the 128-bit MD5 digest of the encryption key.
- source str
- [string] The path to the file to upload.
- storage_
class str - [string] The storage class of the object. Valid value is STANDARD. Default is STANDARD.
- Mapping[str, str]
- [map] The tag-set for the object.
- version_
id str - [string] The version of the object.
- website_
redirect str - [string] Redirects requests for this object to another object in the same bucket or to an external URL.
- bucket String
- [string] The name of the bucket where the object will be stored. Must be between 3 and 63 characters.
- cache
Control String - [string] Specifies caching behavior along the request/reply chain.
- content String
- [string] Inline content of the object.
- content
Disposition String - [string] Specifies presentational information for the object.
- content
Encoding String - [string] Specifies what content encodings have been applied to the object.
- content
Language String - [string] The natural language or languages of the intended audience for the object.
- content
Type String - [string] A standard MIME type describing the format of the contents.
- etag String
- [string] An entity tag (ETag) is an opaque identifier assigned by a web server to a specific version of a resource found at a URL.
- expires String
- [string] The date and time at which the object is no longer cacheable.
- force
Destroy Boolean - [bool] If true, the object will be destroyed if versioning is enabled then all versions will be destroyed. Default is
false
. - key String
- [string] The key of the object. Must be at least 1 character long.
- metadata Map<String>
- [map] A map of metadata to store with the object in IONOS Object Storage. Metadata keys must be lowercase alphanumeric characters.
- mfa String
- [string]The concatenation of the authentication device's serial number, a space, and the value displayed on your authentication device.
- object
Lock StringLegal Hold - [string] Indicates whether a legal hold is in effect for the object. Valid values are
ON
andOFF
. - object
Lock StringMode - [string] The object lock mode that you want to apply to the object. Valid values are
GOVERNANCE
andCOMPLIANCE
. - object
Lock StringRetain Until Date - [string] The date and time when the object lock retention expires.Must be in RFC3999 format
- request
Payer String - [string] Confirms that the requester knows that they will be charged for the request.
- server
Side StringEncryption - [string] The server-side encryption algorithm used when storing this object in IONOS Object Storage. Valid value is AES256.
- server
Side StringEncryption Context - [string] Specifies the IONOS Object Storage Encryption Context for object encryption.
- server
Side StringEncryption Customer Algorithm - [string] Specifies the algorithm to use for encrypting the object. Valid value is AES256.
- server
Side StringEncryption Customer Key - [string] Specifies the 256-bit, base64-encoded encryption key to use to encrypt and decrypt your data.
- server
Side StringEncryption Customer Key Md5 - [string] Specifies the 128-bit MD5 digest of the encryption key.
- source String
- [string] The path to the file to upload.
- storage
Class String - [string] The storage class of the object. Valid value is STANDARD. Default is STANDARD.
- Map<String>
- [map] The tag-set for the object.
- version
Id String - [string] The version of the object.
- website
Redirect String - [string] Redirects requests for this object to another object in the same bucket or to an external URL.
Import
Resource Object can be imported using the bucket name
and object key
$ pulumi import ionoscloud:index/s3Object:S3Object example example/object
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- ionoscloud ionos-cloud/terraform-provider-ionoscloud
- License
- Notes
- This Pulumi package is based on the
ionoscloud
Terraform Provider.