TablePolicy class

Resource for managing an Amazon S3 Tables Table Policy.

Example Usage

Basic Usage

pulumi {
  required_providers {
    aws = {
      source = "pulumi/aws"
    }
  }
}

data "aws_iam_getpolicydocument" "example" {
  statements {
  }
}

resource "aws_s3tables_tablepolicy" "example" {
  resource_policy  = data.aws_iam_getpolicydocument.example.json
  name             = test.name
  namespace        = test.namespace
  table_bucket_arn = test.tableBucketArn
}
resource "aws_s3tables_table" "example" {
  name             = "example_table"
  namespace        = aws_s3tables_namespace.example
  table_bucket_arn = aws_s3tables_namespace.example.table_bucket_arn
  format           = "ICEBERG"
}
resource "aws_s3tables_namespace" "example" {
  namespace        = ["example-namespace"]
  table_bucket_arn = aws_s3tables_tablebucket.example.arn
}
resource "aws_s3tables_tablebucket" "example" {
  name = "example-bucket"
}
resources:
  exampleTablePolicy:
    type: aws:s3tables:TablePolicy
    name: example
    properties:
      resourcePolicy: ${example.json}
      name: ${test.name}
      namespace: ${test.namespace}
      tableBucketArn: ${test.tableBucketArn}
  exampleTable:
    type: aws:s3tables:Table
    name: example
    properties:
      name: example_table
      namespace: ${exampleNamespace}
      tableBucketArn: ${exampleNamespace.tableBucketArn}
      format: ICEBERG
  exampleNamespace:
    type: aws:s3tables:Namespace
    name: example
    properties:
      namespace:
        - example-namespace
      tableBucketArn: ${exampleTableBucket.arn}
  exampleTableBucket:
    type: aws:s3tables:TableBucket
    name: example
    properties:
      name: example-bucket
variables:
  example:
    fn::invoke:
      function: aws:iam:getPolicyDocument
      arguments:
        statements:
          - {}

Import

Using pulumi import, import S3 Tables Table Policy using the tableBucketArn, the value of namespace, and the value of name, separated by a semicolon (;). For example:

$ pulumi import aws:s3tables/tablePolicy:TablePolicy example 'arn:aws:s3tables:us-west-2:123456789012:bucket/example-bucket;example-namespace;example-table'

Constructors

TablePolicy(String name, {TablePolicyArgs? args, CustomResourceOptions? options})
Creates a new TablePolicy. name The Pulumi resource name. args Arguments used to configure this TablePolicy. The set of arguments for TablePolicy. options Resource options controlling this resource's behavior.
TablePolicy.reference(String urn)
Creates a typed reference to an existing TablePolicy resource.

Properties

childResources → Set<Resource>
finalinherited
completionSources ↔ Map<String, IOutputCompletionSource>
latefinalinherited
hashCode → int
The hash code for this object.
no setterinherited
id ↔ Output<String>
getter/setter pairinherited
isCustom → bool
Returns whether this resource is provider-managed.
no setterinherited
isProtected → bool
Returns whether this resource is protected from deletion.
no setterinherited
isRemote → bool
Whether this resource is registered as remote.
no setterinherited
isResourceReference → bool
Whether this instance represents a resource value returned over RPC.
finalinherited
name ↔ Output<String>
Name of the table. Must be between 1 and 255 characters in length. Can consist of lowercase letters, numbers, and underscores, and must begin and end with a lowercase letter or number.
latefinal
namespace ↔ Output<String>
Name of the namespace for this table. Must be between 1 and 255 characters in length. Can consist of lowercase letters, numbers, and underscores, and must begin and end with a lowercase letter or number.
latefinal
region ↔ Output<String>
Region where this resource will be managed. Defaults to the Region set in the provider configuration.
latefinal
resourcePolicy ↔ Output<String>
Amazon Web Services resource-based policy document in JSON format.
latefinal
resourceTransforms → List<ResourceTransform>
Inherited/explicit async transforms.
no setterinherited
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
tableBucketArn ↔ Output<String>
ARN referencing the Table Bucket that contains this Namespace.
latefinal
transformations → List<ResourceTransformation>
Inherited/explicit legacy transformations.
no setterinherited
urn ↔ Output<String>
latefinalinherited

Methods

failId(Object error) → void
Completes this resource ID with an error when registration fails.
inherited
failOutputs(Object error) → void
Completes all output properties with error.
inherited
failUrn(Object error) → void
Completes this resource URN with an error when registration fails.
inherited
getProvider(String moduleMember) → ProviderResource?
Returns provider for moduleMember's package, if configured.
inherited
getResourceName() → String
Returns this resource's logical name.
inherited
getResourceType() → String
Returns this resource's Pulumi type token.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
registerOutput<T>(String propertyName, {Object? decoder(Object?)?, bool isSecret = false}) → Output<T>
Registers a dynamic output property for this resource.
inherited
resolveId(String? value, {required bool isKnown}) → void
Resolves the provider-assigned ID for this resource.
inherited
resolveOutputs(Struct outputs) → void
Resolves all output properties from a monitor response payload.
inherited
resolveUrn(String value) → void
Resolves this resource's URN once assigned by the engine.
inherited
serializeProperties(Map<String, dynamic> properties) → Future<Struct>
Serializes resource properties for RPC transmission.
inherited
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited

Static Methods

get(String name, Input<String> id, {TablePolicyState? state, CustomResourceOptions? options}) → TablePolicy
Gets an existing TablePolicy resource's state with the given name and id.