audit

package
v0.1.8 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 26, 2024 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func PkgVersion added in v0.0.5

func PkgVersion() (semver.Version, error)

PkgVersion uses reflection to determine the version of the current package. If a version cannot be determined, v1 will be assumed. The second return value is always nil.

Types

type GetCosRegionsArgs

type GetCosRegionsArgs struct {
	// Used to save results.
	ResultOutputFile *string `pulumi:"resultOutputFile"`
}

A collection of arguments for invoking getCosRegions.

type GetCosRegionsAuditCosRegionList

type GetCosRegionsAuditCosRegionList struct {
	// Cos region.
	CosRegion string `pulumi:"cosRegion"`
	// Cos region chinese name.
	CosRegionName string `pulumi:"cosRegionName"`
}

type GetCosRegionsAuditCosRegionListArgs

type GetCosRegionsAuditCosRegionListArgs struct {
	// Cos region.
	CosRegion pulumi.StringInput `pulumi:"cosRegion"`
	// Cos region chinese name.
	CosRegionName pulumi.StringInput `pulumi:"cosRegionName"`
}

func (GetCosRegionsAuditCosRegionListArgs) ElementType

func (GetCosRegionsAuditCosRegionListArgs) ToGetCosRegionsAuditCosRegionListOutput

func (i GetCosRegionsAuditCosRegionListArgs) ToGetCosRegionsAuditCosRegionListOutput() GetCosRegionsAuditCosRegionListOutput

func (GetCosRegionsAuditCosRegionListArgs) ToGetCosRegionsAuditCosRegionListOutputWithContext

func (i GetCosRegionsAuditCosRegionListArgs) ToGetCosRegionsAuditCosRegionListOutputWithContext(ctx context.Context) GetCosRegionsAuditCosRegionListOutput

type GetCosRegionsAuditCosRegionListArray

type GetCosRegionsAuditCosRegionListArray []GetCosRegionsAuditCosRegionListInput

func (GetCosRegionsAuditCosRegionListArray) ElementType

func (GetCosRegionsAuditCosRegionListArray) ToGetCosRegionsAuditCosRegionListArrayOutput

func (i GetCosRegionsAuditCosRegionListArray) ToGetCosRegionsAuditCosRegionListArrayOutput() GetCosRegionsAuditCosRegionListArrayOutput

func (GetCosRegionsAuditCosRegionListArray) ToGetCosRegionsAuditCosRegionListArrayOutputWithContext

func (i GetCosRegionsAuditCosRegionListArray) ToGetCosRegionsAuditCosRegionListArrayOutputWithContext(ctx context.Context) GetCosRegionsAuditCosRegionListArrayOutput

type GetCosRegionsAuditCosRegionListArrayInput

type GetCosRegionsAuditCosRegionListArrayInput interface {
	pulumi.Input

	ToGetCosRegionsAuditCosRegionListArrayOutput() GetCosRegionsAuditCosRegionListArrayOutput
	ToGetCosRegionsAuditCosRegionListArrayOutputWithContext(context.Context) GetCosRegionsAuditCosRegionListArrayOutput
}

GetCosRegionsAuditCosRegionListArrayInput is an input type that accepts GetCosRegionsAuditCosRegionListArray and GetCosRegionsAuditCosRegionListArrayOutput values. You can construct a concrete instance of `GetCosRegionsAuditCosRegionListArrayInput` via:

GetCosRegionsAuditCosRegionListArray{ GetCosRegionsAuditCosRegionListArgs{...} }

type GetCosRegionsAuditCosRegionListArrayOutput

type GetCosRegionsAuditCosRegionListArrayOutput struct{ *pulumi.OutputState }

func (GetCosRegionsAuditCosRegionListArrayOutput) ElementType

func (GetCosRegionsAuditCosRegionListArrayOutput) Index

func (GetCosRegionsAuditCosRegionListArrayOutput) ToGetCosRegionsAuditCosRegionListArrayOutput

func (o GetCosRegionsAuditCosRegionListArrayOutput) ToGetCosRegionsAuditCosRegionListArrayOutput() GetCosRegionsAuditCosRegionListArrayOutput

func (GetCosRegionsAuditCosRegionListArrayOutput) ToGetCosRegionsAuditCosRegionListArrayOutputWithContext

func (o GetCosRegionsAuditCosRegionListArrayOutput) ToGetCosRegionsAuditCosRegionListArrayOutputWithContext(ctx context.Context) GetCosRegionsAuditCosRegionListArrayOutput

type GetCosRegionsAuditCosRegionListInput

type GetCosRegionsAuditCosRegionListInput interface {
	pulumi.Input

	ToGetCosRegionsAuditCosRegionListOutput() GetCosRegionsAuditCosRegionListOutput
	ToGetCosRegionsAuditCosRegionListOutputWithContext(context.Context) GetCosRegionsAuditCosRegionListOutput
}

GetCosRegionsAuditCosRegionListInput is an input type that accepts GetCosRegionsAuditCosRegionListArgs and GetCosRegionsAuditCosRegionListOutput values. You can construct a concrete instance of `GetCosRegionsAuditCosRegionListInput` via:

GetCosRegionsAuditCosRegionListArgs{...}

type GetCosRegionsAuditCosRegionListOutput

type GetCosRegionsAuditCosRegionListOutput struct{ *pulumi.OutputState }

func (GetCosRegionsAuditCosRegionListOutput) CosRegion

Cos region.

func (GetCosRegionsAuditCosRegionListOutput) CosRegionName

Cos region chinese name.

func (GetCosRegionsAuditCosRegionListOutput) ElementType

func (GetCosRegionsAuditCosRegionListOutput) ToGetCosRegionsAuditCosRegionListOutput

func (o GetCosRegionsAuditCosRegionListOutput) ToGetCosRegionsAuditCosRegionListOutput() GetCosRegionsAuditCosRegionListOutput

func (GetCosRegionsAuditCosRegionListOutput) ToGetCosRegionsAuditCosRegionListOutputWithContext

func (o GetCosRegionsAuditCosRegionListOutput) ToGetCosRegionsAuditCosRegionListOutputWithContext(ctx context.Context) GetCosRegionsAuditCosRegionListOutput

type GetCosRegionsOutputArgs

type GetCosRegionsOutputArgs struct {
	// Used to save results.
	ResultOutputFile pulumi.StringPtrInput `pulumi:"resultOutputFile"`
}

A collection of arguments for invoking getCosRegions.

func (GetCosRegionsOutputArgs) ElementType

func (GetCosRegionsOutputArgs) ElementType() reflect.Type

type GetCosRegionsResult

type GetCosRegionsResult struct {
	// List of available regions supported by audit cos.
	AuditCosRegionLists []GetCosRegionsAuditCosRegionList `pulumi:"auditCosRegionLists"`
	// The provider-assigned unique ID for this managed resource.
	Id               string  `pulumi:"id"`
	ResultOutputFile *string `pulumi:"resultOutputFile"`
}

A collection of values returned by getCosRegions.

func GetCosRegions

func GetCosRegions(ctx *pulumi.Context, args *GetCosRegionsArgs, opts ...pulumi.InvokeOption) (*GetCosRegionsResult, error)

Use this data source to query the cos region list supported by the audit.

## Example Usage

```go package main

import (

"github.com/pulumi/pulumi-tencentcloud/sdk/go/tencentcloud/Audit"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
"github.com/tencentcloudstack/pulumi-tencentcloud/sdk/go/tencentcloud/Audit"

)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := Audit.GetCosRegions(ctx, nil, nil)
		if err != nil {
			return err
		}
		return nil
	})
}

```

type GetCosRegionsResultOutput

type GetCosRegionsResultOutput struct{ *pulumi.OutputState }

A collection of values returned by getCosRegions.

func (GetCosRegionsResultOutput) AuditCosRegionLists

List of available regions supported by audit cos.

func (GetCosRegionsResultOutput) ElementType

func (GetCosRegionsResultOutput) ElementType() reflect.Type

func (GetCosRegionsResultOutput) Id

The provider-assigned unique ID for this managed resource.

func (GetCosRegionsResultOutput) ResultOutputFile

func (o GetCosRegionsResultOutput) ResultOutputFile() pulumi.StringPtrOutput

func (GetCosRegionsResultOutput) ToGetCosRegionsResultOutput

func (o GetCosRegionsResultOutput) ToGetCosRegionsResultOutput() GetCosRegionsResultOutput

func (GetCosRegionsResultOutput) ToGetCosRegionsResultOutputWithContext

func (o GetCosRegionsResultOutput) ToGetCosRegionsResultOutputWithContext(ctx context.Context) GetCosRegionsResultOutput

type GetKeyAliasArgs

type GetKeyAliasArgs struct {
	// Region.
	Region string `pulumi:"region"`
	// Used to save results.
	ResultOutputFile *string `pulumi:"resultOutputFile"`
}

A collection of arguments for invoking getKeyAlias.

type GetKeyAliasAuditKeyAliasList

type GetKeyAliasAuditKeyAliasList struct {
	// Key alias.
	KeyAlias string `pulumi:"keyAlias"`
	// Key ID.
	KeyId string `pulumi:"keyId"`
}

type GetKeyAliasAuditKeyAliasListArgs

type GetKeyAliasAuditKeyAliasListArgs struct {
	// Key alias.
	KeyAlias pulumi.StringInput `pulumi:"keyAlias"`
	// Key ID.
	KeyId pulumi.StringInput `pulumi:"keyId"`
}

func (GetKeyAliasAuditKeyAliasListArgs) ElementType

func (GetKeyAliasAuditKeyAliasListArgs) ToGetKeyAliasAuditKeyAliasListOutput

func (i GetKeyAliasAuditKeyAliasListArgs) ToGetKeyAliasAuditKeyAliasListOutput() GetKeyAliasAuditKeyAliasListOutput

func (GetKeyAliasAuditKeyAliasListArgs) ToGetKeyAliasAuditKeyAliasListOutputWithContext

func (i GetKeyAliasAuditKeyAliasListArgs) ToGetKeyAliasAuditKeyAliasListOutputWithContext(ctx context.Context) GetKeyAliasAuditKeyAliasListOutput

type GetKeyAliasAuditKeyAliasListArray

type GetKeyAliasAuditKeyAliasListArray []GetKeyAliasAuditKeyAliasListInput

func (GetKeyAliasAuditKeyAliasListArray) ElementType

func (GetKeyAliasAuditKeyAliasListArray) ToGetKeyAliasAuditKeyAliasListArrayOutput

func (i GetKeyAliasAuditKeyAliasListArray) ToGetKeyAliasAuditKeyAliasListArrayOutput() GetKeyAliasAuditKeyAliasListArrayOutput

func (GetKeyAliasAuditKeyAliasListArray) ToGetKeyAliasAuditKeyAliasListArrayOutputWithContext

func (i GetKeyAliasAuditKeyAliasListArray) ToGetKeyAliasAuditKeyAliasListArrayOutputWithContext(ctx context.Context) GetKeyAliasAuditKeyAliasListArrayOutput

type GetKeyAliasAuditKeyAliasListArrayInput

type GetKeyAliasAuditKeyAliasListArrayInput interface {
	pulumi.Input

	ToGetKeyAliasAuditKeyAliasListArrayOutput() GetKeyAliasAuditKeyAliasListArrayOutput
	ToGetKeyAliasAuditKeyAliasListArrayOutputWithContext(context.Context) GetKeyAliasAuditKeyAliasListArrayOutput
}

GetKeyAliasAuditKeyAliasListArrayInput is an input type that accepts GetKeyAliasAuditKeyAliasListArray and GetKeyAliasAuditKeyAliasListArrayOutput values. You can construct a concrete instance of `GetKeyAliasAuditKeyAliasListArrayInput` via:

GetKeyAliasAuditKeyAliasListArray{ GetKeyAliasAuditKeyAliasListArgs{...} }

type GetKeyAliasAuditKeyAliasListArrayOutput

type GetKeyAliasAuditKeyAliasListArrayOutput struct{ *pulumi.OutputState }

func (GetKeyAliasAuditKeyAliasListArrayOutput) ElementType

func (GetKeyAliasAuditKeyAliasListArrayOutput) Index

func (GetKeyAliasAuditKeyAliasListArrayOutput) ToGetKeyAliasAuditKeyAliasListArrayOutput

func (o GetKeyAliasAuditKeyAliasListArrayOutput) ToGetKeyAliasAuditKeyAliasListArrayOutput() GetKeyAliasAuditKeyAliasListArrayOutput

func (GetKeyAliasAuditKeyAliasListArrayOutput) ToGetKeyAliasAuditKeyAliasListArrayOutputWithContext

func (o GetKeyAliasAuditKeyAliasListArrayOutput) ToGetKeyAliasAuditKeyAliasListArrayOutputWithContext(ctx context.Context) GetKeyAliasAuditKeyAliasListArrayOutput

type GetKeyAliasAuditKeyAliasListInput

type GetKeyAliasAuditKeyAliasListInput interface {
	pulumi.Input

	ToGetKeyAliasAuditKeyAliasListOutput() GetKeyAliasAuditKeyAliasListOutput
	ToGetKeyAliasAuditKeyAliasListOutputWithContext(context.Context) GetKeyAliasAuditKeyAliasListOutput
}

GetKeyAliasAuditKeyAliasListInput is an input type that accepts GetKeyAliasAuditKeyAliasListArgs and GetKeyAliasAuditKeyAliasListOutput values. You can construct a concrete instance of `GetKeyAliasAuditKeyAliasListInput` via:

GetKeyAliasAuditKeyAliasListArgs{...}

type GetKeyAliasAuditKeyAliasListOutput

type GetKeyAliasAuditKeyAliasListOutput struct{ *pulumi.OutputState }

func (GetKeyAliasAuditKeyAliasListOutput) ElementType

func (GetKeyAliasAuditKeyAliasListOutput) KeyAlias

Key alias.

func (GetKeyAliasAuditKeyAliasListOutput) KeyId

Key ID.

func (GetKeyAliasAuditKeyAliasListOutput) ToGetKeyAliasAuditKeyAliasListOutput

func (o GetKeyAliasAuditKeyAliasListOutput) ToGetKeyAliasAuditKeyAliasListOutput() GetKeyAliasAuditKeyAliasListOutput

func (GetKeyAliasAuditKeyAliasListOutput) ToGetKeyAliasAuditKeyAliasListOutputWithContext

func (o GetKeyAliasAuditKeyAliasListOutput) ToGetKeyAliasAuditKeyAliasListOutputWithContext(ctx context.Context) GetKeyAliasAuditKeyAliasListOutput

type GetKeyAliasOutputArgs

type GetKeyAliasOutputArgs struct {
	// Region.
	Region pulumi.StringInput `pulumi:"region"`
	// Used to save results.
	ResultOutputFile pulumi.StringPtrInput `pulumi:"resultOutputFile"`
}

A collection of arguments for invoking getKeyAlias.

func (GetKeyAliasOutputArgs) ElementType

func (GetKeyAliasOutputArgs) ElementType() reflect.Type

type GetKeyAliasResult

type GetKeyAliasResult struct {
	// List of available key alias supported by audit.
	AuditKeyAliasLists []GetKeyAliasAuditKeyAliasList `pulumi:"auditKeyAliasLists"`
	// The provider-assigned unique ID for this managed resource.
	Id               string  `pulumi:"id"`
	Region           string  `pulumi:"region"`
	ResultOutputFile *string `pulumi:"resultOutputFile"`
}

A collection of values returned by getKeyAlias.

func GetKeyAlias

func GetKeyAlias(ctx *pulumi.Context, args *GetKeyAliasArgs, opts ...pulumi.InvokeOption) (*GetKeyAliasResult, error)

Use this data source to query the key alias list specified with region supported by the audit.

## Example Usage

```go package main

import (

"github.com/pulumi/pulumi-tencentcloud/sdk/go/tencentcloud/Audit"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
"github.com/tencentcloudstack/pulumi-tencentcloud/sdk/go/tencentcloud/Audit"

)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := Audit.GetKeyAlias(ctx, &audit.GetKeyAliasArgs{
			Region: "ap-hongkong",
		}, nil)
		if err != nil {
			return err
		}
		return nil
	})
}

```

type GetKeyAliasResultOutput

type GetKeyAliasResultOutput struct{ *pulumi.OutputState }

A collection of values returned by getKeyAlias.

func (GetKeyAliasResultOutput) AuditKeyAliasLists

List of available key alias supported by audit.

func (GetKeyAliasResultOutput) ElementType

func (GetKeyAliasResultOutput) ElementType() reflect.Type

func (GetKeyAliasResultOutput) Id

The provider-assigned unique ID for this managed resource.

func (GetKeyAliasResultOutput) Region

func (GetKeyAliasResultOutput) ResultOutputFile

func (o GetKeyAliasResultOutput) ResultOutputFile() pulumi.StringPtrOutput

func (GetKeyAliasResultOutput) ToGetKeyAliasResultOutput

func (o GetKeyAliasResultOutput) ToGetKeyAliasResultOutput() GetKeyAliasResultOutput

func (GetKeyAliasResultOutput) ToGetKeyAliasResultOutputWithContext

func (o GetKeyAliasResultOutput) ToGetKeyAliasResultOutputWithContext(ctx context.Context) GetKeyAliasResultOutput

type Instance

type Instance struct {
	pulumi.CustomResourceState

	// Indicate whether to turn on audit logging or not.
	AuditSwitch pulumi.BoolOutput `pulumi:"auditSwitch"`
	// Name of the cos bucket to save audit log. Caution: the validation of existing cos bucket will not be checked by
	// terraform.
	CosBucket pulumi.StringOutput `pulumi:"cosBucket"`
	// Region of the cos bucket.
	CosRegion pulumi.StringOutput `pulumi:"cosRegion"`
	// Indicate whether the log is encrypt with KMS algorithm or not.
	EnableKmsEncry pulumi.BoolPtrOutput `pulumi:"enableKmsEncry"`
	// Existing CMK unique key. This field can be get by data source `Audit.getKeyAlias`. Caution: the region of the KMS must be as same as the `cosRegion`.
	KeyId pulumi.StringPtrOutput `pulumi:"keyId"`
	// The log file name prefix. The length ranges from 3 to 40. If not set, the account ID will be the log file prefix.
	LogFilePrefix pulumi.StringOutput `pulumi:"logFilePrefix"`
	// Name of audit. Valid length ranges from 3 to 128. Only alpha character or numbers or '_' supported.
	Name pulumi.StringOutput `pulumi:"name"`
	// Event attribute filter. Valid values: `1`, `2`, `3`. `1` for readonly, `2` for write-only, `3` for all.
	ReadWriteAttribute pulumi.IntOutput `pulumi:"readWriteAttribute"`
}

Provides a resource to create an audit.

## Example Usage

```go package main

import (

"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
"github.com/tencentcloudstack/pulumi-tencentcloud/sdk/go/tencentcloud/Audit"

)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := Audit.NewInstance(ctx, "foo", &Audit.InstanceArgs{
			AuditSwitch:        pulumi.Bool(true),
			CosBucket:          pulumi.String("test"),
			CosRegion:          pulumi.String("ap-hongkong"),
			LogFilePrefix:      pulumi.String("test"),
			ReadWriteAttribute: pulumi.Int(3),
		})
		if err != nil {
			return err
		}
		return nil
	})
}

```

## Import

Audit can be imported using the id, e.g.

```sh

$ pulumi import tencentcloud:Audit/instance:Instance foo audit-test

```

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

func (*Instance) ElementType() reflect.Type

func (*Instance) ToInstanceOutput

func (i *Instance) ToInstanceOutput() InstanceOutput

func (*Instance) ToInstanceOutputWithContext

func (i *Instance) ToInstanceOutputWithContext(ctx context.Context) InstanceOutput

type InstanceArgs

type InstanceArgs struct {
	// Indicate whether to turn on audit logging or not.
	AuditSwitch pulumi.BoolInput
	// Name of the cos bucket to save audit log. Caution: the validation of existing cos bucket will not be checked by
	// terraform.
	CosBucket pulumi.StringInput
	// Region of the cos bucket.
	CosRegion pulumi.StringInput
	// Indicate whether the log is encrypt with KMS algorithm or not.
	EnableKmsEncry pulumi.BoolPtrInput
	// Existing CMK unique key. This field can be get by data source `Audit.getKeyAlias`. Caution: the region of the KMS must be as same as the `cosRegion`.
	KeyId pulumi.StringPtrInput
	// The log file name prefix. The length ranges from 3 to 40. If not set, the account ID will be the log file prefix.
	LogFilePrefix pulumi.StringPtrInput
	// Name of audit. Valid length ranges from 3 to 128. Only alpha character or numbers or '_' supported.
	Name pulumi.StringPtrInput
	// Event attribute filter. Valid values: `1`, `2`, `3`. `1` for readonly, `2` for write-only, `3` for all.
	ReadWriteAttribute pulumi.IntInput
}

The set of arguments for constructing a Instance resource.

func (InstanceArgs) ElementType

func (InstanceArgs) ElementType() reflect.Type

type InstanceArray

type InstanceArray []InstanceInput

func (InstanceArray) ElementType

func (InstanceArray) ElementType() reflect.Type

func (InstanceArray) ToInstanceArrayOutput

func (i InstanceArray) ToInstanceArrayOutput() InstanceArrayOutput

func (InstanceArray) ToInstanceArrayOutputWithContext

func (i InstanceArray) ToInstanceArrayOutputWithContext(ctx context.Context) InstanceArrayOutput

type InstanceArrayInput

type InstanceArrayInput interface {
	pulumi.Input

	ToInstanceArrayOutput() InstanceArrayOutput
	ToInstanceArrayOutputWithContext(context.Context) InstanceArrayOutput
}

InstanceArrayInput is an input type that accepts InstanceArray and InstanceArrayOutput values. You can construct a concrete instance of `InstanceArrayInput` via:

InstanceArray{ InstanceArgs{...} }

type InstanceArrayOutput

type InstanceArrayOutput struct{ *pulumi.OutputState }

func (InstanceArrayOutput) ElementType

func (InstanceArrayOutput) ElementType() reflect.Type

func (InstanceArrayOutput) Index

func (InstanceArrayOutput) ToInstanceArrayOutput

func (o InstanceArrayOutput) ToInstanceArrayOutput() InstanceArrayOutput

func (InstanceArrayOutput) ToInstanceArrayOutputWithContext

func (o InstanceArrayOutput) ToInstanceArrayOutputWithContext(ctx context.Context) InstanceArrayOutput

type InstanceInput

type InstanceInput interface {
	pulumi.Input

	ToInstanceOutput() InstanceOutput
	ToInstanceOutputWithContext(ctx context.Context) InstanceOutput
}

type InstanceMap

type InstanceMap map[string]InstanceInput

func (InstanceMap) ElementType

func (InstanceMap) ElementType() reflect.Type

func (InstanceMap) ToInstanceMapOutput

func (i InstanceMap) ToInstanceMapOutput() InstanceMapOutput

func (InstanceMap) ToInstanceMapOutputWithContext

func (i InstanceMap) ToInstanceMapOutputWithContext(ctx context.Context) InstanceMapOutput

type InstanceMapInput

type InstanceMapInput interface {
	pulumi.Input

	ToInstanceMapOutput() InstanceMapOutput
	ToInstanceMapOutputWithContext(context.Context) InstanceMapOutput
}

InstanceMapInput is an input type that accepts InstanceMap and InstanceMapOutput values. You can construct a concrete instance of `InstanceMapInput` via:

InstanceMap{ "key": InstanceArgs{...} }

type InstanceMapOutput

type InstanceMapOutput struct{ *pulumi.OutputState }

func (InstanceMapOutput) ElementType

func (InstanceMapOutput) ElementType() reflect.Type

func (InstanceMapOutput) MapIndex

func (InstanceMapOutput) ToInstanceMapOutput

func (o InstanceMapOutput) ToInstanceMapOutput() InstanceMapOutput

func (InstanceMapOutput) ToInstanceMapOutputWithContext

func (o InstanceMapOutput) ToInstanceMapOutputWithContext(ctx context.Context) InstanceMapOutput

type InstanceOutput

type InstanceOutput struct{ *pulumi.OutputState }

func (InstanceOutput) AuditSwitch

func (o InstanceOutput) AuditSwitch() pulumi.BoolOutput

Indicate whether to turn on audit logging or not.

func (InstanceOutput) CosBucket

func (o InstanceOutput) CosBucket() pulumi.StringOutput

Name of the cos bucket to save audit log. Caution: the validation of existing cos bucket will not be checked by terraform.

func (InstanceOutput) CosRegion

func (o InstanceOutput) CosRegion() pulumi.StringOutput

Region of the cos bucket.

func (InstanceOutput) ElementType

func (InstanceOutput) ElementType() reflect.Type

func (InstanceOutput) EnableKmsEncry

func (o InstanceOutput) EnableKmsEncry() pulumi.BoolPtrOutput

Indicate whether the log is encrypt with KMS algorithm or not.

func (InstanceOutput) KeyId

Existing CMK unique key. This field can be get by data source `Audit.getKeyAlias`. Caution: the region of the KMS must be as same as the `cosRegion`.

func (InstanceOutput) LogFilePrefix

func (o InstanceOutput) LogFilePrefix() pulumi.StringOutput

The log file name prefix. The length ranges from 3 to 40. If not set, the account ID will be the log file prefix.

func (InstanceOutput) Name

Name of audit. Valid length ranges from 3 to 128. Only alpha character or numbers or '_' supported.

func (InstanceOutput) ReadWriteAttribute

func (o InstanceOutput) ReadWriteAttribute() pulumi.IntOutput

Event attribute filter. Valid values: `1`, `2`, `3`. `1` for readonly, `2` for write-only, `3` for all.

func (InstanceOutput) ToInstanceOutput

func (o InstanceOutput) ToInstanceOutput() InstanceOutput

func (InstanceOutput) ToInstanceOutputWithContext

func (o InstanceOutput) ToInstanceOutputWithContext(ctx context.Context) InstanceOutput

type InstanceState

type InstanceState struct {
	// Indicate whether to turn on audit logging or not.
	AuditSwitch pulumi.BoolPtrInput
	// Name of the cos bucket to save audit log. Caution: the validation of existing cos bucket will not be checked by
	// terraform.
	CosBucket pulumi.StringPtrInput
	// Region of the cos bucket.
	CosRegion pulumi.StringPtrInput
	// Indicate whether the log is encrypt with KMS algorithm or not.
	EnableKmsEncry pulumi.BoolPtrInput
	// Existing CMK unique key. This field can be get by data source `Audit.getKeyAlias`. Caution: the region of the KMS must be as same as the `cosRegion`.
	KeyId pulumi.StringPtrInput
	// The log file name prefix. The length ranges from 3 to 40. If not set, the account ID will be the log file prefix.
	LogFilePrefix pulumi.StringPtrInput
	// Name of audit. Valid length ranges from 3 to 128. Only alpha character or numbers or '_' supported.
	Name pulumi.StringPtrInput
	// Event attribute filter. Valid values: `1`, `2`, `3`. `1` for readonly, `2` for write-only, `3` for all.
	ReadWriteAttribute pulumi.IntPtrInput
}

func (InstanceState) ElementType

func (InstanceState) ElementType() reflect.Type

type Track added in v0.1.3

type Track struct {
	pulumi.CustomResourceState

	// Track interface type, optional:- `Read`: Read interface- `Write`: Write interface- `*`: All interface.
	ActionType pulumi.StringOutput `pulumi:"actionType"`
	// Track create time.
	CreateTime pulumi.StringOutput `pulumi:"createTime"`
	// Track interface name list:- when ResourceType is `*`, EventNames is must `["*"]`- when ResourceType is a single product, EventNames support all interface:`["*"]`- when ResourceType is a single product, EventNames support some interface, up to 10.
	EventNames pulumi.StringArrayOutput `pulumi:"eventNames"`
	// Track name.
	Name pulumi.StringOutput `pulumi:"name"`
	// Track product, optional:- `*`: All product- Single product, such as `cos`.
	ResourceType pulumi.StringOutput `pulumi:"resourceType"`
	// Track status, optional:- `0`: Close- `1`: Open.
	Status pulumi.IntOutput `pulumi:"status"`
	// Track Storage, support `cos` and `cls`.
	Storage TrackStorageOutput `pulumi:"storage"`
	// Whether to enable the delivery of group member operation logs to the group management account or trusted service management account, optional:- `0`: Close- `1`: Open.
	TrackForAllMembers pulumi.IntPtrOutput `pulumi:"trackForAllMembers"`
}

Provides a resource to create a audit track

## Example Usage

```go package main

import (

"github.com/pulumi/pulumi-tencentcloud/sdk/go/tencentcloud/Audit"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
"github.com/tencentcloudstack/pulumi-tencentcloud/sdk/go/tencentcloud/Audit"

)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := Audit.NewTrack(ctx, "track", &Audit.TrackArgs{
			ActionType: pulumi.String("Read"),
			EventNames: pulumi.StringArray{
				pulumi.String("*"),
			},
			ResourceType: pulumi.String("*"),
			Status:       pulumi.Int(1),
			Storage: &audit.TrackStorageArgs{
				StorageName:   pulumi.String("db90b92c-91d2-46b0-94ac-debbbb21dc4e"),
				StoragePrefix: pulumi.String("cloudaudit"),
				StorageRegion: pulumi.String("ap-guangzhou"),
				StorageType:   pulumi.String("cls"),
			},
			TrackForAllMembers: pulumi.Int(0),
		})
		if err != nil {
			return err
		}
		return nil
	})
}

```

## Import

audit track can be imported using the id, e.g.

```sh

$ pulumi import tencentcloud:Audit/track:Track track track_id

```

func GetTrack added in v0.1.3

func GetTrack(ctx *pulumi.Context,
	name string, id pulumi.IDInput, state *TrackState, opts ...pulumi.ResourceOption) (*Track, error)

GetTrack gets an existing Track 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 NewTrack added in v0.1.3

func NewTrack(ctx *pulumi.Context,
	name string, args *TrackArgs, opts ...pulumi.ResourceOption) (*Track, error)

NewTrack registers a new resource with the given unique name, arguments, and options.

func (*Track) ElementType added in v0.1.3

func (*Track) ElementType() reflect.Type

func (*Track) ToTrackOutput added in v0.1.3

func (i *Track) ToTrackOutput() TrackOutput

func (*Track) ToTrackOutputWithContext added in v0.1.3

func (i *Track) ToTrackOutputWithContext(ctx context.Context) TrackOutput

type TrackArgs added in v0.1.3

type TrackArgs struct {
	// Track interface type, optional:- `Read`: Read interface- `Write`: Write interface- `*`: All interface.
	ActionType pulumi.StringInput
	// Track interface name list:- when ResourceType is `*`, EventNames is must `["*"]`- when ResourceType is a single product, EventNames support all interface:`["*"]`- when ResourceType is a single product, EventNames support some interface, up to 10.
	EventNames pulumi.StringArrayInput
	// Track name.
	Name pulumi.StringPtrInput
	// Track product, optional:- `*`: All product- Single product, such as `cos`.
	ResourceType pulumi.StringInput
	// Track status, optional:- `0`: Close- `1`: Open.
	Status pulumi.IntInput
	// Track Storage, support `cos` and `cls`.
	Storage TrackStorageInput
	// Whether to enable the delivery of group member operation logs to the group management account or trusted service management account, optional:- `0`: Close- `1`: Open.
	TrackForAllMembers pulumi.IntPtrInput
}

The set of arguments for constructing a Track resource.

func (TrackArgs) ElementType added in v0.1.3

func (TrackArgs) ElementType() reflect.Type

type TrackArray added in v0.1.3

type TrackArray []TrackInput

func (TrackArray) ElementType added in v0.1.3

func (TrackArray) ElementType() reflect.Type

func (TrackArray) ToTrackArrayOutput added in v0.1.3

func (i TrackArray) ToTrackArrayOutput() TrackArrayOutput

func (TrackArray) ToTrackArrayOutputWithContext added in v0.1.3

func (i TrackArray) ToTrackArrayOutputWithContext(ctx context.Context) TrackArrayOutput

type TrackArrayInput added in v0.1.3

type TrackArrayInput interface {
	pulumi.Input

	ToTrackArrayOutput() TrackArrayOutput
	ToTrackArrayOutputWithContext(context.Context) TrackArrayOutput
}

TrackArrayInput is an input type that accepts TrackArray and TrackArrayOutput values. You can construct a concrete instance of `TrackArrayInput` via:

TrackArray{ TrackArgs{...} }

type TrackArrayOutput added in v0.1.3

type TrackArrayOutput struct{ *pulumi.OutputState }

func (TrackArrayOutput) ElementType added in v0.1.3

func (TrackArrayOutput) ElementType() reflect.Type

func (TrackArrayOutput) Index added in v0.1.3

func (TrackArrayOutput) ToTrackArrayOutput added in v0.1.3

func (o TrackArrayOutput) ToTrackArrayOutput() TrackArrayOutput

func (TrackArrayOutput) ToTrackArrayOutputWithContext added in v0.1.3

func (o TrackArrayOutput) ToTrackArrayOutputWithContext(ctx context.Context) TrackArrayOutput

type TrackInput added in v0.1.3

type TrackInput interface {
	pulumi.Input

	ToTrackOutput() TrackOutput
	ToTrackOutputWithContext(ctx context.Context) TrackOutput
}

type TrackMap added in v0.1.3

type TrackMap map[string]TrackInput

func (TrackMap) ElementType added in v0.1.3

func (TrackMap) ElementType() reflect.Type

func (TrackMap) ToTrackMapOutput added in v0.1.3

func (i TrackMap) ToTrackMapOutput() TrackMapOutput

func (TrackMap) ToTrackMapOutputWithContext added in v0.1.3

func (i TrackMap) ToTrackMapOutputWithContext(ctx context.Context) TrackMapOutput

type TrackMapInput added in v0.1.3

type TrackMapInput interface {
	pulumi.Input

	ToTrackMapOutput() TrackMapOutput
	ToTrackMapOutputWithContext(context.Context) TrackMapOutput
}

TrackMapInput is an input type that accepts TrackMap and TrackMapOutput values. You can construct a concrete instance of `TrackMapInput` via:

TrackMap{ "key": TrackArgs{...} }

type TrackMapOutput added in v0.1.3

type TrackMapOutput struct{ *pulumi.OutputState }

func (TrackMapOutput) ElementType added in v0.1.3

func (TrackMapOutput) ElementType() reflect.Type

func (TrackMapOutput) MapIndex added in v0.1.3

func (TrackMapOutput) ToTrackMapOutput added in v0.1.3

func (o TrackMapOutput) ToTrackMapOutput() TrackMapOutput

func (TrackMapOutput) ToTrackMapOutputWithContext added in v0.1.3

func (o TrackMapOutput) ToTrackMapOutputWithContext(ctx context.Context) TrackMapOutput

type TrackOutput added in v0.1.3

type TrackOutput struct{ *pulumi.OutputState }

func (TrackOutput) ActionType added in v0.1.3

func (o TrackOutput) ActionType() pulumi.StringOutput

Track interface type, optional:- `Read`: Read interface- `Write`: Write interface- `*`: All interface.

func (TrackOutput) CreateTime added in v0.1.3

func (o TrackOutput) CreateTime() pulumi.StringOutput

Track create time.

func (TrackOutput) ElementType added in v0.1.3

func (TrackOutput) ElementType() reflect.Type

func (TrackOutput) EventNames added in v0.1.3

func (o TrackOutput) EventNames() pulumi.StringArrayOutput

Track interface name list:- when ResourceType is `*`, EventNames is must `["*"]`- when ResourceType is a single product, EventNames support all interface:`["*"]`- when ResourceType is a single product, EventNames support some interface, up to 10.

func (TrackOutput) Name added in v0.1.3

func (o TrackOutput) Name() pulumi.StringOutput

Track name.

func (TrackOutput) ResourceType added in v0.1.3

func (o TrackOutput) ResourceType() pulumi.StringOutput

Track product, optional:- `*`: All product- Single product, such as `cos`.

func (TrackOutput) Status added in v0.1.3

func (o TrackOutput) Status() pulumi.IntOutput

Track status, optional:- `0`: Close- `1`: Open.

func (TrackOutput) Storage added in v0.1.3

func (o TrackOutput) Storage() TrackStorageOutput

Track Storage, support `cos` and `cls`.

func (TrackOutput) ToTrackOutput added in v0.1.3

func (o TrackOutput) ToTrackOutput() TrackOutput

func (TrackOutput) ToTrackOutputWithContext added in v0.1.3

func (o TrackOutput) ToTrackOutputWithContext(ctx context.Context) TrackOutput

func (TrackOutput) TrackForAllMembers added in v0.1.3

func (o TrackOutput) TrackForAllMembers() pulumi.IntPtrOutput

Whether to enable the delivery of group member operation logs to the group management account or trusted service management account, optional:- `0`: Close- `1`: Open.

type TrackState added in v0.1.3

type TrackState struct {
	// Track interface type, optional:- `Read`: Read interface- `Write`: Write interface- `*`: All interface.
	ActionType pulumi.StringPtrInput
	// Track create time.
	CreateTime pulumi.StringPtrInput
	// Track interface name list:- when ResourceType is `*`, EventNames is must `["*"]`- when ResourceType is a single product, EventNames support all interface:`["*"]`- when ResourceType is a single product, EventNames support some interface, up to 10.
	EventNames pulumi.StringArrayInput
	// Track name.
	Name pulumi.StringPtrInput
	// Track product, optional:- `*`: All product- Single product, such as `cos`.
	ResourceType pulumi.StringPtrInput
	// Track status, optional:- `0`: Close- `1`: Open.
	Status pulumi.IntPtrInput
	// Track Storage, support `cos` and `cls`.
	Storage TrackStoragePtrInput
	// Whether to enable the delivery of group member operation logs to the group management account or trusted service management account, optional:- `0`: Close- `1`: Open.
	TrackForAllMembers pulumi.IntPtrInput
}

func (TrackState) ElementType added in v0.1.3

func (TrackState) ElementType() reflect.Type

type TrackStorage added in v0.1.3

type TrackStorage struct {
	// Track Storage name:- when StorageType is `cls`, StorageName is cls topicId- when StorageType is `cos`, StorageName is cos bucket name that does not contain `-APPID`.
	StorageName string `pulumi:"storageName"`
	// Storage path prefix.
	StoragePrefix string `pulumi:"storagePrefix"`
	// Storage region.
	StorageRegion string `pulumi:"storageRegion"`
	// Track Storage type, optional:- `cos`- `cls`.
	StorageType string `pulumi:"storageType"`
}

type TrackStorageArgs added in v0.1.3

type TrackStorageArgs struct {
	// Track Storage name:- when StorageType is `cls`, StorageName is cls topicId- when StorageType is `cos`, StorageName is cos bucket name that does not contain `-APPID`.
	StorageName pulumi.StringInput `pulumi:"storageName"`
	// Storage path prefix.
	StoragePrefix pulumi.StringInput `pulumi:"storagePrefix"`
	// Storage region.
	StorageRegion pulumi.StringInput `pulumi:"storageRegion"`
	// Track Storage type, optional:- `cos`- `cls`.
	StorageType pulumi.StringInput `pulumi:"storageType"`
}

func (TrackStorageArgs) ElementType added in v0.1.3

func (TrackStorageArgs) ElementType() reflect.Type

func (TrackStorageArgs) ToTrackStorageOutput added in v0.1.3

func (i TrackStorageArgs) ToTrackStorageOutput() TrackStorageOutput

func (TrackStorageArgs) ToTrackStorageOutputWithContext added in v0.1.3

func (i TrackStorageArgs) ToTrackStorageOutputWithContext(ctx context.Context) TrackStorageOutput

func (TrackStorageArgs) ToTrackStoragePtrOutput added in v0.1.3

func (i TrackStorageArgs) ToTrackStoragePtrOutput() TrackStoragePtrOutput

func (TrackStorageArgs) ToTrackStoragePtrOutputWithContext added in v0.1.3

func (i TrackStorageArgs) ToTrackStoragePtrOutputWithContext(ctx context.Context) TrackStoragePtrOutput

type TrackStorageInput added in v0.1.3

type TrackStorageInput interface {
	pulumi.Input

	ToTrackStorageOutput() TrackStorageOutput
	ToTrackStorageOutputWithContext(context.Context) TrackStorageOutput
}

TrackStorageInput is an input type that accepts TrackStorageArgs and TrackStorageOutput values. You can construct a concrete instance of `TrackStorageInput` via:

TrackStorageArgs{...}

type TrackStorageOutput added in v0.1.3

type TrackStorageOutput struct{ *pulumi.OutputState }

func (TrackStorageOutput) ElementType added in v0.1.3

func (TrackStorageOutput) ElementType() reflect.Type

func (TrackStorageOutput) StorageName added in v0.1.3

func (o TrackStorageOutput) StorageName() pulumi.StringOutput

Track Storage name:- when StorageType is `cls`, StorageName is cls topicId- when StorageType is `cos`, StorageName is cos bucket name that does not contain `-APPID`.

func (TrackStorageOutput) StoragePrefix added in v0.1.3

func (o TrackStorageOutput) StoragePrefix() pulumi.StringOutput

Storage path prefix.

func (TrackStorageOutput) StorageRegion added in v0.1.3

func (o TrackStorageOutput) StorageRegion() pulumi.StringOutput

Storage region.

func (TrackStorageOutput) StorageType added in v0.1.3

func (o TrackStorageOutput) StorageType() pulumi.StringOutput

Track Storage type, optional:- `cos`- `cls`.

func (TrackStorageOutput) ToTrackStorageOutput added in v0.1.3

func (o TrackStorageOutput) ToTrackStorageOutput() TrackStorageOutput

func (TrackStorageOutput) ToTrackStorageOutputWithContext added in v0.1.3

func (o TrackStorageOutput) ToTrackStorageOutputWithContext(ctx context.Context) TrackStorageOutput

func (TrackStorageOutput) ToTrackStoragePtrOutput added in v0.1.3

func (o TrackStorageOutput) ToTrackStoragePtrOutput() TrackStoragePtrOutput

func (TrackStorageOutput) ToTrackStoragePtrOutputWithContext added in v0.1.3

func (o TrackStorageOutput) ToTrackStoragePtrOutputWithContext(ctx context.Context) TrackStoragePtrOutput

type TrackStoragePtrInput added in v0.1.3

type TrackStoragePtrInput interface {
	pulumi.Input

	ToTrackStoragePtrOutput() TrackStoragePtrOutput
	ToTrackStoragePtrOutputWithContext(context.Context) TrackStoragePtrOutput
}

TrackStoragePtrInput is an input type that accepts TrackStorageArgs, TrackStoragePtr and TrackStoragePtrOutput values. You can construct a concrete instance of `TrackStoragePtrInput` via:

        TrackStorageArgs{...}

or:

        nil

func TrackStoragePtr added in v0.1.3

func TrackStoragePtr(v *TrackStorageArgs) TrackStoragePtrInput

type TrackStoragePtrOutput added in v0.1.3

type TrackStoragePtrOutput struct{ *pulumi.OutputState }

func (TrackStoragePtrOutput) Elem added in v0.1.3

func (TrackStoragePtrOutput) ElementType added in v0.1.3

func (TrackStoragePtrOutput) ElementType() reflect.Type

func (TrackStoragePtrOutput) StorageName added in v0.1.3

Track Storage name:- when StorageType is `cls`, StorageName is cls topicId- when StorageType is `cos`, StorageName is cos bucket name that does not contain `-APPID`.

func (TrackStoragePtrOutput) StoragePrefix added in v0.1.3

func (o TrackStoragePtrOutput) StoragePrefix() pulumi.StringPtrOutput

Storage path prefix.

func (TrackStoragePtrOutput) StorageRegion added in v0.1.3

func (o TrackStoragePtrOutput) StorageRegion() pulumi.StringPtrOutput

Storage region.

func (TrackStoragePtrOutput) StorageType added in v0.1.3

Track Storage type, optional:- `cos`- `cls`.

func (TrackStoragePtrOutput) ToTrackStoragePtrOutput added in v0.1.3

func (o TrackStoragePtrOutput) ToTrackStoragePtrOutput() TrackStoragePtrOutput

func (TrackStoragePtrOutput) ToTrackStoragePtrOutputWithContext added in v0.1.3

func (o TrackStoragePtrOutput) ToTrackStoragePtrOutputWithContext(ctx context.Context) TrackStoragePtrOutput

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL