Documentation
¶
Index ¶
- type GCPolicy
- type GCPolicyArgs
- type GCPolicyInput
- type GCPolicyMaxAge
- type GCPolicyMaxAgeArgs
- type GCPolicyMaxAgeArray
- type GCPolicyMaxAgeArrayInput
- type GCPolicyMaxAgeArrayOutput
- func (GCPolicyMaxAgeArrayOutput) ElementType() reflect.Type
- func (o GCPolicyMaxAgeArrayOutput) Index(i pulumi.IntInput) GCPolicyMaxAgeOutput
- func (o GCPolicyMaxAgeArrayOutput) ToGCPolicyMaxAgeArrayOutput() GCPolicyMaxAgeArrayOutput
- func (o GCPolicyMaxAgeArrayOutput) ToGCPolicyMaxAgeArrayOutputWithContext(ctx context.Context) GCPolicyMaxAgeArrayOutput
- type GCPolicyMaxAgeInput
- type GCPolicyMaxAgeOutput
- type GCPolicyMaxVersion
- type GCPolicyMaxVersionArgs
- type GCPolicyMaxVersionArray
- type GCPolicyMaxVersionArrayInput
- type GCPolicyMaxVersionArrayOutput
- func (GCPolicyMaxVersionArrayOutput) ElementType() reflect.Type
- func (o GCPolicyMaxVersionArrayOutput) Index(i pulumi.IntInput) GCPolicyMaxVersionOutput
- func (o GCPolicyMaxVersionArrayOutput) ToGCPolicyMaxVersionArrayOutput() GCPolicyMaxVersionArrayOutput
- func (o GCPolicyMaxVersionArrayOutput) ToGCPolicyMaxVersionArrayOutputWithContext(ctx context.Context) GCPolicyMaxVersionArrayOutput
- type GCPolicyMaxVersionInput
- type GCPolicyMaxVersionOutput
- func (GCPolicyMaxVersionOutput) ElementType() reflect.Type
- func (o GCPolicyMaxVersionOutput) Number() pulumi.IntOutput
- func (o GCPolicyMaxVersionOutput) ToGCPolicyMaxVersionOutput() GCPolicyMaxVersionOutput
- func (o GCPolicyMaxVersionOutput) ToGCPolicyMaxVersionOutputWithContext(ctx context.Context) GCPolicyMaxVersionOutput
- type GCPolicyOutput
- type GCPolicyState
- type Instance
- type InstanceArgs
- type InstanceCluster
- type InstanceClusterArgs
- type InstanceClusterArray
- type InstanceClusterArrayInput
- type InstanceClusterArrayOutput
- func (InstanceClusterArrayOutput) ElementType() reflect.Type
- func (o InstanceClusterArrayOutput) Index(i pulumi.IntInput) InstanceClusterOutput
- func (o InstanceClusterArrayOutput) ToInstanceClusterArrayOutput() InstanceClusterArrayOutput
- func (o InstanceClusterArrayOutput) ToInstanceClusterArrayOutputWithContext(ctx context.Context) InstanceClusterArrayOutput
- type InstanceClusterInput
- type InstanceClusterOutput
- func (o InstanceClusterOutput) ClusterId() pulumi.StringOutput
- func (InstanceClusterOutput) ElementType() reflect.Type
- func (o InstanceClusterOutput) NumNodes() pulumi.IntPtrOutput
- func (o InstanceClusterOutput) StorageType() pulumi.StringPtrOutput
- func (o InstanceClusterOutput) ToInstanceClusterOutput() InstanceClusterOutput
- func (o InstanceClusterOutput) ToInstanceClusterOutputWithContext(ctx context.Context) InstanceClusterOutput
- func (o InstanceClusterOutput) Zone() pulumi.StringOutput
- type InstanceIamBinding
- type InstanceIamBindingArgs
- type InstanceIamBindingCondition
- type InstanceIamBindingConditionArgs
- func (InstanceIamBindingConditionArgs) ElementType() reflect.Type
- func (i InstanceIamBindingConditionArgs) ToInstanceIamBindingConditionOutput() InstanceIamBindingConditionOutput
- func (i InstanceIamBindingConditionArgs) ToInstanceIamBindingConditionOutputWithContext(ctx context.Context) InstanceIamBindingConditionOutput
- func (i InstanceIamBindingConditionArgs) ToInstanceIamBindingConditionPtrOutput() InstanceIamBindingConditionPtrOutput
- func (i InstanceIamBindingConditionArgs) ToInstanceIamBindingConditionPtrOutputWithContext(ctx context.Context) InstanceIamBindingConditionPtrOutput
- type InstanceIamBindingConditionInput
- type InstanceIamBindingConditionOutput
- func (o InstanceIamBindingConditionOutput) Description() pulumi.StringPtrOutput
- func (InstanceIamBindingConditionOutput) ElementType() reflect.Type
- func (o InstanceIamBindingConditionOutput) Expression() pulumi.StringOutput
- func (o InstanceIamBindingConditionOutput) Title() pulumi.StringOutput
- func (o InstanceIamBindingConditionOutput) ToInstanceIamBindingConditionOutput() InstanceIamBindingConditionOutput
- func (o InstanceIamBindingConditionOutput) ToInstanceIamBindingConditionOutputWithContext(ctx context.Context) InstanceIamBindingConditionOutput
- func (o InstanceIamBindingConditionOutput) ToInstanceIamBindingConditionPtrOutput() InstanceIamBindingConditionPtrOutput
- func (o InstanceIamBindingConditionOutput) ToInstanceIamBindingConditionPtrOutputWithContext(ctx context.Context) InstanceIamBindingConditionPtrOutput
- type InstanceIamBindingConditionPtrInput
- type InstanceIamBindingConditionPtrOutput
- func (o InstanceIamBindingConditionPtrOutput) Description() pulumi.StringPtrOutput
- func (o InstanceIamBindingConditionPtrOutput) Elem() InstanceIamBindingConditionOutput
- func (InstanceIamBindingConditionPtrOutput) ElementType() reflect.Type
- func (o InstanceIamBindingConditionPtrOutput) Expression() pulumi.StringPtrOutput
- func (o InstanceIamBindingConditionPtrOutput) Title() pulumi.StringPtrOutput
- func (o InstanceIamBindingConditionPtrOutput) ToInstanceIamBindingConditionPtrOutput() InstanceIamBindingConditionPtrOutput
- func (o InstanceIamBindingConditionPtrOutput) ToInstanceIamBindingConditionPtrOutputWithContext(ctx context.Context) InstanceIamBindingConditionPtrOutput
- type InstanceIamBindingInput
- type InstanceIamBindingOutput
- type InstanceIamBindingState
- type InstanceIamMember
- type InstanceIamMemberArgs
- type InstanceIamMemberCondition
- type InstanceIamMemberConditionArgs
- func (InstanceIamMemberConditionArgs) ElementType() reflect.Type
- func (i InstanceIamMemberConditionArgs) ToInstanceIamMemberConditionOutput() InstanceIamMemberConditionOutput
- func (i InstanceIamMemberConditionArgs) ToInstanceIamMemberConditionOutputWithContext(ctx context.Context) InstanceIamMemberConditionOutput
- func (i InstanceIamMemberConditionArgs) ToInstanceIamMemberConditionPtrOutput() InstanceIamMemberConditionPtrOutput
- func (i InstanceIamMemberConditionArgs) ToInstanceIamMemberConditionPtrOutputWithContext(ctx context.Context) InstanceIamMemberConditionPtrOutput
- type InstanceIamMemberConditionInput
- type InstanceIamMemberConditionOutput
- func (o InstanceIamMemberConditionOutput) Description() pulumi.StringPtrOutput
- func (InstanceIamMemberConditionOutput) ElementType() reflect.Type
- func (o InstanceIamMemberConditionOutput) Expression() pulumi.StringOutput
- func (o InstanceIamMemberConditionOutput) Title() pulumi.StringOutput
- func (o InstanceIamMemberConditionOutput) ToInstanceIamMemberConditionOutput() InstanceIamMemberConditionOutput
- func (o InstanceIamMemberConditionOutput) ToInstanceIamMemberConditionOutputWithContext(ctx context.Context) InstanceIamMemberConditionOutput
- func (o InstanceIamMemberConditionOutput) ToInstanceIamMemberConditionPtrOutput() InstanceIamMemberConditionPtrOutput
- func (o InstanceIamMemberConditionOutput) ToInstanceIamMemberConditionPtrOutputWithContext(ctx context.Context) InstanceIamMemberConditionPtrOutput
- type InstanceIamMemberConditionPtrInput
- type InstanceIamMemberConditionPtrOutput
- func (o InstanceIamMemberConditionPtrOutput) Description() pulumi.StringPtrOutput
- func (o InstanceIamMemberConditionPtrOutput) Elem() InstanceIamMemberConditionOutput
- func (InstanceIamMemberConditionPtrOutput) ElementType() reflect.Type
- func (o InstanceIamMemberConditionPtrOutput) Expression() pulumi.StringPtrOutput
- func (o InstanceIamMemberConditionPtrOutput) Title() pulumi.StringPtrOutput
- func (o InstanceIamMemberConditionPtrOutput) ToInstanceIamMemberConditionPtrOutput() InstanceIamMemberConditionPtrOutput
- func (o InstanceIamMemberConditionPtrOutput) ToInstanceIamMemberConditionPtrOutputWithContext(ctx context.Context) InstanceIamMemberConditionPtrOutput
- type InstanceIamMemberInput
- type InstanceIamMemberOutput
- type InstanceIamMemberState
- type InstanceIamPolicy
- type InstanceIamPolicyArgs
- type InstanceIamPolicyInput
- type InstanceIamPolicyOutput
- type InstanceIamPolicyState
- type InstanceInput
- type InstanceOutput
- type InstanceState
- type Table
- type TableArgs
- type TableColumnFamily
- type TableColumnFamilyArgs
- type TableColumnFamilyArray
- type TableColumnFamilyArrayInput
- type TableColumnFamilyArrayOutput
- func (TableColumnFamilyArrayOutput) ElementType() reflect.Type
- func (o TableColumnFamilyArrayOutput) Index(i pulumi.IntInput) TableColumnFamilyOutput
- func (o TableColumnFamilyArrayOutput) ToTableColumnFamilyArrayOutput() TableColumnFamilyArrayOutput
- func (o TableColumnFamilyArrayOutput) ToTableColumnFamilyArrayOutputWithContext(ctx context.Context) TableColumnFamilyArrayOutput
- type TableColumnFamilyInput
- type TableColumnFamilyOutput
- func (TableColumnFamilyOutput) ElementType() reflect.Type
- func (o TableColumnFamilyOutput) Family() pulumi.StringOutput
- func (o TableColumnFamilyOutput) ToTableColumnFamilyOutput() TableColumnFamilyOutput
- func (o TableColumnFamilyOutput) ToTableColumnFamilyOutputWithContext(ctx context.Context) TableColumnFamilyOutput
- type TableIamBinding
- type TableIamBindingArgs
- type TableIamBindingCondition
- type TableIamBindingConditionArgs
- func (TableIamBindingConditionArgs) ElementType() reflect.Type
- func (i TableIamBindingConditionArgs) ToTableIamBindingConditionOutput() TableIamBindingConditionOutput
- func (i TableIamBindingConditionArgs) ToTableIamBindingConditionOutputWithContext(ctx context.Context) TableIamBindingConditionOutput
- func (i TableIamBindingConditionArgs) ToTableIamBindingConditionPtrOutput() TableIamBindingConditionPtrOutput
- func (i TableIamBindingConditionArgs) ToTableIamBindingConditionPtrOutputWithContext(ctx context.Context) TableIamBindingConditionPtrOutput
- type TableIamBindingConditionInput
- type TableIamBindingConditionOutput
- func (o TableIamBindingConditionOutput) Description() pulumi.StringPtrOutput
- func (TableIamBindingConditionOutput) ElementType() reflect.Type
- func (o TableIamBindingConditionOutput) Expression() pulumi.StringOutput
- func (o TableIamBindingConditionOutput) Title() pulumi.StringOutput
- func (o TableIamBindingConditionOutput) ToTableIamBindingConditionOutput() TableIamBindingConditionOutput
- func (o TableIamBindingConditionOutput) ToTableIamBindingConditionOutputWithContext(ctx context.Context) TableIamBindingConditionOutput
- func (o TableIamBindingConditionOutput) ToTableIamBindingConditionPtrOutput() TableIamBindingConditionPtrOutput
- func (o TableIamBindingConditionOutput) ToTableIamBindingConditionPtrOutputWithContext(ctx context.Context) TableIamBindingConditionPtrOutput
- type TableIamBindingConditionPtrInput
- type TableIamBindingConditionPtrOutput
- func (o TableIamBindingConditionPtrOutput) Description() pulumi.StringPtrOutput
- func (o TableIamBindingConditionPtrOutput) Elem() TableIamBindingConditionOutput
- func (TableIamBindingConditionPtrOutput) ElementType() reflect.Type
- func (o TableIamBindingConditionPtrOutput) Expression() pulumi.StringPtrOutput
- func (o TableIamBindingConditionPtrOutput) Title() pulumi.StringPtrOutput
- func (o TableIamBindingConditionPtrOutput) ToTableIamBindingConditionPtrOutput() TableIamBindingConditionPtrOutput
- func (o TableIamBindingConditionPtrOutput) ToTableIamBindingConditionPtrOutputWithContext(ctx context.Context) TableIamBindingConditionPtrOutput
- type TableIamBindingInput
- type TableIamBindingOutput
- type TableIamBindingState
- type TableIamMember
- type TableIamMemberArgs
- type TableIamMemberCondition
- type TableIamMemberConditionArgs
- func (TableIamMemberConditionArgs) ElementType() reflect.Type
- func (i TableIamMemberConditionArgs) ToTableIamMemberConditionOutput() TableIamMemberConditionOutput
- func (i TableIamMemberConditionArgs) ToTableIamMemberConditionOutputWithContext(ctx context.Context) TableIamMemberConditionOutput
- func (i TableIamMemberConditionArgs) ToTableIamMemberConditionPtrOutput() TableIamMemberConditionPtrOutput
- func (i TableIamMemberConditionArgs) ToTableIamMemberConditionPtrOutputWithContext(ctx context.Context) TableIamMemberConditionPtrOutput
- type TableIamMemberConditionInput
- type TableIamMemberConditionOutput
- func (o TableIamMemberConditionOutput) Description() pulumi.StringPtrOutput
- func (TableIamMemberConditionOutput) ElementType() reflect.Type
- func (o TableIamMemberConditionOutput) Expression() pulumi.StringOutput
- func (o TableIamMemberConditionOutput) Title() pulumi.StringOutput
- func (o TableIamMemberConditionOutput) ToTableIamMemberConditionOutput() TableIamMemberConditionOutput
- func (o TableIamMemberConditionOutput) ToTableIamMemberConditionOutputWithContext(ctx context.Context) TableIamMemberConditionOutput
- func (o TableIamMemberConditionOutput) ToTableIamMemberConditionPtrOutput() TableIamMemberConditionPtrOutput
- func (o TableIamMemberConditionOutput) ToTableIamMemberConditionPtrOutputWithContext(ctx context.Context) TableIamMemberConditionPtrOutput
- type TableIamMemberConditionPtrInput
- type TableIamMemberConditionPtrOutput
- func (o TableIamMemberConditionPtrOutput) Description() pulumi.StringPtrOutput
- func (o TableIamMemberConditionPtrOutput) Elem() TableIamMemberConditionOutput
- func (TableIamMemberConditionPtrOutput) ElementType() reflect.Type
- func (o TableIamMemberConditionPtrOutput) Expression() pulumi.StringPtrOutput
- func (o TableIamMemberConditionPtrOutput) Title() pulumi.StringPtrOutput
- func (o TableIamMemberConditionPtrOutput) ToTableIamMemberConditionPtrOutput() TableIamMemberConditionPtrOutput
- func (o TableIamMemberConditionPtrOutput) ToTableIamMemberConditionPtrOutputWithContext(ctx context.Context) TableIamMemberConditionPtrOutput
- type TableIamMemberInput
- type TableIamMemberOutput
- type TableIamMemberState
- type TableIamPolicy
- type TableIamPolicyArgs
- type TableIamPolicyInput
- type TableIamPolicyOutput
- type TableIamPolicyState
- type TableInput
- type TableOutput
- type TableState
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type GCPolicy ¶
type GCPolicy struct { pulumi.CustomResourceState // The name of the column family. ColumnFamily pulumi.StringOutput `pulumi:"columnFamily"` // The name of the Bigtable instance. InstanceName pulumi.StringOutput `pulumi:"instanceName"` // GC policy that applies to all cells older than the given age. MaxAges GCPolicyMaxAgeArrayOutput `pulumi:"maxAges"` // GC policy that applies to all versions of a cell except for the most recent. MaxVersions GCPolicyMaxVersionArrayOutput `pulumi:"maxVersions"` // If multiple policies are set, you should choose between `UNION` OR `INTERSECTION`. Mode pulumi.StringPtrOutput `pulumi:"mode"` // The ID of the project in which the resource belongs. If it is not provided, the provider project is used. Project pulumi.StringOutput `pulumi:"project"` // The name of the table. Table pulumi.StringOutput `pulumi:"table"` }
Creates a Google Cloud Bigtable GC Policy inside a family. For more information see [the official documentation](https://cloud.google.com/bigtable/) and [API](https://cloud.google.com/bigtable/docs/go/reference).
## Example Usage
```go package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/bigtable" "github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)
func main() { pulumi.Run(func(ctx *pulumi.Context) error { instance, err := bigtable.NewInstance(ctx, "instance", &bigtable.InstanceArgs{ Clusters: bigtable.InstanceClusterArray{ &bigtable.InstanceClusterArgs{ ClusterId: pulumi.String("tf-instance-cluster"), Zone: pulumi.String("us-central1-b"), NumNodes: pulumi.Int(3), StorageType: pulumi.String("HDD"), }, }, }) if err != nil { return err } table, err := bigtable.NewTable(ctx, "table", &bigtable.TableArgs{ InstanceName: instance.Name, ColumnFamilies: bigtable.TableColumnFamilyArray{ &bigtable.TableColumnFamilyArgs{ Family: pulumi.String("name"), }, }, }) if err != nil { return err } _, err = bigtable.NewGCPolicy(ctx, "policy", &bigtable.GCPolicyArgs{ InstanceName: instance.Name, Table: table.Name, ColumnFamily: pulumi.String("name"), MaxAges: bigtable.GCPolicyMaxAgeArray{ &bigtable.GCPolicyMaxAgeArgs{ Days: pulumi.Int(7), }, }, }) if err != nil { return err } return nil }) }
```
Multiple conditions is also supported. `UNION` when any of its sub-policies apply (OR). `INTERSECTION` when all its sub-policies apply (AND)
```go package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/bigtable" "github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)
func main() { pulumi.Run(func(ctx *pulumi.Context) error { _, err := bigtable.NewGCPolicy(ctx, "policy", &bigtable.GCPolicyArgs{ InstanceName: pulumi.Any(google_bigtable_instance.Instance.Name), Table: pulumi.Any(google_bigtable_table.Table.Name), ColumnFamily: pulumi.String("name"), Mode: pulumi.String("UNION"), MaxAges: bigtable.GCPolicyMaxAgeArray{ &bigtable.GCPolicyMaxAgeArgs{ Days: pulumi.Int(7), }, }, MaxVersions: bigtable.GCPolicyMaxVersionArray{ &bigtable.GCPolicyMaxVersionArgs{ Number: pulumi.Int(10), }, }, }) if err != nil { return err } return nil }) }
```
## Import
This resource does not support import.
func GetGCPolicy ¶
func GetGCPolicy(ctx *pulumi.Context, name string, id pulumi.IDInput, state *GCPolicyState, opts ...pulumi.ResourceOption) (*GCPolicy, error)
GetGCPolicy gets an existing GCPolicy resource's state with the given name, ID, and optional state properties that are used to uniquely qualify the lookup (nil if not required).
func NewGCPolicy ¶
func NewGCPolicy(ctx *pulumi.Context, name string, args *GCPolicyArgs, opts ...pulumi.ResourceOption) (*GCPolicy, error)
NewGCPolicy registers a new resource with the given unique name, arguments, and options.
func (GCPolicy) ElementType ¶ added in v4.4.0
func (GCPolicy) ToGCPolicyOutput ¶ added in v4.4.0
func (i GCPolicy) ToGCPolicyOutput() GCPolicyOutput
func (GCPolicy) ToGCPolicyOutputWithContext ¶ added in v4.4.0
func (i GCPolicy) ToGCPolicyOutputWithContext(ctx context.Context) GCPolicyOutput
type GCPolicyArgs ¶
type GCPolicyArgs struct { // The name of the column family. ColumnFamily pulumi.StringInput // The name of the Bigtable instance. InstanceName pulumi.StringInput // GC policy that applies to all cells older than the given age. MaxAges GCPolicyMaxAgeArrayInput // GC policy that applies to all versions of a cell except for the most recent. MaxVersions GCPolicyMaxVersionArrayInput // If multiple policies are set, you should choose between `UNION` OR `INTERSECTION`. Mode pulumi.StringPtrInput // The ID of the project in which the resource belongs. If it is not provided, the provider project is used. Project pulumi.StringPtrInput // The name of the table. Table pulumi.StringInput }
The set of arguments for constructing a GCPolicy resource.
func (GCPolicyArgs) ElementType ¶
func (GCPolicyArgs) ElementType() reflect.Type
type GCPolicyInput ¶ added in v4.4.0
type GCPolicyInput interface { pulumi.Input ToGCPolicyOutput() GCPolicyOutput ToGCPolicyOutputWithContext(ctx context.Context) GCPolicyOutput }
type GCPolicyMaxAge ¶
type GCPolicyMaxAge struct { // Number of days before applying GC policy. Days int `pulumi:"days"` }
type GCPolicyMaxAgeArgs ¶
type GCPolicyMaxAgeArgs struct { // Number of days before applying GC policy. Days pulumi.IntInput `pulumi:"days"` }
func (GCPolicyMaxAgeArgs) ElementType ¶
func (GCPolicyMaxAgeArgs) ElementType() reflect.Type
func (GCPolicyMaxAgeArgs) ToGCPolicyMaxAgeOutput ¶
func (i GCPolicyMaxAgeArgs) ToGCPolicyMaxAgeOutput() GCPolicyMaxAgeOutput
func (GCPolicyMaxAgeArgs) ToGCPolicyMaxAgeOutputWithContext ¶
func (i GCPolicyMaxAgeArgs) ToGCPolicyMaxAgeOutputWithContext(ctx context.Context) GCPolicyMaxAgeOutput
type GCPolicyMaxAgeArray ¶
type GCPolicyMaxAgeArray []GCPolicyMaxAgeInput
func (GCPolicyMaxAgeArray) ElementType ¶
func (GCPolicyMaxAgeArray) ElementType() reflect.Type
func (GCPolicyMaxAgeArray) ToGCPolicyMaxAgeArrayOutput ¶
func (i GCPolicyMaxAgeArray) ToGCPolicyMaxAgeArrayOutput() GCPolicyMaxAgeArrayOutput
func (GCPolicyMaxAgeArray) ToGCPolicyMaxAgeArrayOutputWithContext ¶
func (i GCPolicyMaxAgeArray) ToGCPolicyMaxAgeArrayOutputWithContext(ctx context.Context) GCPolicyMaxAgeArrayOutput
type GCPolicyMaxAgeArrayInput ¶
type GCPolicyMaxAgeArrayInput interface { pulumi.Input ToGCPolicyMaxAgeArrayOutput() GCPolicyMaxAgeArrayOutput ToGCPolicyMaxAgeArrayOutputWithContext(context.Context) GCPolicyMaxAgeArrayOutput }
GCPolicyMaxAgeArrayInput is an input type that accepts GCPolicyMaxAgeArray and GCPolicyMaxAgeArrayOutput values. You can construct a concrete instance of `GCPolicyMaxAgeArrayInput` via:
GCPolicyMaxAgeArray{ GCPolicyMaxAgeArgs{...} }
type GCPolicyMaxAgeArrayOutput ¶
type GCPolicyMaxAgeArrayOutput struct{ *pulumi.OutputState }
func (GCPolicyMaxAgeArrayOutput) ElementType ¶
func (GCPolicyMaxAgeArrayOutput) ElementType() reflect.Type
func (GCPolicyMaxAgeArrayOutput) Index ¶
func (o GCPolicyMaxAgeArrayOutput) Index(i pulumi.IntInput) GCPolicyMaxAgeOutput
func (GCPolicyMaxAgeArrayOutput) ToGCPolicyMaxAgeArrayOutput ¶
func (o GCPolicyMaxAgeArrayOutput) ToGCPolicyMaxAgeArrayOutput() GCPolicyMaxAgeArrayOutput
func (GCPolicyMaxAgeArrayOutput) ToGCPolicyMaxAgeArrayOutputWithContext ¶
func (o GCPolicyMaxAgeArrayOutput) ToGCPolicyMaxAgeArrayOutputWithContext(ctx context.Context) GCPolicyMaxAgeArrayOutput
type GCPolicyMaxAgeInput ¶
type GCPolicyMaxAgeInput interface { pulumi.Input ToGCPolicyMaxAgeOutput() GCPolicyMaxAgeOutput ToGCPolicyMaxAgeOutputWithContext(context.Context) GCPolicyMaxAgeOutput }
GCPolicyMaxAgeInput is an input type that accepts GCPolicyMaxAgeArgs and GCPolicyMaxAgeOutput values. You can construct a concrete instance of `GCPolicyMaxAgeInput` via:
GCPolicyMaxAgeArgs{...}
type GCPolicyMaxAgeOutput ¶
type GCPolicyMaxAgeOutput struct{ *pulumi.OutputState }
func (GCPolicyMaxAgeOutput) Days ¶
func (o GCPolicyMaxAgeOutput) Days() pulumi.IntOutput
Number of days before applying GC policy.
func (GCPolicyMaxAgeOutput) ElementType ¶
func (GCPolicyMaxAgeOutput) ElementType() reflect.Type
func (GCPolicyMaxAgeOutput) ToGCPolicyMaxAgeOutput ¶
func (o GCPolicyMaxAgeOutput) ToGCPolicyMaxAgeOutput() GCPolicyMaxAgeOutput
func (GCPolicyMaxAgeOutput) ToGCPolicyMaxAgeOutputWithContext ¶
func (o GCPolicyMaxAgeOutput) ToGCPolicyMaxAgeOutputWithContext(ctx context.Context) GCPolicyMaxAgeOutput
type GCPolicyMaxVersion ¶
type GCPolicyMaxVersion struct { // Number of version before applying the GC policy. Number int `pulumi:"number"` }
type GCPolicyMaxVersionArgs ¶
type GCPolicyMaxVersionArgs struct { // Number of version before applying the GC policy. Number pulumi.IntInput `pulumi:"number"` }
func (GCPolicyMaxVersionArgs) ElementType ¶
func (GCPolicyMaxVersionArgs) ElementType() reflect.Type
func (GCPolicyMaxVersionArgs) ToGCPolicyMaxVersionOutput ¶
func (i GCPolicyMaxVersionArgs) ToGCPolicyMaxVersionOutput() GCPolicyMaxVersionOutput
func (GCPolicyMaxVersionArgs) ToGCPolicyMaxVersionOutputWithContext ¶
func (i GCPolicyMaxVersionArgs) ToGCPolicyMaxVersionOutputWithContext(ctx context.Context) GCPolicyMaxVersionOutput
type GCPolicyMaxVersionArray ¶
type GCPolicyMaxVersionArray []GCPolicyMaxVersionInput
func (GCPolicyMaxVersionArray) ElementType ¶
func (GCPolicyMaxVersionArray) ElementType() reflect.Type
func (GCPolicyMaxVersionArray) ToGCPolicyMaxVersionArrayOutput ¶
func (i GCPolicyMaxVersionArray) ToGCPolicyMaxVersionArrayOutput() GCPolicyMaxVersionArrayOutput
func (GCPolicyMaxVersionArray) ToGCPolicyMaxVersionArrayOutputWithContext ¶
func (i GCPolicyMaxVersionArray) ToGCPolicyMaxVersionArrayOutputWithContext(ctx context.Context) GCPolicyMaxVersionArrayOutput
type GCPolicyMaxVersionArrayInput ¶
type GCPolicyMaxVersionArrayInput interface { pulumi.Input ToGCPolicyMaxVersionArrayOutput() GCPolicyMaxVersionArrayOutput ToGCPolicyMaxVersionArrayOutputWithContext(context.Context) GCPolicyMaxVersionArrayOutput }
GCPolicyMaxVersionArrayInput is an input type that accepts GCPolicyMaxVersionArray and GCPolicyMaxVersionArrayOutput values. You can construct a concrete instance of `GCPolicyMaxVersionArrayInput` via:
GCPolicyMaxVersionArray{ GCPolicyMaxVersionArgs{...} }
type GCPolicyMaxVersionArrayOutput ¶
type GCPolicyMaxVersionArrayOutput struct{ *pulumi.OutputState }
func (GCPolicyMaxVersionArrayOutput) ElementType ¶
func (GCPolicyMaxVersionArrayOutput) ElementType() reflect.Type
func (GCPolicyMaxVersionArrayOutput) Index ¶
func (o GCPolicyMaxVersionArrayOutput) Index(i pulumi.IntInput) GCPolicyMaxVersionOutput
func (GCPolicyMaxVersionArrayOutput) ToGCPolicyMaxVersionArrayOutput ¶
func (o GCPolicyMaxVersionArrayOutput) ToGCPolicyMaxVersionArrayOutput() GCPolicyMaxVersionArrayOutput
func (GCPolicyMaxVersionArrayOutput) ToGCPolicyMaxVersionArrayOutputWithContext ¶
func (o GCPolicyMaxVersionArrayOutput) ToGCPolicyMaxVersionArrayOutputWithContext(ctx context.Context) GCPolicyMaxVersionArrayOutput
type GCPolicyMaxVersionInput ¶
type GCPolicyMaxVersionInput interface { pulumi.Input ToGCPolicyMaxVersionOutput() GCPolicyMaxVersionOutput ToGCPolicyMaxVersionOutputWithContext(context.Context) GCPolicyMaxVersionOutput }
GCPolicyMaxVersionInput is an input type that accepts GCPolicyMaxVersionArgs and GCPolicyMaxVersionOutput values. You can construct a concrete instance of `GCPolicyMaxVersionInput` via:
GCPolicyMaxVersionArgs{...}
type GCPolicyMaxVersionOutput ¶
type GCPolicyMaxVersionOutput struct{ *pulumi.OutputState }
func (GCPolicyMaxVersionOutput) ElementType ¶
func (GCPolicyMaxVersionOutput) ElementType() reflect.Type
func (GCPolicyMaxVersionOutput) Number ¶
func (o GCPolicyMaxVersionOutput) Number() pulumi.IntOutput
Number of version before applying the GC policy.
func (GCPolicyMaxVersionOutput) ToGCPolicyMaxVersionOutput ¶
func (o GCPolicyMaxVersionOutput) ToGCPolicyMaxVersionOutput() GCPolicyMaxVersionOutput
func (GCPolicyMaxVersionOutput) ToGCPolicyMaxVersionOutputWithContext ¶
func (o GCPolicyMaxVersionOutput) ToGCPolicyMaxVersionOutputWithContext(ctx context.Context) GCPolicyMaxVersionOutput
type GCPolicyOutput ¶ added in v4.4.0
type GCPolicyOutput struct {
*pulumi.OutputState
}
func (GCPolicyOutput) ElementType ¶ added in v4.4.0
func (GCPolicyOutput) ElementType() reflect.Type
func (GCPolicyOutput) ToGCPolicyOutput ¶ added in v4.4.0
func (o GCPolicyOutput) ToGCPolicyOutput() GCPolicyOutput
func (GCPolicyOutput) ToGCPolicyOutputWithContext ¶ added in v4.4.0
func (o GCPolicyOutput) ToGCPolicyOutputWithContext(ctx context.Context) GCPolicyOutput
type GCPolicyState ¶
type GCPolicyState struct { // The name of the column family. ColumnFamily pulumi.StringPtrInput // The name of the Bigtable instance. InstanceName pulumi.StringPtrInput // GC policy that applies to all cells older than the given age. MaxAges GCPolicyMaxAgeArrayInput // GC policy that applies to all versions of a cell except for the most recent. MaxVersions GCPolicyMaxVersionArrayInput // If multiple policies are set, you should choose between `UNION` OR `INTERSECTION`. Mode pulumi.StringPtrInput // The ID of the project in which the resource belongs. If it is not provided, the provider project is used. Project pulumi.StringPtrInput // The name of the table. Table pulumi.StringPtrInput }
func (GCPolicyState) ElementType ¶
func (GCPolicyState) ElementType() reflect.Type
type Instance ¶
type Instance struct { pulumi.CustomResourceState // A block of cluster configuration options. This can be specified at least once, and up to 4 times. // See structure below. Clusters InstanceClusterArrayOutput `pulumi:"clusters"` // Whether or not to allow this provider to destroy the instance. Unless this field is set to false // in the statefile, a `pulumi destroy` or `pulumi up` that would delete the instance will fail. DeletionProtection pulumi.BoolPtrOutput `pulumi:"deletionProtection"` // The human-readable display name of the Bigtable instance. Defaults to the instance `name`. DisplayName pulumi.StringOutput `pulumi:"displayName"` // The instance type to create. One of `"DEVELOPMENT"` or `"PRODUCTION"`. Defaults to `"PRODUCTION"`. // It is recommended to leave this field unspecified since the distinction between `"DEVELOPMENT"` and `"PRODUCTION"` instances is going away, // and all instances will become `"PRODUCTION"` instances. This means that new and existing `"DEVELOPMENT"` instances will be converted to // `"PRODUCTION"` instances. It is recommended for users to use `"PRODUCTION"` instances in any case, since a 1-node `"PRODUCTION"` instance // is functionally identical to a `"DEVELOPMENT"` instance, but without the accompanying restrictions. // // Deprecated: It is recommended to leave this field unspecified since the distinction between "DEVELOPMENT" and "PRODUCTION" instances is going away, and all instances will become "PRODUCTION" instances. This means that new and existing "DEVELOPMENT" instances will be converted to "PRODUCTION" instances. It is recommended for users to use "PRODUCTION" instances in any case, since a 1-node "PRODUCTION" instance is functionally identical to a "DEVELOPMENT" instance, but without the accompanying restrictions. InstanceType pulumi.StringPtrOutput `pulumi:"instanceType"` // A set of key/value label pairs to assign to the resource. Label keys must follow the requirements at https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements. Labels pulumi.StringMapOutput `pulumi:"labels"` // The name (also called Instance Id in the Cloud Console) of the Cloud Bigtable instance. Name pulumi.StringOutput `pulumi:"name"` // The ID of the project in which the resource belongs. If it // is not provided, the provider project is used. Project pulumi.StringOutput `pulumi:"project"` }
Creates a Google Bigtable instance. For more information see [the official documentation](https://cloud.google.com/bigtable/) and [API](https://cloud.google.com/bigtable/docs/go/reference).
## Example Usage ### Development Instance
```go package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/bigtable" "github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)
func main() { pulumi.Run(func(ctx *pulumi.Context) error { _, err := bigtable.NewInstance(ctx, "development_instance", &bigtable.InstanceArgs{ Clusters: bigtable.InstanceClusterArray{ &bigtable.InstanceClusterArgs{ ClusterId: pulumi.String("tf-instance-cluster"), StorageType: pulumi.String("HDD"), Zone: pulumi.String("us-central1-b"), }, }, InstanceType: pulumi.String("DEVELOPMENT"), Labels: pulumi.StringMap{ "my-label": pulumi.String("dev-label"), }, }) if err != nil { return err } return nil }) }
```
## Import
Bigtable Instances can be imported using any of these accepted formats ¶
```sh
$ pulumi import gcp:bigtable/instance:Instance default projects/{{project}}/instances/{{name}}
```
```sh
$ pulumi import gcp:bigtable/instance:Instance default {{project}}/{{name}}
```
```sh
$ pulumi import gcp:bigtable/instance:Instance default {{name}}
```
func GetInstance ¶
func GetInstance(ctx *pulumi.Context, name string, id pulumi.IDInput, state *InstanceState, opts ...pulumi.ResourceOption) (*Instance, error)
GetInstance gets an existing Instance resource's state with the given name, ID, and optional state properties that are used to uniquely qualify the lookup (nil if not required).
func NewInstance ¶
func NewInstance(ctx *pulumi.Context, name string, args *InstanceArgs, opts ...pulumi.ResourceOption) (*Instance, error)
NewInstance registers a new resource with the given unique name, arguments, and options.
func (Instance) ElementType ¶ added in v4.4.0
func (Instance) ToInstanceOutput ¶ added in v4.4.0
func (i Instance) ToInstanceOutput() InstanceOutput
func (Instance) ToInstanceOutputWithContext ¶ added in v4.4.0
func (i Instance) ToInstanceOutputWithContext(ctx context.Context) InstanceOutput
type InstanceArgs ¶
type InstanceArgs struct { // A block of cluster configuration options. This can be specified at least once, and up to 4 times. // See structure below. Clusters InstanceClusterArrayInput // Whether or not to allow this provider to destroy the instance. Unless this field is set to false // in the statefile, a `pulumi destroy` or `pulumi up` that would delete the instance will fail. DeletionProtection pulumi.BoolPtrInput // The human-readable display name of the Bigtable instance. Defaults to the instance `name`. DisplayName pulumi.StringPtrInput // The instance type to create. One of `"DEVELOPMENT"` or `"PRODUCTION"`. Defaults to `"PRODUCTION"`. // It is recommended to leave this field unspecified since the distinction between `"DEVELOPMENT"` and `"PRODUCTION"` instances is going away, // and all instances will become `"PRODUCTION"` instances. This means that new and existing `"DEVELOPMENT"` instances will be converted to // `"PRODUCTION"` instances. It is recommended for users to use `"PRODUCTION"` instances in any case, since a 1-node `"PRODUCTION"` instance // is functionally identical to a `"DEVELOPMENT"` instance, but without the accompanying restrictions. // // Deprecated: It is recommended to leave this field unspecified since the distinction between "DEVELOPMENT" and "PRODUCTION" instances is going away, and all instances will become "PRODUCTION" instances. This means that new and existing "DEVELOPMENT" instances will be converted to "PRODUCTION" instances. It is recommended for users to use "PRODUCTION" instances in any case, since a 1-node "PRODUCTION" instance is functionally identical to a "DEVELOPMENT" instance, but without the accompanying restrictions. InstanceType pulumi.StringPtrInput // A set of key/value label pairs to assign to the resource. Label keys must follow the requirements at https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements. Labels pulumi.StringMapInput // The name (also called Instance Id in the Cloud Console) of the Cloud Bigtable instance. Name pulumi.StringPtrInput // The ID of the project in which the resource belongs. If it // is not provided, the provider project is used. Project pulumi.StringPtrInput }
The set of arguments for constructing a Instance resource.
func (InstanceArgs) ElementType ¶
func (InstanceArgs) ElementType() reflect.Type
type InstanceCluster ¶
type InstanceCluster struct { // The ID of the Cloud Bigtable cluster. ClusterId string `pulumi:"clusterId"` // The number of nodes in your Cloud Bigtable cluster. // Required, with a minimum of `1` for a `PRODUCTION` instance. Must be left unset // for a `DEVELOPMENT` instance. NumNodes *int `pulumi:"numNodes"` // The storage type to use. One of `"SSD"` or // `"HDD"`. Defaults to `"SSD"`. StorageType *string `pulumi:"storageType"` // The zone to create the Cloud Bigtable cluster in. Each // cluster must have a different zone in the same region. Zones that support // Bigtable instances are noted on the [Cloud Bigtable locations page](https://cloud.google.com/bigtable/docs/locations). Zone string `pulumi:"zone"` }
type InstanceClusterArgs ¶
type InstanceClusterArgs struct { // The ID of the Cloud Bigtable cluster. ClusterId pulumi.StringInput `pulumi:"clusterId"` // The number of nodes in your Cloud Bigtable cluster. // Required, with a minimum of `1` for a `PRODUCTION` instance. Must be left unset // for a `DEVELOPMENT` instance. NumNodes pulumi.IntPtrInput `pulumi:"numNodes"` // The storage type to use. One of `"SSD"` or // `"HDD"`. Defaults to `"SSD"`. StorageType pulumi.StringPtrInput `pulumi:"storageType"` // The zone to create the Cloud Bigtable cluster in. Each // cluster must have a different zone in the same region. Zones that support // Bigtable instances are noted on the [Cloud Bigtable locations page](https://cloud.google.com/bigtable/docs/locations). Zone pulumi.StringInput `pulumi:"zone"` }
func (InstanceClusterArgs) ElementType ¶
func (InstanceClusterArgs) ElementType() reflect.Type
func (InstanceClusterArgs) ToInstanceClusterOutput ¶
func (i InstanceClusterArgs) ToInstanceClusterOutput() InstanceClusterOutput
func (InstanceClusterArgs) ToInstanceClusterOutputWithContext ¶
func (i InstanceClusterArgs) ToInstanceClusterOutputWithContext(ctx context.Context) InstanceClusterOutput
type InstanceClusterArray ¶
type InstanceClusterArray []InstanceClusterInput
func (InstanceClusterArray) ElementType ¶
func (InstanceClusterArray) ElementType() reflect.Type
func (InstanceClusterArray) ToInstanceClusterArrayOutput ¶
func (i InstanceClusterArray) ToInstanceClusterArrayOutput() InstanceClusterArrayOutput
func (InstanceClusterArray) ToInstanceClusterArrayOutputWithContext ¶
func (i InstanceClusterArray) ToInstanceClusterArrayOutputWithContext(ctx context.Context) InstanceClusterArrayOutput
type InstanceClusterArrayInput ¶
type InstanceClusterArrayInput interface { pulumi.Input ToInstanceClusterArrayOutput() InstanceClusterArrayOutput ToInstanceClusterArrayOutputWithContext(context.Context) InstanceClusterArrayOutput }
InstanceClusterArrayInput is an input type that accepts InstanceClusterArray and InstanceClusterArrayOutput values. You can construct a concrete instance of `InstanceClusterArrayInput` via:
InstanceClusterArray{ InstanceClusterArgs{...} }
type InstanceClusterArrayOutput ¶
type InstanceClusterArrayOutput struct{ *pulumi.OutputState }
func (InstanceClusterArrayOutput) ElementType ¶
func (InstanceClusterArrayOutput) ElementType() reflect.Type
func (InstanceClusterArrayOutput) Index ¶
func (o InstanceClusterArrayOutput) Index(i pulumi.IntInput) InstanceClusterOutput
func (InstanceClusterArrayOutput) ToInstanceClusterArrayOutput ¶
func (o InstanceClusterArrayOutput) ToInstanceClusterArrayOutput() InstanceClusterArrayOutput
func (InstanceClusterArrayOutput) ToInstanceClusterArrayOutputWithContext ¶
func (o InstanceClusterArrayOutput) ToInstanceClusterArrayOutputWithContext(ctx context.Context) InstanceClusterArrayOutput
type InstanceClusterInput ¶
type InstanceClusterInput interface { pulumi.Input ToInstanceClusterOutput() InstanceClusterOutput ToInstanceClusterOutputWithContext(context.Context) InstanceClusterOutput }
InstanceClusterInput is an input type that accepts InstanceClusterArgs and InstanceClusterOutput values. You can construct a concrete instance of `InstanceClusterInput` via:
InstanceClusterArgs{...}
type InstanceClusterOutput ¶
type InstanceClusterOutput struct{ *pulumi.OutputState }
func (InstanceClusterOutput) ClusterId ¶
func (o InstanceClusterOutput) ClusterId() pulumi.StringOutput
The ID of the Cloud Bigtable cluster.
func (InstanceClusterOutput) ElementType ¶
func (InstanceClusterOutput) ElementType() reflect.Type
func (InstanceClusterOutput) NumNodes ¶
func (o InstanceClusterOutput) NumNodes() pulumi.IntPtrOutput
The number of nodes in your Cloud Bigtable cluster. Required, with a minimum of `1` for a `PRODUCTION` instance. Must be left unset for a `DEVELOPMENT` instance.
func (InstanceClusterOutput) StorageType ¶
func (o InstanceClusterOutput) StorageType() pulumi.StringPtrOutput
The storage type to use. One of `"SSD"` or `"HDD"`. Defaults to `"SSD"`.
func (InstanceClusterOutput) ToInstanceClusterOutput ¶
func (o InstanceClusterOutput) ToInstanceClusterOutput() InstanceClusterOutput
func (InstanceClusterOutput) ToInstanceClusterOutputWithContext ¶
func (o InstanceClusterOutput) ToInstanceClusterOutputWithContext(ctx context.Context) InstanceClusterOutput
func (InstanceClusterOutput) Zone ¶
func (o InstanceClusterOutput) Zone() pulumi.StringOutput
The zone to create the Cloud Bigtable cluster in. Each cluster must have a different zone in the same region. Zones that support Bigtable instances are noted on the [Cloud Bigtable locations page](https://cloud.google.com/bigtable/docs/locations).
type InstanceIamBinding ¶
type InstanceIamBinding struct { pulumi.CustomResourceState Condition InstanceIamBindingConditionPtrOutput `pulumi:"condition"` // (Computed) The etag of the instances's IAM policy. Etag pulumi.StringOutput `pulumi:"etag"` // The name or relative resource id of the instance to manage IAM policies for. Instance pulumi.StringOutput `pulumi:"instance"` Members pulumi.StringArrayOutput `pulumi:"members"` // The project in which the instance belongs. If it // is not provided, a default will be supplied. Project pulumi.StringOutput `pulumi:"project"` // The role that should be applied. Only one // `bigtable.InstanceIamBinding` can be used per role. Note that custom roles must be of the format // `[projects|organizations]/{parent-name}/roles/{role-name}`. Read more about roles [here](https://cloud.google.com/bigtable/docs/access-control#roles). Role pulumi.StringOutput `pulumi:"role"` }
Three different resources help you manage IAM policies on bigtable instances. Each of these resources serves a different use case:
* `bigtable.InstanceIamPolicy`: Authoritative. Sets the IAM policy for the instance and replaces any existing policy already attached. * `bigtable.InstanceIamBinding`: Authoritative for a given role. Updates the IAM policy to grant a role to a list of members. Other roles within the IAM policy for the instance are preserved. * `bigtable.InstanceIamMember`: Non-authoritative. Updates the IAM policy to grant a role to a new member. Other members for the role for the instance are preserved.
> **Note:** `bigtable.InstanceIamPolicy` **cannot** be used in conjunction with `bigtable.InstanceIamBinding` and `bigtable.InstanceIamMember` or they will fight over what your policy should be. In addition, be careful not to accidentally unset ownership of the instance as `bigtable.InstanceIamPolicy` replaces the entire policy.
> **Note:** `bigtable.InstanceIamBinding` resources **can be** used in conjunction with `bigtable.InstanceIamMember` resources **only if** they do not grant privilege to the same role.
## google\_bigtable\_instance\_iam\_policy
```go package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/bigtable" "github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/organizations" "github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)
func main() { pulumi.Run(func(ctx *pulumi.Context) error { admin, err := organizations.LookupIAMPolicy(ctx, &organizations.LookupIAMPolicyArgs{ Bindings: []organizations.GetIAMPolicyBinding{ organizations.GetIAMPolicyBinding{ Role: "roles/bigtable.user", Members: []string{ "user:jane@example.com", }, }, }, }, nil) if err != nil { return err } _, err = bigtable.NewInstanceIamPolicy(ctx, "editor", &bigtable.InstanceIamPolicyArgs{ Project: pulumi.String("your-project"), Instance: pulumi.String("your-bigtable-instance"), PolicyData: pulumi.String(admin.PolicyData), }) if err != nil { return err } return nil }) }
```
## google\_bigtable\_instance\_iam\_binding
```go package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/bigtable" "github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)
func main() { pulumi.Run(func(ctx *pulumi.Context) error { _, err := bigtable.NewInstanceIamBinding(ctx, "editor", &bigtable.InstanceIamBindingArgs{ Instance: pulumi.String("your-bigtable-instance"), Members: pulumi.StringArray{ pulumi.String("user:jane@example.com"), }, Role: pulumi.String("roles/bigtable.user"), }) if err != nil { return err } return nil }) }
```
## google\_bigtable\_instance\_iam\_member
```go package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/bigtable" "github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)
func main() { pulumi.Run(func(ctx *pulumi.Context) error { _, err := bigtable.NewInstanceIamMember(ctx, "editor", &bigtable.InstanceIamMemberArgs{ Instance: pulumi.String("your-bigtable-instance"), Member: pulumi.String("user:jane@example.com"), Role: pulumi.String("roles/bigtable.user"), }) if err != nil { return err } return nil }) }
```
## Import
Instance IAM resources can be imported using the project, instance name, role and/or member.
```sh
$ pulumi import gcp:bigtable/instanceIamBinding:InstanceIamBinding editor "projects/{project}/instances/{instance}"
```
```sh
$ pulumi import gcp:bigtable/instanceIamBinding:InstanceIamBinding editor "projects/{project}/instances/{instance} roles/editor"
```
```sh
$ pulumi import gcp:bigtable/instanceIamBinding:InstanceIamBinding editor "projects/{project}/instances/{instance} roles/editor user:jane@example.com"
```
-> **Custom Roles**If you're importing a IAM resource with a custom role, make sure to use the
full name of the custom role, e.g. `[projects/my-project|organizations/my-org]/roles/my-custom-role`.
func GetInstanceIamBinding ¶
func GetInstanceIamBinding(ctx *pulumi.Context, name string, id pulumi.IDInput, state *InstanceIamBindingState, opts ...pulumi.ResourceOption) (*InstanceIamBinding, error)
GetInstanceIamBinding gets an existing InstanceIamBinding resource's state with the given name, ID, and optional state properties that are used to uniquely qualify the lookup (nil if not required).
func NewInstanceIamBinding ¶
func NewInstanceIamBinding(ctx *pulumi.Context, name string, args *InstanceIamBindingArgs, opts ...pulumi.ResourceOption) (*InstanceIamBinding, error)
NewInstanceIamBinding registers a new resource with the given unique name, arguments, and options.
func (InstanceIamBinding) ElementType ¶ added in v4.4.0
func (InstanceIamBinding) ElementType() reflect.Type
func (InstanceIamBinding) ToInstanceIamBindingOutput ¶ added in v4.4.0
func (i InstanceIamBinding) ToInstanceIamBindingOutput() InstanceIamBindingOutput
func (InstanceIamBinding) ToInstanceIamBindingOutputWithContext ¶ added in v4.4.0
func (i InstanceIamBinding) ToInstanceIamBindingOutputWithContext(ctx context.Context) InstanceIamBindingOutput
type InstanceIamBindingArgs ¶
type InstanceIamBindingArgs struct { Condition InstanceIamBindingConditionPtrInput // The name or relative resource id of the instance to manage IAM policies for. Instance pulumi.StringInput Members pulumi.StringArrayInput // The project in which the instance belongs. If it // is not provided, a default will be supplied. Project pulumi.StringPtrInput // The role that should be applied. Only one // `bigtable.InstanceIamBinding` can be used per role. Note that custom roles must be of the format // `[projects|organizations]/{parent-name}/roles/{role-name}`. Read more about roles [here](https://cloud.google.com/bigtable/docs/access-control#roles). Role pulumi.StringInput }
The set of arguments for constructing a InstanceIamBinding resource.
func (InstanceIamBindingArgs) ElementType ¶
func (InstanceIamBindingArgs) ElementType() reflect.Type
type InstanceIamBindingConditionArgs ¶
type InstanceIamBindingConditionArgs struct { Description pulumi.StringPtrInput `pulumi:"description"` Expression pulumi.StringInput `pulumi:"expression"` Title pulumi.StringInput `pulumi:"title"` }
func (InstanceIamBindingConditionArgs) ElementType ¶
func (InstanceIamBindingConditionArgs) ElementType() reflect.Type
func (InstanceIamBindingConditionArgs) ToInstanceIamBindingConditionOutput ¶
func (i InstanceIamBindingConditionArgs) ToInstanceIamBindingConditionOutput() InstanceIamBindingConditionOutput
func (InstanceIamBindingConditionArgs) ToInstanceIamBindingConditionOutputWithContext ¶
func (i InstanceIamBindingConditionArgs) ToInstanceIamBindingConditionOutputWithContext(ctx context.Context) InstanceIamBindingConditionOutput
func (InstanceIamBindingConditionArgs) ToInstanceIamBindingConditionPtrOutput ¶
func (i InstanceIamBindingConditionArgs) ToInstanceIamBindingConditionPtrOutput() InstanceIamBindingConditionPtrOutput
func (InstanceIamBindingConditionArgs) ToInstanceIamBindingConditionPtrOutputWithContext ¶
func (i InstanceIamBindingConditionArgs) ToInstanceIamBindingConditionPtrOutputWithContext(ctx context.Context) InstanceIamBindingConditionPtrOutput
type InstanceIamBindingConditionInput ¶
type InstanceIamBindingConditionInput interface { pulumi.Input ToInstanceIamBindingConditionOutput() InstanceIamBindingConditionOutput ToInstanceIamBindingConditionOutputWithContext(context.Context) InstanceIamBindingConditionOutput }
InstanceIamBindingConditionInput is an input type that accepts InstanceIamBindingConditionArgs and InstanceIamBindingConditionOutput values. You can construct a concrete instance of `InstanceIamBindingConditionInput` via:
InstanceIamBindingConditionArgs{...}
type InstanceIamBindingConditionOutput ¶
type InstanceIamBindingConditionOutput struct{ *pulumi.OutputState }
func (InstanceIamBindingConditionOutput) Description ¶
func (o InstanceIamBindingConditionOutput) Description() pulumi.StringPtrOutput
func (InstanceIamBindingConditionOutput) ElementType ¶
func (InstanceIamBindingConditionOutput) ElementType() reflect.Type
func (InstanceIamBindingConditionOutput) Expression ¶
func (o InstanceIamBindingConditionOutput) Expression() pulumi.StringOutput
func (InstanceIamBindingConditionOutput) Title ¶
func (o InstanceIamBindingConditionOutput) Title() pulumi.StringOutput
func (InstanceIamBindingConditionOutput) ToInstanceIamBindingConditionOutput ¶
func (o InstanceIamBindingConditionOutput) ToInstanceIamBindingConditionOutput() InstanceIamBindingConditionOutput
func (InstanceIamBindingConditionOutput) ToInstanceIamBindingConditionOutputWithContext ¶
func (o InstanceIamBindingConditionOutput) ToInstanceIamBindingConditionOutputWithContext(ctx context.Context) InstanceIamBindingConditionOutput
func (InstanceIamBindingConditionOutput) ToInstanceIamBindingConditionPtrOutput ¶
func (o InstanceIamBindingConditionOutput) ToInstanceIamBindingConditionPtrOutput() InstanceIamBindingConditionPtrOutput
func (InstanceIamBindingConditionOutput) ToInstanceIamBindingConditionPtrOutputWithContext ¶
func (o InstanceIamBindingConditionOutput) ToInstanceIamBindingConditionPtrOutputWithContext(ctx context.Context) InstanceIamBindingConditionPtrOutput
type InstanceIamBindingConditionPtrInput ¶
type InstanceIamBindingConditionPtrInput interface { pulumi.Input ToInstanceIamBindingConditionPtrOutput() InstanceIamBindingConditionPtrOutput ToInstanceIamBindingConditionPtrOutputWithContext(context.Context) InstanceIamBindingConditionPtrOutput }
InstanceIamBindingConditionPtrInput is an input type that accepts InstanceIamBindingConditionArgs, InstanceIamBindingConditionPtr and InstanceIamBindingConditionPtrOutput values. You can construct a concrete instance of `InstanceIamBindingConditionPtrInput` via:
InstanceIamBindingConditionArgs{...} or: nil
func InstanceIamBindingConditionPtr ¶
func InstanceIamBindingConditionPtr(v *InstanceIamBindingConditionArgs) InstanceIamBindingConditionPtrInput
type InstanceIamBindingConditionPtrOutput ¶
type InstanceIamBindingConditionPtrOutput struct{ *pulumi.OutputState }
func (InstanceIamBindingConditionPtrOutput) Description ¶
func (o InstanceIamBindingConditionPtrOutput) Description() pulumi.StringPtrOutput
func (InstanceIamBindingConditionPtrOutput) ElementType ¶
func (InstanceIamBindingConditionPtrOutput) ElementType() reflect.Type
func (InstanceIamBindingConditionPtrOutput) Expression ¶
func (o InstanceIamBindingConditionPtrOutput) Expression() pulumi.StringPtrOutput
func (InstanceIamBindingConditionPtrOutput) Title ¶
func (o InstanceIamBindingConditionPtrOutput) Title() pulumi.StringPtrOutput
func (InstanceIamBindingConditionPtrOutput) ToInstanceIamBindingConditionPtrOutput ¶
func (o InstanceIamBindingConditionPtrOutput) ToInstanceIamBindingConditionPtrOutput() InstanceIamBindingConditionPtrOutput
func (InstanceIamBindingConditionPtrOutput) ToInstanceIamBindingConditionPtrOutputWithContext ¶
func (o InstanceIamBindingConditionPtrOutput) ToInstanceIamBindingConditionPtrOutputWithContext(ctx context.Context) InstanceIamBindingConditionPtrOutput
type InstanceIamBindingInput ¶ added in v4.4.0
type InstanceIamBindingInput interface { pulumi.Input ToInstanceIamBindingOutput() InstanceIamBindingOutput ToInstanceIamBindingOutputWithContext(ctx context.Context) InstanceIamBindingOutput }
type InstanceIamBindingOutput ¶ added in v4.4.0
type InstanceIamBindingOutput struct {
*pulumi.OutputState
}
func (InstanceIamBindingOutput) ElementType ¶ added in v4.4.0
func (InstanceIamBindingOutput) ElementType() reflect.Type
func (InstanceIamBindingOutput) ToInstanceIamBindingOutput ¶ added in v4.4.0
func (o InstanceIamBindingOutput) ToInstanceIamBindingOutput() InstanceIamBindingOutput
func (InstanceIamBindingOutput) ToInstanceIamBindingOutputWithContext ¶ added in v4.4.0
func (o InstanceIamBindingOutput) ToInstanceIamBindingOutputWithContext(ctx context.Context) InstanceIamBindingOutput
type InstanceIamBindingState ¶
type InstanceIamBindingState struct { Condition InstanceIamBindingConditionPtrInput // (Computed) The etag of the instances's IAM policy. Etag pulumi.StringPtrInput // The name or relative resource id of the instance to manage IAM policies for. Instance pulumi.StringPtrInput Members pulumi.StringArrayInput // The project in which the instance belongs. If it // is not provided, a default will be supplied. Project pulumi.StringPtrInput // The role that should be applied. Only one // `bigtable.InstanceIamBinding` can be used per role. Note that custom roles must be of the format // `[projects|organizations]/{parent-name}/roles/{role-name}`. Read more about roles [here](https://cloud.google.com/bigtable/docs/access-control#roles). Role pulumi.StringPtrInput }
func (InstanceIamBindingState) ElementType ¶
func (InstanceIamBindingState) ElementType() reflect.Type
type InstanceIamMember ¶
type InstanceIamMember struct { pulumi.CustomResourceState Condition InstanceIamMemberConditionPtrOutput `pulumi:"condition"` // (Computed) The etag of the instances's IAM policy. Etag pulumi.StringOutput `pulumi:"etag"` // The name or relative resource id of the instance to manage IAM policies for. Instance pulumi.StringOutput `pulumi:"instance"` Member pulumi.StringOutput `pulumi:"member"` // The project in which the instance belongs. If it // is not provided, a default will be supplied. Project pulumi.StringOutput `pulumi:"project"` // The role that should be applied. Only one // `bigtable.InstanceIamBinding` can be used per role. Note that custom roles must be of the format // `[projects|organizations]/{parent-name}/roles/{role-name}`. Read more about roles [here](https://cloud.google.com/bigtable/docs/access-control#roles). Role pulumi.StringOutput `pulumi:"role"` }
Three different resources help you manage IAM policies on bigtable instances. Each of these resources serves a different use case:
* `bigtable.InstanceIamPolicy`: Authoritative. Sets the IAM policy for the instance and replaces any existing policy already attached. * `bigtable.InstanceIamBinding`: Authoritative for a given role. Updates the IAM policy to grant a role to a list of members. Other roles within the IAM policy for the instance are preserved. * `bigtable.InstanceIamMember`: Non-authoritative. Updates the IAM policy to grant a role to a new member. Other members for the role for the instance are preserved.
> **Note:** `bigtable.InstanceIamPolicy` **cannot** be used in conjunction with `bigtable.InstanceIamBinding` and `bigtable.InstanceIamMember` or they will fight over what your policy should be. In addition, be careful not to accidentally unset ownership of the instance as `bigtable.InstanceIamPolicy` replaces the entire policy.
> **Note:** `bigtable.InstanceIamBinding` resources **can be** used in conjunction with `bigtable.InstanceIamMember` resources **only if** they do not grant privilege to the same role.
## google\_bigtable\_instance\_iam\_policy
```go package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/bigtable" "github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/organizations" "github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)
func main() { pulumi.Run(func(ctx *pulumi.Context) error { admin, err := organizations.LookupIAMPolicy(ctx, &organizations.LookupIAMPolicyArgs{ Bindings: []organizations.GetIAMPolicyBinding{ organizations.GetIAMPolicyBinding{ Role: "roles/bigtable.user", Members: []string{ "user:jane@example.com", }, }, }, }, nil) if err != nil { return err } _, err = bigtable.NewInstanceIamPolicy(ctx, "editor", &bigtable.InstanceIamPolicyArgs{ Project: pulumi.String("your-project"), Instance: pulumi.String("your-bigtable-instance"), PolicyData: pulumi.String(admin.PolicyData), }) if err != nil { return err } return nil }) }
```
## google\_bigtable\_instance\_iam\_binding
```go package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/bigtable" "github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)
func main() { pulumi.Run(func(ctx *pulumi.Context) error { _, err := bigtable.NewInstanceIamBinding(ctx, "editor", &bigtable.InstanceIamBindingArgs{ Instance: pulumi.String("your-bigtable-instance"), Members: pulumi.StringArray{ pulumi.String("user:jane@example.com"), }, Role: pulumi.String("roles/bigtable.user"), }) if err != nil { return err } return nil }) }
```
## google\_bigtable\_instance\_iam\_member
```go package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/bigtable" "github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)
func main() { pulumi.Run(func(ctx *pulumi.Context) error { _, err := bigtable.NewInstanceIamMember(ctx, "editor", &bigtable.InstanceIamMemberArgs{ Instance: pulumi.String("your-bigtable-instance"), Member: pulumi.String("user:jane@example.com"), Role: pulumi.String("roles/bigtable.user"), }) if err != nil { return err } return nil }) }
```
## Import
Instance IAM resources can be imported using the project, instance name, role and/or member.
```sh
$ pulumi import gcp:bigtable/instanceIamMember:InstanceIamMember editor "projects/{project}/instances/{instance}"
```
```sh
$ pulumi import gcp:bigtable/instanceIamMember:InstanceIamMember editor "projects/{project}/instances/{instance} roles/editor"
```
```sh
$ pulumi import gcp:bigtable/instanceIamMember:InstanceIamMember editor "projects/{project}/instances/{instance} roles/editor user:jane@example.com"
```
-> **Custom Roles**If you're importing a IAM resource with a custom role, make sure to use the
full name of the custom role, e.g. `[projects/my-project|organizations/my-org]/roles/my-custom-role`.
func GetInstanceIamMember ¶
func GetInstanceIamMember(ctx *pulumi.Context, name string, id pulumi.IDInput, state *InstanceIamMemberState, opts ...pulumi.ResourceOption) (*InstanceIamMember, error)
GetInstanceIamMember gets an existing InstanceIamMember resource's state with the given name, ID, and optional state properties that are used to uniquely qualify the lookup (nil if not required).
func NewInstanceIamMember ¶
func NewInstanceIamMember(ctx *pulumi.Context, name string, args *InstanceIamMemberArgs, opts ...pulumi.ResourceOption) (*InstanceIamMember, error)
NewInstanceIamMember registers a new resource with the given unique name, arguments, and options.
func (InstanceIamMember) ElementType ¶ added in v4.4.0
func (InstanceIamMember) ElementType() reflect.Type
func (InstanceIamMember) ToInstanceIamMemberOutput ¶ added in v4.4.0
func (i InstanceIamMember) ToInstanceIamMemberOutput() InstanceIamMemberOutput
func (InstanceIamMember) ToInstanceIamMemberOutputWithContext ¶ added in v4.4.0
func (i InstanceIamMember) ToInstanceIamMemberOutputWithContext(ctx context.Context) InstanceIamMemberOutput
type InstanceIamMemberArgs ¶
type InstanceIamMemberArgs struct { Condition InstanceIamMemberConditionPtrInput // The name or relative resource id of the instance to manage IAM policies for. Instance pulumi.StringInput Member pulumi.StringInput // The project in which the instance belongs. If it // is not provided, a default will be supplied. Project pulumi.StringPtrInput // The role that should be applied. Only one // `bigtable.InstanceIamBinding` can be used per role. Note that custom roles must be of the format // `[projects|organizations]/{parent-name}/roles/{role-name}`. Read more about roles [here](https://cloud.google.com/bigtable/docs/access-control#roles). Role pulumi.StringInput }
The set of arguments for constructing a InstanceIamMember resource.
func (InstanceIamMemberArgs) ElementType ¶
func (InstanceIamMemberArgs) ElementType() reflect.Type
type InstanceIamMemberConditionArgs ¶
type InstanceIamMemberConditionArgs struct { Description pulumi.StringPtrInput `pulumi:"description"` Expression pulumi.StringInput `pulumi:"expression"` Title pulumi.StringInput `pulumi:"title"` }
func (InstanceIamMemberConditionArgs) ElementType ¶
func (InstanceIamMemberConditionArgs) ElementType() reflect.Type
func (InstanceIamMemberConditionArgs) ToInstanceIamMemberConditionOutput ¶
func (i InstanceIamMemberConditionArgs) ToInstanceIamMemberConditionOutput() InstanceIamMemberConditionOutput
func (InstanceIamMemberConditionArgs) ToInstanceIamMemberConditionOutputWithContext ¶
func (i InstanceIamMemberConditionArgs) ToInstanceIamMemberConditionOutputWithContext(ctx context.Context) InstanceIamMemberConditionOutput
func (InstanceIamMemberConditionArgs) ToInstanceIamMemberConditionPtrOutput ¶
func (i InstanceIamMemberConditionArgs) ToInstanceIamMemberConditionPtrOutput() InstanceIamMemberConditionPtrOutput
func (InstanceIamMemberConditionArgs) ToInstanceIamMemberConditionPtrOutputWithContext ¶
func (i InstanceIamMemberConditionArgs) ToInstanceIamMemberConditionPtrOutputWithContext(ctx context.Context) InstanceIamMemberConditionPtrOutput
type InstanceIamMemberConditionInput ¶
type InstanceIamMemberConditionInput interface { pulumi.Input ToInstanceIamMemberConditionOutput() InstanceIamMemberConditionOutput ToInstanceIamMemberConditionOutputWithContext(context.Context) InstanceIamMemberConditionOutput }
InstanceIamMemberConditionInput is an input type that accepts InstanceIamMemberConditionArgs and InstanceIamMemberConditionOutput values. You can construct a concrete instance of `InstanceIamMemberConditionInput` via:
InstanceIamMemberConditionArgs{...}
type InstanceIamMemberConditionOutput ¶
type InstanceIamMemberConditionOutput struct{ *pulumi.OutputState }
func (InstanceIamMemberConditionOutput) Description ¶
func (o InstanceIamMemberConditionOutput) Description() pulumi.StringPtrOutput
func (InstanceIamMemberConditionOutput) ElementType ¶
func (InstanceIamMemberConditionOutput) ElementType() reflect.Type
func (InstanceIamMemberConditionOutput) Expression ¶
func (o InstanceIamMemberConditionOutput) Expression() pulumi.StringOutput
func (InstanceIamMemberConditionOutput) Title ¶
func (o InstanceIamMemberConditionOutput) Title() pulumi.StringOutput
func (InstanceIamMemberConditionOutput) ToInstanceIamMemberConditionOutput ¶
func (o InstanceIamMemberConditionOutput) ToInstanceIamMemberConditionOutput() InstanceIamMemberConditionOutput
func (InstanceIamMemberConditionOutput) ToInstanceIamMemberConditionOutputWithContext ¶
func (o InstanceIamMemberConditionOutput) ToInstanceIamMemberConditionOutputWithContext(ctx context.Context) InstanceIamMemberConditionOutput
func (InstanceIamMemberConditionOutput) ToInstanceIamMemberConditionPtrOutput ¶
func (o InstanceIamMemberConditionOutput) ToInstanceIamMemberConditionPtrOutput() InstanceIamMemberConditionPtrOutput
func (InstanceIamMemberConditionOutput) ToInstanceIamMemberConditionPtrOutputWithContext ¶
func (o InstanceIamMemberConditionOutput) ToInstanceIamMemberConditionPtrOutputWithContext(ctx context.Context) InstanceIamMemberConditionPtrOutput
type InstanceIamMemberConditionPtrInput ¶
type InstanceIamMemberConditionPtrInput interface { pulumi.Input ToInstanceIamMemberConditionPtrOutput() InstanceIamMemberConditionPtrOutput ToInstanceIamMemberConditionPtrOutputWithContext(context.Context) InstanceIamMemberConditionPtrOutput }
InstanceIamMemberConditionPtrInput is an input type that accepts InstanceIamMemberConditionArgs, InstanceIamMemberConditionPtr and InstanceIamMemberConditionPtrOutput values. You can construct a concrete instance of `InstanceIamMemberConditionPtrInput` via:
InstanceIamMemberConditionArgs{...} or: nil
func InstanceIamMemberConditionPtr ¶
func InstanceIamMemberConditionPtr(v *InstanceIamMemberConditionArgs) InstanceIamMemberConditionPtrInput
type InstanceIamMemberConditionPtrOutput ¶
type InstanceIamMemberConditionPtrOutput struct{ *pulumi.OutputState }
func (InstanceIamMemberConditionPtrOutput) Description ¶
func (o InstanceIamMemberConditionPtrOutput) Description() pulumi.StringPtrOutput
func (InstanceIamMemberConditionPtrOutput) Elem ¶
func (o InstanceIamMemberConditionPtrOutput) Elem() InstanceIamMemberConditionOutput
func (InstanceIamMemberConditionPtrOutput) ElementType ¶
func (InstanceIamMemberConditionPtrOutput) ElementType() reflect.Type
func (InstanceIamMemberConditionPtrOutput) Expression ¶
func (o InstanceIamMemberConditionPtrOutput) Expression() pulumi.StringPtrOutput
func (InstanceIamMemberConditionPtrOutput) Title ¶
func (o InstanceIamMemberConditionPtrOutput) Title() pulumi.StringPtrOutput
func (InstanceIamMemberConditionPtrOutput) ToInstanceIamMemberConditionPtrOutput ¶
func (o InstanceIamMemberConditionPtrOutput) ToInstanceIamMemberConditionPtrOutput() InstanceIamMemberConditionPtrOutput
func (InstanceIamMemberConditionPtrOutput) ToInstanceIamMemberConditionPtrOutputWithContext ¶
func (o InstanceIamMemberConditionPtrOutput) ToInstanceIamMemberConditionPtrOutputWithContext(ctx context.Context) InstanceIamMemberConditionPtrOutput
type InstanceIamMemberInput ¶ added in v4.4.0
type InstanceIamMemberInput interface { pulumi.Input ToInstanceIamMemberOutput() InstanceIamMemberOutput ToInstanceIamMemberOutputWithContext(ctx context.Context) InstanceIamMemberOutput }
type InstanceIamMemberOutput ¶ added in v4.4.0
type InstanceIamMemberOutput struct {
*pulumi.OutputState
}
func (InstanceIamMemberOutput) ElementType ¶ added in v4.4.0
func (InstanceIamMemberOutput) ElementType() reflect.Type
func (InstanceIamMemberOutput) ToInstanceIamMemberOutput ¶ added in v4.4.0
func (o InstanceIamMemberOutput) ToInstanceIamMemberOutput() InstanceIamMemberOutput
func (InstanceIamMemberOutput) ToInstanceIamMemberOutputWithContext ¶ added in v4.4.0
func (o InstanceIamMemberOutput) ToInstanceIamMemberOutputWithContext(ctx context.Context) InstanceIamMemberOutput
type InstanceIamMemberState ¶
type InstanceIamMemberState struct { Condition InstanceIamMemberConditionPtrInput // (Computed) The etag of the instances's IAM policy. Etag pulumi.StringPtrInput // The name or relative resource id of the instance to manage IAM policies for. Instance pulumi.StringPtrInput Member pulumi.StringPtrInput // The project in which the instance belongs. If it // is not provided, a default will be supplied. Project pulumi.StringPtrInput // The role that should be applied. Only one // `bigtable.InstanceIamBinding` can be used per role. Note that custom roles must be of the format // `[projects|organizations]/{parent-name}/roles/{role-name}`. Read more about roles [here](https://cloud.google.com/bigtable/docs/access-control#roles). Role pulumi.StringPtrInput }
func (InstanceIamMemberState) ElementType ¶
func (InstanceIamMemberState) ElementType() reflect.Type
type InstanceIamPolicy ¶
type InstanceIamPolicy struct { pulumi.CustomResourceState // (Computed) The etag of the instances's IAM policy. Etag pulumi.StringOutput `pulumi:"etag"` // The name or relative resource id of the instance to manage IAM policies for. Instance pulumi.StringOutput `pulumi:"instance"` // The policy data generated by a `organizations.getIAMPolicy` data source. PolicyData pulumi.StringOutput `pulumi:"policyData"` // The project in which the instance belongs. If it // is not provided, a default will be supplied. Project pulumi.StringOutput `pulumi:"project"` }
Three different resources help you manage IAM policies on bigtable instances. Each of these resources serves a different use case:
* `bigtable.InstanceIamPolicy`: Authoritative. Sets the IAM policy for the instance and replaces any existing policy already attached. * `bigtable.InstanceIamBinding`: Authoritative for a given role. Updates the IAM policy to grant a role to a list of members. Other roles within the IAM policy for the instance are preserved. * `bigtable.InstanceIamMember`: Non-authoritative. Updates the IAM policy to grant a role to a new member. Other members for the role for the instance are preserved.
> **Note:** `bigtable.InstanceIamPolicy` **cannot** be used in conjunction with `bigtable.InstanceIamBinding` and `bigtable.InstanceIamMember` or they will fight over what your policy should be. In addition, be careful not to accidentally unset ownership of the instance as `bigtable.InstanceIamPolicy` replaces the entire policy.
> **Note:** `bigtable.InstanceIamBinding` resources **can be** used in conjunction with `bigtable.InstanceIamMember` resources **only if** they do not grant privilege to the same role.
## google\_bigtable\_instance\_iam\_policy
```go package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/bigtable" "github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/organizations" "github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)
func main() { pulumi.Run(func(ctx *pulumi.Context) error { admin, err := organizations.LookupIAMPolicy(ctx, &organizations.LookupIAMPolicyArgs{ Bindings: []organizations.GetIAMPolicyBinding{ organizations.GetIAMPolicyBinding{ Role: "roles/bigtable.user", Members: []string{ "user:jane@example.com", }, }, }, }, nil) if err != nil { return err } _, err = bigtable.NewInstanceIamPolicy(ctx, "editor", &bigtable.InstanceIamPolicyArgs{ Project: pulumi.String("your-project"), Instance: pulumi.String("your-bigtable-instance"), PolicyData: pulumi.String(admin.PolicyData), }) if err != nil { return err } return nil }) }
```
## google\_bigtable\_instance\_iam\_binding
```go package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/bigtable" "github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)
func main() { pulumi.Run(func(ctx *pulumi.Context) error { _, err := bigtable.NewInstanceIamBinding(ctx, "editor", &bigtable.InstanceIamBindingArgs{ Instance: pulumi.String("your-bigtable-instance"), Members: pulumi.StringArray{ pulumi.String("user:jane@example.com"), }, Role: pulumi.String("roles/bigtable.user"), }) if err != nil { return err } return nil }) }
```
## google\_bigtable\_instance\_iam\_member
```go package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/bigtable" "github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)
func main() { pulumi.Run(func(ctx *pulumi.Context) error { _, err := bigtable.NewInstanceIamMember(ctx, "editor", &bigtable.InstanceIamMemberArgs{ Instance: pulumi.String("your-bigtable-instance"), Member: pulumi.String("user:jane@example.com"), Role: pulumi.String("roles/bigtable.user"), }) if err != nil { return err } return nil }) }
```
## Import
Instance IAM resources can be imported using the project, instance name, role and/or member.
```sh
$ pulumi import gcp:bigtable/instanceIamPolicy:InstanceIamPolicy editor "projects/{project}/instances/{instance}"
```
```sh
$ pulumi import gcp:bigtable/instanceIamPolicy:InstanceIamPolicy editor "projects/{project}/instances/{instance} roles/editor"
```
```sh
$ pulumi import gcp:bigtable/instanceIamPolicy:InstanceIamPolicy editor "projects/{project}/instances/{instance} roles/editor user:jane@example.com"
```
-> **Custom Roles**If you're importing a IAM resource with a custom role, make sure to use the
full name of the custom role, e.g. `[projects/my-project|organizations/my-org]/roles/my-custom-role`.
func GetInstanceIamPolicy ¶
func GetInstanceIamPolicy(ctx *pulumi.Context, name string, id pulumi.IDInput, state *InstanceIamPolicyState, opts ...pulumi.ResourceOption) (*InstanceIamPolicy, error)
GetInstanceIamPolicy gets an existing InstanceIamPolicy resource's state with the given name, ID, and optional state properties that are used to uniquely qualify the lookup (nil if not required).
func NewInstanceIamPolicy ¶
func NewInstanceIamPolicy(ctx *pulumi.Context, name string, args *InstanceIamPolicyArgs, opts ...pulumi.ResourceOption) (*InstanceIamPolicy, error)
NewInstanceIamPolicy registers a new resource with the given unique name, arguments, and options.
func (InstanceIamPolicy) ElementType ¶ added in v4.4.0
func (InstanceIamPolicy) ElementType() reflect.Type
func (InstanceIamPolicy) ToInstanceIamPolicyOutput ¶ added in v4.4.0
func (i InstanceIamPolicy) ToInstanceIamPolicyOutput() InstanceIamPolicyOutput
func (InstanceIamPolicy) ToInstanceIamPolicyOutputWithContext ¶ added in v4.4.0
func (i InstanceIamPolicy) ToInstanceIamPolicyOutputWithContext(ctx context.Context) InstanceIamPolicyOutput
type InstanceIamPolicyArgs ¶
type InstanceIamPolicyArgs struct { // The name or relative resource id of the instance to manage IAM policies for. Instance pulumi.StringInput // The policy data generated by a `organizations.getIAMPolicy` data source. PolicyData pulumi.StringInput // The project in which the instance belongs. If it // is not provided, a default will be supplied. Project pulumi.StringPtrInput }
The set of arguments for constructing a InstanceIamPolicy resource.
func (InstanceIamPolicyArgs) ElementType ¶
func (InstanceIamPolicyArgs) ElementType() reflect.Type
type InstanceIamPolicyInput ¶ added in v4.4.0
type InstanceIamPolicyInput interface { pulumi.Input ToInstanceIamPolicyOutput() InstanceIamPolicyOutput ToInstanceIamPolicyOutputWithContext(ctx context.Context) InstanceIamPolicyOutput }
type InstanceIamPolicyOutput ¶ added in v4.4.0
type InstanceIamPolicyOutput struct {
*pulumi.OutputState
}
func (InstanceIamPolicyOutput) ElementType ¶ added in v4.4.0
func (InstanceIamPolicyOutput) ElementType() reflect.Type
func (InstanceIamPolicyOutput) ToInstanceIamPolicyOutput ¶ added in v4.4.0
func (o InstanceIamPolicyOutput) ToInstanceIamPolicyOutput() InstanceIamPolicyOutput
func (InstanceIamPolicyOutput) ToInstanceIamPolicyOutputWithContext ¶ added in v4.4.0
func (o InstanceIamPolicyOutput) ToInstanceIamPolicyOutputWithContext(ctx context.Context) InstanceIamPolicyOutput
type InstanceIamPolicyState ¶
type InstanceIamPolicyState struct { // (Computed) The etag of the instances's IAM policy. Etag pulumi.StringPtrInput // The name or relative resource id of the instance to manage IAM policies for. Instance pulumi.StringPtrInput // The policy data generated by a `organizations.getIAMPolicy` data source. PolicyData pulumi.StringPtrInput // The project in which the instance belongs. If it // is not provided, a default will be supplied. Project pulumi.StringPtrInput }
func (InstanceIamPolicyState) ElementType ¶
func (InstanceIamPolicyState) ElementType() reflect.Type
type InstanceInput ¶ added in v4.4.0
type InstanceInput interface { pulumi.Input ToInstanceOutput() InstanceOutput ToInstanceOutputWithContext(ctx context.Context) InstanceOutput }
type InstanceOutput ¶ added in v4.4.0
type InstanceOutput struct {
*pulumi.OutputState
}
func (InstanceOutput) ElementType ¶ added in v4.4.0
func (InstanceOutput) ElementType() reflect.Type
func (InstanceOutput) ToInstanceOutput ¶ added in v4.4.0
func (o InstanceOutput) ToInstanceOutput() InstanceOutput
func (InstanceOutput) ToInstanceOutputWithContext ¶ added in v4.4.0
func (o InstanceOutput) ToInstanceOutputWithContext(ctx context.Context) InstanceOutput
type InstanceState ¶
type InstanceState struct { // A block of cluster configuration options. This can be specified at least once, and up to 4 times. // See structure below. Clusters InstanceClusterArrayInput // Whether or not to allow this provider to destroy the instance. Unless this field is set to false // in the statefile, a `pulumi destroy` or `pulumi up` that would delete the instance will fail. DeletionProtection pulumi.BoolPtrInput // The human-readable display name of the Bigtable instance. Defaults to the instance `name`. DisplayName pulumi.StringPtrInput // The instance type to create. One of `"DEVELOPMENT"` or `"PRODUCTION"`. Defaults to `"PRODUCTION"`. // It is recommended to leave this field unspecified since the distinction between `"DEVELOPMENT"` and `"PRODUCTION"` instances is going away, // and all instances will become `"PRODUCTION"` instances. This means that new and existing `"DEVELOPMENT"` instances will be converted to // `"PRODUCTION"` instances. It is recommended for users to use `"PRODUCTION"` instances in any case, since a 1-node `"PRODUCTION"` instance // is functionally identical to a `"DEVELOPMENT"` instance, but without the accompanying restrictions. // // Deprecated: It is recommended to leave this field unspecified since the distinction between "DEVELOPMENT" and "PRODUCTION" instances is going away, and all instances will become "PRODUCTION" instances. This means that new and existing "DEVELOPMENT" instances will be converted to "PRODUCTION" instances. It is recommended for users to use "PRODUCTION" instances in any case, since a 1-node "PRODUCTION" instance is functionally identical to a "DEVELOPMENT" instance, but without the accompanying restrictions. InstanceType pulumi.StringPtrInput // A set of key/value label pairs to assign to the resource. Label keys must follow the requirements at https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements. Labels pulumi.StringMapInput // The name (also called Instance Id in the Cloud Console) of the Cloud Bigtable instance. Name pulumi.StringPtrInput // The ID of the project in which the resource belongs. If it // is not provided, the provider project is used. Project pulumi.StringPtrInput }
func (InstanceState) ElementType ¶
func (InstanceState) ElementType() reflect.Type
type Table ¶
type Table struct { pulumi.CustomResourceState // A group of columns within a table which share a common configuration. This can be specified multiple times. Structure is documented below. ColumnFamilies TableColumnFamilyArrayOutput `pulumi:"columnFamilies"` // The name of the Bigtable instance. InstanceName pulumi.StringOutput `pulumi:"instanceName"` // The name of the table. Name pulumi.StringOutput `pulumi:"name"` // The ID of the project in which the resource belongs. If it // is not provided, the provider project is used. Project pulumi.StringOutput `pulumi:"project"` // A list of predefined keys to split the table on. // !> **Warning:** Modifying the `splitKeys` of an existing table will cause the provider // to delete/recreate the entire `bigtable.Table` resource. SplitKeys pulumi.StringArrayOutput `pulumi:"splitKeys"` }
Creates a Google Cloud Bigtable table inside an instance. For more information see [the official documentation](https://cloud.google.com/bigtable/) and [API](https://cloud.google.com/bigtable/docs/go/reference).
## Example Usage
```go package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/bigtable" "github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)
func main() { pulumi.Run(func(ctx *pulumi.Context) error { instance, err := bigtable.NewInstance(ctx, "instance", &bigtable.InstanceArgs{ Clusters: bigtable.InstanceClusterArray{ &bigtable.InstanceClusterArgs{ ClusterId: pulumi.String("tf-instance-cluster"), Zone: pulumi.String("us-central1-b"), NumNodes: pulumi.Int(3), StorageType: pulumi.String("HDD"), }, }, }) if err != nil { return err } _, err = bigtable.NewTable(ctx, "table", &bigtable.TableArgs{ InstanceName: instance.Name, SplitKeys: pulumi.StringArray{ pulumi.String("a"), pulumi.String("b"), pulumi.String("c"), }, }) if err != nil { return err } return nil }) }
```
## Import
Bigtable Tables can be imported using any of these accepted formats ¶
```sh
$ pulumi import gcp:bigtable/table:Table default projects/{{project}}/instances/{{instance_name}}/tables/{{name}}
```
```sh
$ pulumi import gcp:bigtable/table:Table default {{project}}/{{instance_name}}/{{name}}
```
```sh
$ pulumi import gcp:bigtable/table:Table default {{instance_name}}/{{name}}
```
The following fields can't be read and will show diffs if set in config when imported- `split_keys`
func GetTable ¶
func GetTable(ctx *pulumi.Context, name string, id pulumi.IDInput, state *TableState, opts ...pulumi.ResourceOption) (*Table, error)
GetTable gets an existing Table resource's state with the given name, ID, and optional state properties that are used to uniquely qualify the lookup (nil if not required).
func NewTable ¶
func NewTable(ctx *pulumi.Context, name string, args *TableArgs, opts ...pulumi.ResourceOption) (*Table, error)
NewTable registers a new resource with the given unique name, arguments, and options.
func (Table) ElementType ¶ added in v4.4.0
func (Table) ToTableOutput ¶ added in v4.4.0
func (i Table) ToTableOutput() TableOutput
func (Table) ToTableOutputWithContext ¶ added in v4.4.0
func (i Table) ToTableOutputWithContext(ctx context.Context) TableOutput
type TableArgs ¶
type TableArgs struct { // A group of columns within a table which share a common configuration. This can be specified multiple times. Structure is documented below. ColumnFamilies TableColumnFamilyArrayInput // The name of the Bigtable instance. InstanceName pulumi.StringInput // The name of the table. Name pulumi.StringPtrInput // The ID of the project in which the resource belongs. If it // is not provided, the provider project is used. Project pulumi.StringPtrInput // A list of predefined keys to split the table on. // !> **Warning:** Modifying the `splitKeys` of an existing table will cause the provider // to delete/recreate the entire `bigtable.Table` resource. SplitKeys pulumi.StringArrayInput }
The set of arguments for constructing a Table resource.
func (TableArgs) ElementType ¶
type TableColumnFamily ¶
type TableColumnFamily struct { // The name of the column family. Family string `pulumi:"family"` }
type TableColumnFamilyArgs ¶
type TableColumnFamilyArgs struct { // The name of the column family. Family pulumi.StringInput `pulumi:"family"` }
func (TableColumnFamilyArgs) ElementType ¶
func (TableColumnFamilyArgs) ElementType() reflect.Type
func (TableColumnFamilyArgs) ToTableColumnFamilyOutput ¶
func (i TableColumnFamilyArgs) ToTableColumnFamilyOutput() TableColumnFamilyOutput
func (TableColumnFamilyArgs) ToTableColumnFamilyOutputWithContext ¶
func (i TableColumnFamilyArgs) ToTableColumnFamilyOutputWithContext(ctx context.Context) TableColumnFamilyOutput
type TableColumnFamilyArray ¶
type TableColumnFamilyArray []TableColumnFamilyInput
func (TableColumnFamilyArray) ElementType ¶
func (TableColumnFamilyArray) ElementType() reflect.Type
func (TableColumnFamilyArray) ToTableColumnFamilyArrayOutput ¶
func (i TableColumnFamilyArray) ToTableColumnFamilyArrayOutput() TableColumnFamilyArrayOutput
func (TableColumnFamilyArray) ToTableColumnFamilyArrayOutputWithContext ¶
func (i TableColumnFamilyArray) ToTableColumnFamilyArrayOutputWithContext(ctx context.Context) TableColumnFamilyArrayOutput
type TableColumnFamilyArrayInput ¶
type TableColumnFamilyArrayInput interface { pulumi.Input ToTableColumnFamilyArrayOutput() TableColumnFamilyArrayOutput ToTableColumnFamilyArrayOutputWithContext(context.Context) TableColumnFamilyArrayOutput }
TableColumnFamilyArrayInput is an input type that accepts TableColumnFamilyArray and TableColumnFamilyArrayOutput values. You can construct a concrete instance of `TableColumnFamilyArrayInput` via:
TableColumnFamilyArray{ TableColumnFamilyArgs{...} }
type TableColumnFamilyArrayOutput ¶
type TableColumnFamilyArrayOutput struct{ *pulumi.OutputState }
func (TableColumnFamilyArrayOutput) ElementType ¶
func (TableColumnFamilyArrayOutput) ElementType() reflect.Type
func (TableColumnFamilyArrayOutput) Index ¶
func (o TableColumnFamilyArrayOutput) Index(i pulumi.IntInput) TableColumnFamilyOutput
func (TableColumnFamilyArrayOutput) ToTableColumnFamilyArrayOutput ¶
func (o TableColumnFamilyArrayOutput) ToTableColumnFamilyArrayOutput() TableColumnFamilyArrayOutput
func (TableColumnFamilyArrayOutput) ToTableColumnFamilyArrayOutputWithContext ¶
func (o TableColumnFamilyArrayOutput) ToTableColumnFamilyArrayOutputWithContext(ctx context.Context) TableColumnFamilyArrayOutput
type TableColumnFamilyInput ¶
type TableColumnFamilyInput interface { pulumi.Input ToTableColumnFamilyOutput() TableColumnFamilyOutput ToTableColumnFamilyOutputWithContext(context.Context) TableColumnFamilyOutput }
TableColumnFamilyInput is an input type that accepts TableColumnFamilyArgs and TableColumnFamilyOutput values. You can construct a concrete instance of `TableColumnFamilyInput` via:
TableColumnFamilyArgs{...}
type TableColumnFamilyOutput ¶
type TableColumnFamilyOutput struct{ *pulumi.OutputState }
func (TableColumnFamilyOutput) ElementType ¶
func (TableColumnFamilyOutput) ElementType() reflect.Type
func (TableColumnFamilyOutput) Family ¶
func (o TableColumnFamilyOutput) Family() pulumi.StringOutput
The name of the column family.
func (TableColumnFamilyOutput) ToTableColumnFamilyOutput ¶
func (o TableColumnFamilyOutput) ToTableColumnFamilyOutput() TableColumnFamilyOutput
func (TableColumnFamilyOutput) ToTableColumnFamilyOutputWithContext ¶
func (o TableColumnFamilyOutput) ToTableColumnFamilyOutputWithContext(ctx context.Context) TableColumnFamilyOutput
type TableIamBinding ¶
type TableIamBinding struct { pulumi.CustomResourceState Condition TableIamBindingConditionPtrOutput `pulumi:"condition"` // (Computed) The etag of the tables's IAM policy. Etag pulumi.StringOutput `pulumi:"etag"` // The name or relative resource id of the instance that owns the table. Instance pulumi.StringOutput `pulumi:"instance"` Members pulumi.StringArrayOutput `pulumi:"members"` Project pulumi.StringOutput `pulumi:"project"` // The role that should be applied. Only one // `bigtable.TableIamBinding` can be used per role. Note that custom roles must be of the format // `[projects|organizations]/{parent-name}/roles/{role-name}`. Read more about roles [here](https://cloud.google.com/bigtable/docs/access-control#roles). Role pulumi.StringOutput `pulumi:"role"` // The name or relative resource id of the table to manage IAM policies for. Table pulumi.StringOutput `pulumi:"table"` }
Three different resources help you manage IAM policies on bigtable tables. Each of these resources serves a different use case:
* `bigtable.TableIamPolicy`: Authoritative. Sets the IAM policy for the tables and replaces any existing policy already attached. * `bigtable.TableIamBinding`: Authoritative for a given role. Updates the IAM policy to grant a role to a list of members. Other roles within the IAM policy for the table are preserved. * `bigtable.TableIamMember`: Non-authoritative. Updates the IAM policy to grant a role to a new member. Other members for the role for the table are preserved.
> **Note:** `bigtable.TableIamPolicy` **cannot** be used in conjunction with `bigtable.TableIamBinding` and `bigtable.TableIamMember` or they will fight over what your policy should be. In addition, be careful not to accidentally unset ownership of the table as `bigtable.TableIamPolicy` replaces the entire policy.
> **Note:** `bigtable.TableIamBinding` resources **can be** used in conjunction with `bigtable.TableIamMember` resources **only if** they do not grant privilege to the same role.
## google\_bigtable\_instance\_iam\_policy
```go package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/bigtable" "github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/organizations" "github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)
func main() { pulumi.Run(func(ctx *pulumi.Context) error { admin, err := organizations.LookupIAMPolicy(ctx, &organizations.LookupIAMPolicyArgs{ Bindings: []organizations.GetIAMPolicyBinding{ organizations.GetIAMPolicyBinding{ Role: "roles/bigtable.user", Members: []string{ "user:jane@example.com", }, }, }, }, nil) if err != nil { return err } _, err = bigtable.NewTableIamPolicy(ctx, "editor", &bigtable.TableIamPolicyArgs{ Project: pulumi.String("your-project"), Instance: pulumi.String("your-bigtable-instance"), Table: pulumi.String("your-bigtable-table"), PolicyData: pulumi.String(admin.PolicyData), }) if err != nil { return err } return nil }) }
```
## google\_bigtable\_instance\_iam\_binding
```go package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/bigtable" "github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)
func main() { pulumi.Run(func(ctx *pulumi.Context) error { _, err := bigtable.NewTableIamBinding(ctx, "editor", &bigtable.TableIamBindingArgs{ Instance: pulumi.String("your-bigtable-instance"), Members: pulumi.StringArray{ pulumi.String("user:jane@example.com"), }, Role: pulumi.String("roles/bigtable.user"), Table: pulumi.String("your-bigtable-table"), }) if err != nil { return err } return nil }) }
```
## google\_bigtable\_instance\_iam\_member
```go package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/bigtable" "github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)
func main() { pulumi.Run(func(ctx *pulumi.Context) error { _, err := bigtable.NewTableIamMember(ctx, "editor", &bigtable.TableIamMemberArgs{ Instance: pulumi.String("your-bigtable-instance"), Member: pulumi.String("user:jane@example.com"), Role: pulumi.String("roles/bigtable.user"), Table: pulumi.String("your-bigtable-table"), }) if err != nil { return err } return nil }) }
```
## Import
Instance IAM resources can be imported using the project, table name, role and/or member.
```sh
$ pulumi import gcp:bigtable/tableIamBinding:TableIamBinding editor "projects/{project}/tables/{table}"
```
```sh
$ pulumi import gcp:bigtable/tableIamBinding:TableIamBinding editor "projects/{project}/tables/{table} roles/editor"
```
```sh
$ pulumi import gcp:bigtable/tableIamBinding:TableIamBinding editor "projects/{project}/tables/{table} roles/editor user:jane@example.com"
```
-> **Custom Roles**If you're importing a IAM resource with a custom role, make sure to use the
full name of the custom role, e.g. `[projects/my-project|organizations/my-org]/roles/my-custom-role`.
func GetTableIamBinding ¶
func GetTableIamBinding(ctx *pulumi.Context, name string, id pulumi.IDInput, state *TableIamBindingState, opts ...pulumi.ResourceOption) (*TableIamBinding, error)
GetTableIamBinding gets an existing TableIamBinding resource's state with the given name, ID, and optional state properties that are used to uniquely qualify the lookup (nil if not required).
func NewTableIamBinding ¶
func NewTableIamBinding(ctx *pulumi.Context, name string, args *TableIamBindingArgs, opts ...pulumi.ResourceOption) (*TableIamBinding, error)
NewTableIamBinding registers a new resource with the given unique name, arguments, and options.
func (TableIamBinding) ElementType ¶ added in v4.4.0
func (TableIamBinding) ElementType() reflect.Type
func (TableIamBinding) ToTableIamBindingOutput ¶ added in v4.4.0
func (i TableIamBinding) ToTableIamBindingOutput() TableIamBindingOutput
func (TableIamBinding) ToTableIamBindingOutputWithContext ¶ added in v4.4.0
func (i TableIamBinding) ToTableIamBindingOutputWithContext(ctx context.Context) TableIamBindingOutput
type TableIamBindingArgs ¶
type TableIamBindingArgs struct { Condition TableIamBindingConditionPtrInput // The name or relative resource id of the instance that owns the table. Instance pulumi.StringInput Members pulumi.StringArrayInput Project pulumi.StringPtrInput // The role that should be applied. Only one // `bigtable.TableIamBinding` can be used per role. Note that custom roles must be of the format // `[projects|organizations]/{parent-name}/roles/{role-name}`. Read more about roles [here](https://cloud.google.com/bigtable/docs/access-control#roles). Role pulumi.StringInput // The name or relative resource id of the table to manage IAM policies for. Table pulumi.StringInput }
The set of arguments for constructing a TableIamBinding resource.
func (TableIamBindingArgs) ElementType ¶
func (TableIamBindingArgs) ElementType() reflect.Type
type TableIamBindingConditionArgs ¶
type TableIamBindingConditionArgs struct { Description pulumi.StringPtrInput `pulumi:"description"` Expression pulumi.StringInput `pulumi:"expression"` Title pulumi.StringInput `pulumi:"title"` }
func (TableIamBindingConditionArgs) ElementType ¶
func (TableIamBindingConditionArgs) ElementType() reflect.Type
func (TableIamBindingConditionArgs) ToTableIamBindingConditionOutput ¶
func (i TableIamBindingConditionArgs) ToTableIamBindingConditionOutput() TableIamBindingConditionOutput
func (TableIamBindingConditionArgs) ToTableIamBindingConditionOutputWithContext ¶
func (i TableIamBindingConditionArgs) ToTableIamBindingConditionOutputWithContext(ctx context.Context) TableIamBindingConditionOutput
func (TableIamBindingConditionArgs) ToTableIamBindingConditionPtrOutput ¶
func (i TableIamBindingConditionArgs) ToTableIamBindingConditionPtrOutput() TableIamBindingConditionPtrOutput
func (TableIamBindingConditionArgs) ToTableIamBindingConditionPtrOutputWithContext ¶
func (i TableIamBindingConditionArgs) ToTableIamBindingConditionPtrOutputWithContext(ctx context.Context) TableIamBindingConditionPtrOutput
type TableIamBindingConditionInput ¶
type TableIamBindingConditionInput interface { pulumi.Input ToTableIamBindingConditionOutput() TableIamBindingConditionOutput ToTableIamBindingConditionOutputWithContext(context.Context) TableIamBindingConditionOutput }
TableIamBindingConditionInput is an input type that accepts TableIamBindingConditionArgs and TableIamBindingConditionOutput values. You can construct a concrete instance of `TableIamBindingConditionInput` via:
TableIamBindingConditionArgs{...}
type TableIamBindingConditionOutput ¶
type TableIamBindingConditionOutput struct{ *pulumi.OutputState }
func (TableIamBindingConditionOutput) Description ¶
func (o TableIamBindingConditionOutput) Description() pulumi.StringPtrOutput
func (TableIamBindingConditionOutput) ElementType ¶
func (TableIamBindingConditionOutput) ElementType() reflect.Type
func (TableIamBindingConditionOutput) Expression ¶
func (o TableIamBindingConditionOutput) Expression() pulumi.StringOutput
func (TableIamBindingConditionOutput) Title ¶
func (o TableIamBindingConditionOutput) Title() pulumi.StringOutput
func (TableIamBindingConditionOutput) ToTableIamBindingConditionOutput ¶
func (o TableIamBindingConditionOutput) ToTableIamBindingConditionOutput() TableIamBindingConditionOutput
func (TableIamBindingConditionOutput) ToTableIamBindingConditionOutputWithContext ¶
func (o TableIamBindingConditionOutput) ToTableIamBindingConditionOutputWithContext(ctx context.Context) TableIamBindingConditionOutput
func (TableIamBindingConditionOutput) ToTableIamBindingConditionPtrOutput ¶
func (o TableIamBindingConditionOutput) ToTableIamBindingConditionPtrOutput() TableIamBindingConditionPtrOutput
func (TableIamBindingConditionOutput) ToTableIamBindingConditionPtrOutputWithContext ¶
func (o TableIamBindingConditionOutput) ToTableIamBindingConditionPtrOutputWithContext(ctx context.Context) TableIamBindingConditionPtrOutput
type TableIamBindingConditionPtrInput ¶
type TableIamBindingConditionPtrInput interface { pulumi.Input ToTableIamBindingConditionPtrOutput() TableIamBindingConditionPtrOutput ToTableIamBindingConditionPtrOutputWithContext(context.Context) TableIamBindingConditionPtrOutput }
TableIamBindingConditionPtrInput is an input type that accepts TableIamBindingConditionArgs, TableIamBindingConditionPtr and TableIamBindingConditionPtrOutput values. You can construct a concrete instance of `TableIamBindingConditionPtrInput` via:
TableIamBindingConditionArgs{...} or: nil
func TableIamBindingConditionPtr ¶
func TableIamBindingConditionPtr(v *TableIamBindingConditionArgs) TableIamBindingConditionPtrInput
type TableIamBindingConditionPtrOutput ¶
type TableIamBindingConditionPtrOutput struct{ *pulumi.OutputState }
func (TableIamBindingConditionPtrOutput) Description ¶
func (o TableIamBindingConditionPtrOutput) Description() pulumi.StringPtrOutput
func (TableIamBindingConditionPtrOutput) Elem ¶
func (o TableIamBindingConditionPtrOutput) Elem() TableIamBindingConditionOutput
func (TableIamBindingConditionPtrOutput) ElementType ¶
func (TableIamBindingConditionPtrOutput) ElementType() reflect.Type
func (TableIamBindingConditionPtrOutput) Expression ¶
func (o TableIamBindingConditionPtrOutput) Expression() pulumi.StringPtrOutput
func (TableIamBindingConditionPtrOutput) Title ¶
func (o TableIamBindingConditionPtrOutput) Title() pulumi.StringPtrOutput
func (TableIamBindingConditionPtrOutput) ToTableIamBindingConditionPtrOutput ¶
func (o TableIamBindingConditionPtrOutput) ToTableIamBindingConditionPtrOutput() TableIamBindingConditionPtrOutput
func (TableIamBindingConditionPtrOutput) ToTableIamBindingConditionPtrOutputWithContext ¶
func (o TableIamBindingConditionPtrOutput) ToTableIamBindingConditionPtrOutputWithContext(ctx context.Context) TableIamBindingConditionPtrOutput
type TableIamBindingInput ¶ added in v4.4.0
type TableIamBindingInput interface { pulumi.Input ToTableIamBindingOutput() TableIamBindingOutput ToTableIamBindingOutputWithContext(ctx context.Context) TableIamBindingOutput }
type TableIamBindingOutput ¶ added in v4.4.0
type TableIamBindingOutput struct {
*pulumi.OutputState
}
func (TableIamBindingOutput) ElementType ¶ added in v4.4.0
func (TableIamBindingOutput) ElementType() reflect.Type
func (TableIamBindingOutput) ToTableIamBindingOutput ¶ added in v4.4.0
func (o TableIamBindingOutput) ToTableIamBindingOutput() TableIamBindingOutput
func (TableIamBindingOutput) ToTableIamBindingOutputWithContext ¶ added in v4.4.0
func (o TableIamBindingOutput) ToTableIamBindingOutputWithContext(ctx context.Context) TableIamBindingOutput
type TableIamBindingState ¶
type TableIamBindingState struct { Condition TableIamBindingConditionPtrInput // (Computed) The etag of the tables's IAM policy. Etag pulumi.StringPtrInput // The name or relative resource id of the instance that owns the table. Instance pulumi.StringPtrInput Members pulumi.StringArrayInput Project pulumi.StringPtrInput // The role that should be applied. Only one // `bigtable.TableIamBinding` can be used per role. Note that custom roles must be of the format // `[projects|organizations]/{parent-name}/roles/{role-name}`. Read more about roles [here](https://cloud.google.com/bigtable/docs/access-control#roles). Role pulumi.StringPtrInput // The name or relative resource id of the table to manage IAM policies for. Table pulumi.StringPtrInput }
func (TableIamBindingState) ElementType ¶
func (TableIamBindingState) ElementType() reflect.Type
type TableIamMember ¶
type TableIamMember struct { pulumi.CustomResourceState Condition TableIamMemberConditionPtrOutput `pulumi:"condition"` // (Computed) The etag of the tables's IAM policy. Etag pulumi.StringOutput `pulumi:"etag"` // The name or relative resource id of the instance that owns the table. Instance pulumi.StringOutput `pulumi:"instance"` Member pulumi.StringOutput `pulumi:"member"` Project pulumi.StringOutput `pulumi:"project"` // The role that should be applied. Only one // `bigtable.TableIamBinding` can be used per role. Note that custom roles must be of the format // `[projects|organizations]/{parent-name}/roles/{role-name}`. Read more about roles [here](https://cloud.google.com/bigtable/docs/access-control#roles). Role pulumi.StringOutput `pulumi:"role"` // The name or relative resource id of the table to manage IAM policies for. Table pulumi.StringOutput `pulumi:"table"` }
Three different resources help you manage IAM policies on bigtable tables. Each of these resources serves a different use case:
* `bigtable.TableIamPolicy`: Authoritative. Sets the IAM policy for the tables and replaces any existing policy already attached. * `bigtable.TableIamBinding`: Authoritative for a given role. Updates the IAM policy to grant a role to a list of members. Other roles within the IAM policy for the table are preserved. * `bigtable.TableIamMember`: Non-authoritative. Updates the IAM policy to grant a role to a new member. Other members for the role for the table are preserved.
> **Note:** `bigtable.TableIamPolicy` **cannot** be used in conjunction with `bigtable.TableIamBinding` and `bigtable.TableIamMember` or they will fight over what your policy should be. In addition, be careful not to accidentally unset ownership of the table as `bigtable.TableIamPolicy` replaces the entire policy.
> **Note:** `bigtable.TableIamBinding` resources **can be** used in conjunction with `bigtable.TableIamMember` resources **only if** they do not grant privilege to the same role.
## google\_bigtable\_instance\_iam\_policy
```go package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/bigtable" "github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/organizations" "github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)
func main() { pulumi.Run(func(ctx *pulumi.Context) error { admin, err := organizations.LookupIAMPolicy(ctx, &organizations.LookupIAMPolicyArgs{ Bindings: []organizations.GetIAMPolicyBinding{ organizations.GetIAMPolicyBinding{ Role: "roles/bigtable.user", Members: []string{ "user:jane@example.com", }, }, }, }, nil) if err != nil { return err } _, err = bigtable.NewTableIamPolicy(ctx, "editor", &bigtable.TableIamPolicyArgs{ Project: pulumi.String("your-project"), Instance: pulumi.String("your-bigtable-instance"), Table: pulumi.String("your-bigtable-table"), PolicyData: pulumi.String(admin.PolicyData), }) if err != nil { return err } return nil }) }
```
## google\_bigtable\_instance\_iam\_binding
```go package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/bigtable" "github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)
func main() { pulumi.Run(func(ctx *pulumi.Context) error { _, err := bigtable.NewTableIamBinding(ctx, "editor", &bigtable.TableIamBindingArgs{ Instance: pulumi.String("your-bigtable-instance"), Members: pulumi.StringArray{ pulumi.String("user:jane@example.com"), }, Role: pulumi.String("roles/bigtable.user"), Table: pulumi.String("your-bigtable-table"), }) if err != nil { return err } return nil }) }
```
## google\_bigtable\_instance\_iam\_member
```go package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/bigtable" "github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)
func main() { pulumi.Run(func(ctx *pulumi.Context) error { _, err := bigtable.NewTableIamMember(ctx, "editor", &bigtable.TableIamMemberArgs{ Instance: pulumi.String("your-bigtable-instance"), Member: pulumi.String("user:jane@example.com"), Role: pulumi.String("roles/bigtable.user"), Table: pulumi.String("your-bigtable-table"), }) if err != nil { return err } return nil }) }
```
## Import
Instance IAM resources can be imported using the project, table name, role and/or member.
```sh
$ pulumi import gcp:bigtable/tableIamMember:TableIamMember editor "projects/{project}/tables/{table}"
```
```sh
$ pulumi import gcp:bigtable/tableIamMember:TableIamMember editor "projects/{project}/tables/{table} roles/editor"
```
```sh
$ pulumi import gcp:bigtable/tableIamMember:TableIamMember editor "projects/{project}/tables/{table} roles/editor user:jane@example.com"
```
-> **Custom Roles**If you're importing a IAM resource with a custom role, make sure to use the
full name of the custom role, e.g. `[projects/my-project|organizations/my-org]/roles/my-custom-role`.
func GetTableIamMember ¶
func GetTableIamMember(ctx *pulumi.Context, name string, id pulumi.IDInput, state *TableIamMemberState, opts ...pulumi.ResourceOption) (*TableIamMember, error)
GetTableIamMember gets an existing TableIamMember resource's state with the given name, ID, and optional state properties that are used to uniquely qualify the lookup (nil if not required).
func NewTableIamMember ¶
func NewTableIamMember(ctx *pulumi.Context, name string, args *TableIamMemberArgs, opts ...pulumi.ResourceOption) (*TableIamMember, error)
NewTableIamMember registers a new resource with the given unique name, arguments, and options.
func (TableIamMember) ElementType ¶ added in v4.4.0
func (TableIamMember) ElementType() reflect.Type
func (TableIamMember) ToTableIamMemberOutput ¶ added in v4.4.0
func (i TableIamMember) ToTableIamMemberOutput() TableIamMemberOutput
func (TableIamMember) ToTableIamMemberOutputWithContext ¶ added in v4.4.0
func (i TableIamMember) ToTableIamMemberOutputWithContext(ctx context.Context) TableIamMemberOutput
type TableIamMemberArgs ¶
type TableIamMemberArgs struct { Condition TableIamMemberConditionPtrInput // The name or relative resource id of the instance that owns the table. Instance pulumi.StringInput Member pulumi.StringInput Project pulumi.StringPtrInput // The role that should be applied. Only one // `bigtable.TableIamBinding` can be used per role. Note that custom roles must be of the format // `[projects|organizations]/{parent-name}/roles/{role-name}`. Read more about roles [here](https://cloud.google.com/bigtable/docs/access-control#roles). Role pulumi.StringInput // The name or relative resource id of the table to manage IAM policies for. Table pulumi.StringInput }
The set of arguments for constructing a TableIamMember resource.
func (TableIamMemberArgs) ElementType ¶
func (TableIamMemberArgs) ElementType() reflect.Type
type TableIamMemberCondition ¶
type TableIamMemberConditionArgs ¶
type TableIamMemberConditionArgs struct { Description pulumi.StringPtrInput `pulumi:"description"` Expression pulumi.StringInput `pulumi:"expression"` Title pulumi.StringInput `pulumi:"title"` }
func (TableIamMemberConditionArgs) ElementType ¶
func (TableIamMemberConditionArgs) ElementType() reflect.Type
func (TableIamMemberConditionArgs) ToTableIamMemberConditionOutput ¶
func (i TableIamMemberConditionArgs) ToTableIamMemberConditionOutput() TableIamMemberConditionOutput
func (TableIamMemberConditionArgs) ToTableIamMemberConditionOutputWithContext ¶
func (i TableIamMemberConditionArgs) ToTableIamMemberConditionOutputWithContext(ctx context.Context) TableIamMemberConditionOutput
func (TableIamMemberConditionArgs) ToTableIamMemberConditionPtrOutput ¶
func (i TableIamMemberConditionArgs) ToTableIamMemberConditionPtrOutput() TableIamMemberConditionPtrOutput
func (TableIamMemberConditionArgs) ToTableIamMemberConditionPtrOutputWithContext ¶
func (i TableIamMemberConditionArgs) ToTableIamMemberConditionPtrOutputWithContext(ctx context.Context) TableIamMemberConditionPtrOutput
type TableIamMemberConditionInput ¶
type TableIamMemberConditionInput interface { pulumi.Input ToTableIamMemberConditionOutput() TableIamMemberConditionOutput ToTableIamMemberConditionOutputWithContext(context.Context) TableIamMemberConditionOutput }
TableIamMemberConditionInput is an input type that accepts TableIamMemberConditionArgs and TableIamMemberConditionOutput values. You can construct a concrete instance of `TableIamMemberConditionInput` via:
TableIamMemberConditionArgs{...}
type TableIamMemberConditionOutput ¶
type TableIamMemberConditionOutput struct{ *pulumi.OutputState }
func (TableIamMemberConditionOutput) Description ¶
func (o TableIamMemberConditionOutput) Description() pulumi.StringPtrOutput
func (TableIamMemberConditionOutput) ElementType ¶
func (TableIamMemberConditionOutput) ElementType() reflect.Type
func (TableIamMemberConditionOutput) Expression ¶
func (o TableIamMemberConditionOutput) Expression() pulumi.StringOutput
func (TableIamMemberConditionOutput) Title ¶
func (o TableIamMemberConditionOutput) Title() pulumi.StringOutput
func (TableIamMemberConditionOutput) ToTableIamMemberConditionOutput ¶
func (o TableIamMemberConditionOutput) ToTableIamMemberConditionOutput() TableIamMemberConditionOutput
func (TableIamMemberConditionOutput) ToTableIamMemberConditionOutputWithContext ¶
func (o TableIamMemberConditionOutput) ToTableIamMemberConditionOutputWithContext(ctx context.Context) TableIamMemberConditionOutput
func (TableIamMemberConditionOutput) ToTableIamMemberConditionPtrOutput ¶
func (o TableIamMemberConditionOutput) ToTableIamMemberConditionPtrOutput() TableIamMemberConditionPtrOutput
func (TableIamMemberConditionOutput) ToTableIamMemberConditionPtrOutputWithContext ¶
func (o TableIamMemberConditionOutput) ToTableIamMemberConditionPtrOutputWithContext(ctx context.Context) TableIamMemberConditionPtrOutput
type TableIamMemberConditionPtrInput ¶
type TableIamMemberConditionPtrInput interface { pulumi.Input ToTableIamMemberConditionPtrOutput() TableIamMemberConditionPtrOutput ToTableIamMemberConditionPtrOutputWithContext(context.Context) TableIamMemberConditionPtrOutput }
TableIamMemberConditionPtrInput is an input type that accepts TableIamMemberConditionArgs, TableIamMemberConditionPtr and TableIamMemberConditionPtrOutput values. You can construct a concrete instance of `TableIamMemberConditionPtrInput` via:
TableIamMemberConditionArgs{...} or: nil
func TableIamMemberConditionPtr ¶
func TableIamMemberConditionPtr(v *TableIamMemberConditionArgs) TableIamMemberConditionPtrInput
type TableIamMemberConditionPtrOutput ¶
type TableIamMemberConditionPtrOutput struct{ *pulumi.OutputState }
func (TableIamMemberConditionPtrOutput) Description ¶
func (o TableIamMemberConditionPtrOutput) Description() pulumi.StringPtrOutput
func (TableIamMemberConditionPtrOutput) Elem ¶
func (o TableIamMemberConditionPtrOutput) Elem() TableIamMemberConditionOutput
func (TableIamMemberConditionPtrOutput) ElementType ¶
func (TableIamMemberConditionPtrOutput) ElementType() reflect.Type
func (TableIamMemberConditionPtrOutput) Expression ¶
func (o TableIamMemberConditionPtrOutput) Expression() pulumi.StringPtrOutput
func (TableIamMemberConditionPtrOutput) Title ¶
func (o TableIamMemberConditionPtrOutput) Title() pulumi.StringPtrOutput
func (TableIamMemberConditionPtrOutput) ToTableIamMemberConditionPtrOutput ¶
func (o TableIamMemberConditionPtrOutput) ToTableIamMemberConditionPtrOutput() TableIamMemberConditionPtrOutput
func (TableIamMemberConditionPtrOutput) ToTableIamMemberConditionPtrOutputWithContext ¶
func (o TableIamMemberConditionPtrOutput) ToTableIamMemberConditionPtrOutputWithContext(ctx context.Context) TableIamMemberConditionPtrOutput
type TableIamMemberInput ¶ added in v4.4.0
type TableIamMemberInput interface { pulumi.Input ToTableIamMemberOutput() TableIamMemberOutput ToTableIamMemberOutputWithContext(ctx context.Context) TableIamMemberOutput }
type TableIamMemberOutput ¶ added in v4.4.0
type TableIamMemberOutput struct {
*pulumi.OutputState
}
func (TableIamMemberOutput) ElementType ¶ added in v4.4.0
func (TableIamMemberOutput) ElementType() reflect.Type
func (TableIamMemberOutput) ToTableIamMemberOutput ¶ added in v4.4.0
func (o TableIamMemberOutput) ToTableIamMemberOutput() TableIamMemberOutput
func (TableIamMemberOutput) ToTableIamMemberOutputWithContext ¶ added in v4.4.0
func (o TableIamMemberOutput) ToTableIamMemberOutputWithContext(ctx context.Context) TableIamMemberOutput
type TableIamMemberState ¶
type TableIamMemberState struct { Condition TableIamMemberConditionPtrInput // (Computed) The etag of the tables's IAM policy. Etag pulumi.StringPtrInput // The name or relative resource id of the instance that owns the table. Instance pulumi.StringPtrInput Member pulumi.StringPtrInput Project pulumi.StringPtrInput // The role that should be applied. Only one // `bigtable.TableIamBinding` can be used per role. Note that custom roles must be of the format // `[projects|organizations]/{parent-name}/roles/{role-name}`. Read more about roles [here](https://cloud.google.com/bigtable/docs/access-control#roles). Role pulumi.StringPtrInput // The name or relative resource id of the table to manage IAM policies for. Table pulumi.StringPtrInput }
func (TableIamMemberState) ElementType ¶
func (TableIamMemberState) ElementType() reflect.Type
type TableIamPolicy ¶
type TableIamPolicy struct { pulumi.CustomResourceState // (Computed) The etag of the tables's IAM policy. Etag pulumi.StringOutput `pulumi:"etag"` // The name or relative resource id of the instance that owns the table. Instance pulumi.StringOutput `pulumi:"instance"` // The policy data generated by a `organizations.getIAMPolicy` data source. PolicyData pulumi.StringOutput `pulumi:"policyData"` Project pulumi.StringOutput `pulumi:"project"` // The name or relative resource id of the table to manage IAM policies for. Table pulumi.StringOutput `pulumi:"table"` }
Three different resources help you manage IAM policies on bigtable tables. Each of these resources serves a different use case:
* `bigtable.TableIamPolicy`: Authoritative. Sets the IAM policy for the tables and replaces any existing policy already attached. * `bigtable.TableIamBinding`: Authoritative for a given role. Updates the IAM policy to grant a role to a list of members. Other roles within the IAM policy for the table are preserved. * `bigtable.TableIamMember`: Non-authoritative. Updates the IAM policy to grant a role to a new member. Other members for the role for the table are preserved.
> **Note:** `bigtable.TableIamPolicy` **cannot** be used in conjunction with `bigtable.TableIamBinding` and `bigtable.TableIamMember` or they will fight over what your policy should be. In addition, be careful not to accidentally unset ownership of the table as `bigtable.TableIamPolicy` replaces the entire policy.
> **Note:** `bigtable.TableIamBinding` resources **can be** used in conjunction with `bigtable.TableIamMember` resources **only if** they do not grant privilege to the same role.
## google\_bigtable\_instance\_iam\_policy
```go package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/bigtable" "github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/organizations" "github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)
func main() { pulumi.Run(func(ctx *pulumi.Context) error { admin, err := organizations.LookupIAMPolicy(ctx, &organizations.LookupIAMPolicyArgs{ Bindings: []organizations.GetIAMPolicyBinding{ organizations.GetIAMPolicyBinding{ Role: "roles/bigtable.user", Members: []string{ "user:jane@example.com", }, }, }, }, nil) if err != nil { return err } _, err = bigtable.NewTableIamPolicy(ctx, "editor", &bigtable.TableIamPolicyArgs{ Project: pulumi.String("your-project"), Instance: pulumi.String("your-bigtable-instance"), Table: pulumi.String("your-bigtable-table"), PolicyData: pulumi.String(admin.PolicyData), }) if err != nil { return err } return nil }) }
```
## google\_bigtable\_instance\_iam\_binding
```go package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/bigtable" "github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)
func main() { pulumi.Run(func(ctx *pulumi.Context) error { _, err := bigtable.NewTableIamBinding(ctx, "editor", &bigtable.TableIamBindingArgs{ Instance: pulumi.String("your-bigtable-instance"), Members: pulumi.StringArray{ pulumi.String("user:jane@example.com"), }, Role: pulumi.String("roles/bigtable.user"), Table: pulumi.String("your-bigtable-table"), }) if err != nil { return err } return nil }) }
```
## google\_bigtable\_instance\_iam\_member
```go package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v4/go/gcp/bigtable" "github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)
func main() { pulumi.Run(func(ctx *pulumi.Context) error { _, err := bigtable.NewTableIamMember(ctx, "editor", &bigtable.TableIamMemberArgs{ Instance: pulumi.String("your-bigtable-instance"), Member: pulumi.String("user:jane@example.com"), Role: pulumi.String("roles/bigtable.user"), Table: pulumi.String("your-bigtable-table"), }) if err != nil { return err } return nil }) }
```
## Import
Instance IAM resources can be imported using the project, table name, role and/or member.
```sh
$ pulumi import gcp:bigtable/tableIamPolicy:TableIamPolicy editor "projects/{project}/tables/{table}"
```
```sh
$ pulumi import gcp:bigtable/tableIamPolicy:TableIamPolicy editor "projects/{project}/tables/{table} roles/editor"
```
```sh
$ pulumi import gcp:bigtable/tableIamPolicy:TableIamPolicy editor "projects/{project}/tables/{table} roles/editor user:jane@example.com"
```
-> **Custom Roles**If you're importing a IAM resource with a custom role, make sure to use the
full name of the custom role, e.g. `[projects/my-project|organizations/my-org]/roles/my-custom-role`.
func GetTableIamPolicy ¶
func GetTableIamPolicy(ctx *pulumi.Context, name string, id pulumi.IDInput, state *TableIamPolicyState, opts ...pulumi.ResourceOption) (*TableIamPolicy, error)
GetTableIamPolicy gets an existing TableIamPolicy resource's state with the given name, ID, and optional state properties that are used to uniquely qualify the lookup (nil if not required).
func NewTableIamPolicy ¶
func NewTableIamPolicy(ctx *pulumi.Context, name string, args *TableIamPolicyArgs, opts ...pulumi.ResourceOption) (*TableIamPolicy, error)
NewTableIamPolicy registers a new resource with the given unique name, arguments, and options.
func (TableIamPolicy) ElementType ¶ added in v4.4.0
func (TableIamPolicy) ElementType() reflect.Type
func (TableIamPolicy) ToTableIamPolicyOutput ¶ added in v4.4.0
func (i TableIamPolicy) ToTableIamPolicyOutput() TableIamPolicyOutput
func (TableIamPolicy) ToTableIamPolicyOutputWithContext ¶ added in v4.4.0
func (i TableIamPolicy) ToTableIamPolicyOutputWithContext(ctx context.Context) TableIamPolicyOutput
type TableIamPolicyArgs ¶
type TableIamPolicyArgs struct { // The name or relative resource id of the instance that owns the table. Instance pulumi.StringInput // The policy data generated by a `organizations.getIAMPolicy` data source. PolicyData pulumi.StringInput Project pulumi.StringPtrInput // The name or relative resource id of the table to manage IAM policies for. Table pulumi.StringInput }
The set of arguments for constructing a TableIamPolicy resource.
func (TableIamPolicyArgs) ElementType ¶
func (TableIamPolicyArgs) ElementType() reflect.Type
type TableIamPolicyInput ¶ added in v4.4.0
type TableIamPolicyInput interface { pulumi.Input ToTableIamPolicyOutput() TableIamPolicyOutput ToTableIamPolicyOutputWithContext(ctx context.Context) TableIamPolicyOutput }
type TableIamPolicyOutput ¶ added in v4.4.0
type TableIamPolicyOutput struct {
*pulumi.OutputState
}
func (TableIamPolicyOutput) ElementType ¶ added in v4.4.0
func (TableIamPolicyOutput) ElementType() reflect.Type
func (TableIamPolicyOutput) ToTableIamPolicyOutput ¶ added in v4.4.0
func (o TableIamPolicyOutput) ToTableIamPolicyOutput() TableIamPolicyOutput
func (TableIamPolicyOutput) ToTableIamPolicyOutputWithContext ¶ added in v4.4.0
func (o TableIamPolicyOutput) ToTableIamPolicyOutputWithContext(ctx context.Context) TableIamPolicyOutput
type TableIamPolicyState ¶
type TableIamPolicyState struct { // (Computed) The etag of the tables's IAM policy. Etag pulumi.StringPtrInput // The name or relative resource id of the instance that owns the table. Instance pulumi.StringPtrInput // The policy data generated by a `organizations.getIAMPolicy` data source. PolicyData pulumi.StringPtrInput Project pulumi.StringPtrInput // The name or relative resource id of the table to manage IAM policies for. Table pulumi.StringPtrInput }
func (TableIamPolicyState) ElementType ¶
func (TableIamPolicyState) ElementType() reflect.Type
type TableInput ¶ added in v4.4.0
type TableInput interface { pulumi.Input ToTableOutput() TableOutput ToTableOutputWithContext(ctx context.Context) TableOutput }
type TableOutput ¶ added in v4.4.0
type TableOutput struct {
*pulumi.OutputState
}
func (TableOutput) ElementType ¶ added in v4.4.0
func (TableOutput) ElementType() reflect.Type
func (TableOutput) ToTableOutput ¶ added in v4.4.0
func (o TableOutput) ToTableOutput() TableOutput
func (TableOutput) ToTableOutputWithContext ¶ added in v4.4.0
func (o TableOutput) ToTableOutputWithContext(ctx context.Context) TableOutput
type TableState ¶
type TableState struct { // A group of columns within a table which share a common configuration. This can be specified multiple times. Structure is documented below. ColumnFamilies TableColumnFamilyArrayInput // The name of the Bigtable instance. InstanceName pulumi.StringPtrInput // The name of the table. Name pulumi.StringPtrInput // The ID of the project in which the resource belongs. If it // is not provided, the provider project is used. Project pulumi.StringPtrInput // A list of predefined keys to split the table on. // !> **Warning:** Modifying the `splitKeys` of an existing table will cause the provider // to delete/recreate the entire `bigtable.Table` resource. SplitKeys pulumi.StringArrayInput }
func (TableState) ElementType ¶
func (TableState) ElementType() reflect.Type