alicloud logo
Alibaba Cloud v3.37.0, May 15 23

alicloud.cfg.ConfigurationRecorder

Explore with Pulumi AI

Provides a Alicloud Config Configuration Recorder resource. Cloud Config is a specialized service for evaluating resources. Cloud Config tracks configuration changes of your resources and evaluates configuration compliance. Cloud Config can help you evaluate numerous resources and maintain the continuous compliance of your cloud infrastructure. For information about Alicloud Config Configuration Recorder and how to use it, see What is Configuration Recorder.

NOTE: Available in v1.99.0+.

NOTE: The Cloud Config region only support cn-shanghai and ap-southeast-1.

Example Usage

using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AliCloud = Pulumi.AliCloud;

return await Deployment.RunAsync(() => 
{
    var example = new AliCloud.Cfg.ConfigurationRecorder("example", new()
    {
        ResourceTypes = new[]
        {
            "ACS::ECS::Instance",
            "ACS::ECS::Disk",
        },
    });

});
package main

import (
	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/cfg"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := cfg.NewConfigurationRecorder(ctx, "example", &cfg.ConfigurationRecorderArgs{
			ResourceTypes: pulumi.StringArray{
				pulumi.String("ACS::ECS::Instance"),
				pulumi.String("ACS::ECS::Disk"),
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.cfg.ConfigurationRecorder;
import com.pulumi.alicloud.cfg.ConfigurationRecorderArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;

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

    public static void stack(Context ctx) {
        var example = new ConfigurationRecorder("example", ConfigurationRecorderArgs.builder()        
            .resourceTypes(            
                "ACS::ECS::Instance",
                "ACS::ECS::Disk")
            .build());

    }
}
import pulumi
import pulumi_alicloud as alicloud

example = alicloud.cfg.ConfigurationRecorder("example", resource_types=[
    "ACS::ECS::Instance",
    "ACS::ECS::Disk",
])
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";

const example = new alicloud.cfg.ConfigurationRecorder("example", {resourceTypes: [
    "ACS::ECS::Instance",
    "ACS::ECS::Disk",
]});
resources:
  example:
    type: alicloud:cfg:ConfigurationRecorder
    properties:
      resourceTypes:
        - ACS::ECS::Instance
        - ACS::ECS::Disk

Create ConfigurationRecorder Resource

new ConfigurationRecorder(name: string, args?: ConfigurationRecorderArgs, opts?: CustomResourceOptions);
@overload
def ConfigurationRecorder(resource_name: str,
                          opts: Optional[ResourceOptions] = None,
                          enterprise_edition: Optional[bool] = None,
                          resource_types: Optional[Sequence[str]] = None)
@overload
def ConfigurationRecorder(resource_name: str,
                          args: Optional[ConfigurationRecorderArgs] = None,
                          opts: Optional[ResourceOptions] = None)
func NewConfigurationRecorder(ctx *Context, name string, args *ConfigurationRecorderArgs, opts ...ResourceOption) (*ConfigurationRecorder, error)
public ConfigurationRecorder(string name, ConfigurationRecorderArgs? args = null, CustomResourceOptions? opts = null)
public ConfigurationRecorder(String name, ConfigurationRecorderArgs args)
public ConfigurationRecorder(String name, ConfigurationRecorderArgs args, CustomResourceOptions options)
type: alicloud:cfg:ConfigurationRecorder
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

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

ConfigurationRecorder Resource Properties

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

Inputs

The ConfigurationRecorder resource accepts the following input properties:

EnterpriseEdition bool

Whether to use the enterprise version configuration audit. Valid values: true and false. Default value false. For enterprise accounts, We recommend you to use the resource alicloud_config_aggregator.

ResourceTypes List<string>

A list of resource types to be monitored. Resource types that support Cloud Config.

  • If you use an ordinary account, the resource_types supports the update operation after the process of creation is completed.
  • If you use an enterprise account, the resource_types does not support updating.
EnterpriseEdition bool

Whether to use the enterprise version configuration audit. Valid values: true and false. Default value false. For enterprise accounts, We recommend you to use the resource alicloud_config_aggregator.

ResourceTypes []string

A list of resource types to be monitored. Resource types that support Cloud Config.

  • If you use an ordinary account, the resource_types supports the update operation after the process of creation is completed.
  • If you use an enterprise account, the resource_types does not support updating.
enterpriseEdition Boolean

Whether to use the enterprise version configuration audit. Valid values: true and false. Default value false. For enterprise accounts, We recommend you to use the resource alicloud_config_aggregator.

resourceTypes List<String>

A list of resource types to be monitored. Resource types that support Cloud Config.

  • If you use an ordinary account, the resource_types supports the update operation after the process of creation is completed.
  • If you use an enterprise account, the resource_types does not support updating.
enterpriseEdition boolean

Whether to use the enterprise version configuration audit. Valid values: true and false. Default value false. For enterprise accounts, We recommend you to use the resource alicloud_config_aggregator.

resourceTypes string[]

A list of resource types to be monitored. Resource types that support Cloud Config.

  • If you use an ordinary account, the resource_types supports the update operation after the process of creation is completed.
  • If you use an enterprise account, the resource_types does not support updating.
enterprise_edition bool

Whether to use the enterprise version configuration audit. Valid values: true and false. Default value false. For enterprise accounts, We recommend you to use the resource alicloud_config_aggregator.

resource_types Sequence[str]

A list of resource types to be monitored. Resource types that support Cloud Config.

  • If you use an ordinary account, the resource_types supports the update operation after the process of creation is completed.
  • If you use an enterprise account, the resource_types does not support updating.
enterpriseEdition Boolean

Whether to use the enterprise version configuration audit. Valid values: true and false. Default value false. For enterprise accounts, We recommend you to use the resource alicloud_config_aggregator.

resourceTypes List<String>

A list of resource types to be monitored. Resource types that support Cloud Config.

  • If you use an ordinary account, the resource_types supports the update operation after the process of creation is completed.
  • If you use an enterprise account, the resource_types does not support updating.

Outputs

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

Id string

The provider-assigned unique ID for this managed resource.

OrganizationEnableStatus string

Enterprise version configuration audit enabled status. Values: REGISTRABLE: Not enabled, BUILDING: Building and REGISTERED: Enabled.

OrganizationMasterId int

The ID of the Enterprise management account.

Status string

Status of resource monitoring. Values: REGISTRABLE: Not registered, BUILDING: Under construction, REGISTERED: Registered and REBUILDING: Rebuilding.

Id string

The provider-assigned unique ID for this managed resource.

OrganizationEnableStatus string

Enterprise version configuration audit enabled status. Values: REGISTRABLE: Not enabled, BUILDING: Building and REGISTERED: Enabled.

OrganizationMasterId int

The ID of the Enterprise management account.

Status string

Status of resource monitoring. Values: REGISTRABLE: Not registered, BUILDING: Under construction, REGISTERED: Registered and REBUILDING: Rebuilding.

id String

The provider-assigned unique ID for this managed resource.

organizationEnableStatus String

Enterprise version configuration audit enabled status. Values: REGISTRABLE: Not enabled, BUILDING: Building and REGISTERED: Enabled.

organizationMasterId Integer

The ID of the Enterprise management account.

status String

Status of resource monitoring. Values: REGISTRABLE: Not registered, BUILDING: Under construction, REGISTERED: Registered and REBUILDING: Rebuilding.

id string

The provider-assigned unique ID for this managed resource.

organizationEnableStatus string

Enterprise version configuration audit enabled status. Values: REGISTRABLE: Not enabled, BUILDING: Building and REGISTERED: Enabled.

organizationMasterId number

The ID of the Enterprise management account.

status string

Status of resource monitoring. Values: REGISTRABLE: Not registered, BUILDING: Under construction, REGISTERED: Registered and REBUILDING: Rebuilding.

id str

The provider-assigned unique ID for this managed resource.

organization_enable_status str

Enterprise version configuration audit enabled status. Values: REGISTRABLE: Not enabled, BUILDING: Building and REGISTERED: Enabled.

organization_master_id int

The ID of the Enterprise management account.

status str

Status of resource monitoring. Values: REGISTRABLE: Not registered, BUILDING: Under construction, REGISTERED: Registered and REBUILDING: Rebuilding.

id String

The provider-assigned unique ID for this managed resource.

organizationEnableStatus String

Enterprise version configuration audit enabled status. Values: REGISTRABLE: Not enabled, BUILDING: Building and REGISTERED: Enabled.

organizationMasterId Number

The ID of the Enterprise management account.

status String

Status of resource monitoring. Values: REGISTRABLE: Not registered, BUILDING: Under construction, REGISTERED: Registered and REBUILDING: Rebuilding.

Look up Existing ConfigurationRecorder Resource

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

public static get(name: string, id: Input<ID>, state?: ConfigurationRecorderState, opts?: CustomResourceOptions): ConfigurationRecorder
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        enterprise_edition: Optional[bool] = None,
        organization_enable_status: Optional[str] = None,
        organization_master_id: Optional[int] = None,
        resource_types: Optional[Sequence[str]] = None,
        status: Optional[str] = None) -> ConfigurationRecorder
func GetConfigurationRecorder(ctx *Context, name string, id IDInput, state *ConfigurationRecorderState, opts ...ResourceOption) (*ConfigurationRecorder, error)
public static ConfigurationRecorder Get(string name, Input<string> id, ConfigurationRecorderState? state, CustomResourceOptions? opts = null)
public static ConfigurationRecorder get(String name, Output<String> id, ConfigurationRecorderState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
resource_name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
The following state arguments are supported:
EnterpriseEdition bool

Whether to use the enterprise version configuration audit. Valid values: true and false. Default value false. For enterprise accounts, We recommend you to use the resource alicloud_config_aggregator.

OrganizationEnableStatus string

Enterprise version configuration audit enabled status. Values: REGISTRABLE: Not enabled, BUILDING: Building and REGISTERED: Enabled.

OrganizationMasterId int

The ID of the Enterprise management account.

ResourceTypes List<string>

A list of resource types to be monitored. Resource types that support Cloud Config.

  • If you use an ordinary account, the resource_types supports the update operation after the process of creation is completed.
  • If you use an enterprise account, the resource_types does not support updating.
Status string

Status of resource monitoring. Values: REGISTRABLE: Not registered, BUILDING: Under construction, REGISTERED: Registered and REBUILDING: Rebuilding.

EnterpriseEdition bool

Whether to use the enterprise version configuration audit. Valid values: true and false. Default value false. For enterprise accounts, We recommend you to use the resource alicloud_config_aggregator.

OrganizationEnableStatus string

Enterprise version configuration audit enabled status. Values: REGISTRABLE: Not enabled, BUILDING: Building and REGISTERED: Enabled.

OrganizationMasterId int

The ID of the Enterprise management account.

ResourceTypes []string

A list of resource types to be monitored. Resource types that support Cloud Config.

  • If you use an ordinary account, the resource_types supports the update operation after the process of creation is completed.
  • If you use an enterprise account, the resource_types does not support updating.
Status string

Status of resource monitoring. Values: REGISTRABLE: Not registered, BUILDING: Under construction, REGISTERED: Registered and REBUILDING: Rebuilding.

enterpriseEdition Boolean

Whether to use the enterprise version configuration audit. Valid values: true and false. Default value false. For enterprise accounts, We recommend you to use the resource alicloud_config_aggregator.

organizationEnableStatus String

Enterprise version configuration audit enabled status. Values: REGISTRABLE: Not enabled, BUILDING: Building and REGISTERED: Enabled.

organizationMasterId Integer

The ID of the Enterprise management account.

resourceTypes List<String>

A list of resource types to be monitored. Resource types that support Cloud Config.

  • If you use an ordinary account, the resource_types supports the update operation after the process of creation is completed.
  • If you use an enterprise account, the resource_types does not support updating.
status String

Status of resource monitoring. Values: REGISTRABLE: Not registered, BUILDING: Under construction, REGISTERED: Registered and REBUILDING: Rebuilding.

enterpriseEdition boolean

Whether to use the enterprise version configuration audit. Valid values: true and false. Default value false. For enterprise accounts, We recommend you to use the resource alicloud_config_aggregator.

organizationEnableStatus string

Enterprise version configuration audit enabled status. Values: REGISTRABLE: Not enabled, BUILDING: Building and REGISTERED: Enabled.

organizationMasterId number

The ID of the Enterprise management account.

resourceTypes string[]

A list of resource types to be monitored. Resource types that support Cloud Config.

  • If you use an ordinary account, the resource_types supports the update operation after the process of creation is completed.
  • If you use an enterprise account, the resource_types does not support updating.
status string

Status of resource monitoring. Values: REGISTRABLE: Not registered, BUILDING: Under construction, REGISTERED: Registered and REBUILDING: Rebuilding.

enterprise_edition bool

Whether to use the enterprise version configuration audit. Valid values: true and false. Default value false. For enterprise accounts, We recommend you to use the resource alicloud_config_aggregator.

organization_enable_status str

Enterprise version configuration audit enabled status. Values: REGISTRABLE: Not enabled, BUILDING: Building and REGISTERED: Enabled.

organization_master_id int

The ID of the Enterprise management account.

resource_types Sequence[str]

A list of resource types to be monitored. Resource types that support Cloud Config.

  • If you use an ordinary account, the resource_types supports the update operation after the process of creation is completed.
  • If you use an enterprise account, the resource_types does not support updating.
status str

Status of resource monitoring. Values: REGISTRABLE: Not registered, BUILDING: Under construction, REGISTERED: Registered and REBUILDING: Rebuilding.

enterpriseEdition Boolean

Whether to use the enterprise version configuration audit. Valid values: true and false. Default value false. For enterprise accounts, We recommend you to use the resource alicloud_config_aggregator.

organizationEnableStatus String

Enterprise version configuration audit enabled status. Values: REGISTRABLE: Not enabled, BUILDING: Building and REGISTERED: Enabled.

organizationMasterId Number

The ID of the Enterprise management account.

resourceTypes List<String>

A list of resource types to be monitored. Resource types that support Cloud Config.

  • If you use an ordinary account, the resource_types supports the update operation after the process of creation is completed.
  • If you use an enterprise account, the resource_types does not support updating.
status String

Status of resource monitoring. Values: REGISTRABLE: Not registered, BUILDING: Under construction, REGISTERED: Registered and REBUILDING: Rebuilding.

Import

Alicloud Config Configuration Recorder can be imported using the id, e.g.

 $ pulumi import alicloud:cfg/configurationRecorder:ConfigurationRecorder example 122378463********

Package Details

Repository
Alibaba Cloud pulumi/pulumi-alicloud
License
Apache-2.0
Notes

This Pulumi package is based on the alicloud Terraform Provider.