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 since v1.99.0.
NOTE: The Cloud Config region only support
cn-shanghai
andap-southeast-1
.
Example Usage
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",
]});
import pulumi
import pulumi_alicloud as alicloud
example = alicloud.cfg.ConfigurationRecorder("example", resource_types=[
"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
})
}
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 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());
}
}
resources:
example:
type: alicloud:cfg:ConfigurationRecorder
properties:
resourceTypes:
- ACS::ECS::Instance
- ACS::ECS::Disk
Create ConfigurationRecorder Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new ConfigurationRecorder(name: string, args?: ConfigurationRecorderArgs, opts?: CustomResourceOptions);
@overload
def ConfigurationRecorder(resource_name: str,
args: Optional[ConfigurationRecorderArgs] = None,
opts: Optional[ResourceOptions] = None)
@overload
def ConfigurationRecorder(resource_name: str,
opts: Optional[ResourceOptions] = None,
enterprise_edition: Optional[bool] = None,
resource_types: Optional[Sequence[str]] = 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.
Parameters
- 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.
Constructor example
The following reference example uses placeholder values for all input properties.
var configurationRecorderResource = new AliCloud.Cfg.ConfigurationRecorder("configurationRecorderResource", new()
{
EnterpriseEdition = false,
ResourceTypes = new[]
{
"string",
},
});
example, err := cfg.NewConfigurationRecorder(ctx, "configurationRecorderResource", &cfg.ConfigurationRecorderArgs{
EnterpriseEdition: pulumi.Bool(false),
ResourceTypes: pulumi.StringArray{
pulumi.String("string"),
},
})
var configurationRecorderResource = new ConfigurationRecorder("configurationRecorderResource", ConfigurationRecorderArgs.builder()
.enterpriseEdition(false)
.resourceTypes("string")
.build());
configuration_recorder_resource = alicloud.cfg.ConfigurationRecorder("configurationRecorderResource",
enterprise_edition=False,
resource_types=["string"])
const configurationRecorderResource = new alicloud.cfg.ConfigurationRecorder("configurationRecorderResource", {
enterpriseEdition: false,
resourceTypes: ["string"],
});
type: alicloud:cfg:ConfigurationRecorder
properties:
enterpriseEdition: false
resourceTypes:
- string
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:
- Enterprise
Edition bool - Whether to use the enterprise version configuration audit. Valid values:
true
andfalse
. Default valuefalse
. For enterprise accounts, We recommend you to use the resource alicloud_config_aggregator. - Resource
Types 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.
- If you use an ordinary account, the
- Enterprise
Edition bool - Whether to use the enterprise version configuration audit. Valid values:
true
andfalse
. Default valuefalse
. For enterprise accounts, We recommend you to use the resource alicloud_config_aggregator. - Resource
Types []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.
- If you use an ordinary account, the
- enterprise
Edition Boolean - Whether to use the enterprise version configuration audit. Valid values:
true
andfalse
. Default valuefalse
. For enterprise accounts, We recommend you to use the resource alicloud_config_aggregator. - resource
Types 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.
- If you use an ordinary account, the
- enterprise
Edition boolean - Whether to use the enterprise version configuration audit. Valid values:
true
andfalse
. Default valuefalse
. For enterprise accounts, We recommend you to use the resource alicloud_config_aggregator. - resource
Types 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.
- If you use an ordinary account, the
- enterprise_
edition bool - Whether to use the enterprise version configuration audit. Valid values:
true
andfalse
. Default valuefalse
. 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.
- If you use an ordinary account, the
- enterprise
Edition Boolean - Whether to use the enterprise version configuration audit. Valid values:
true
andfalse
. Default valuefalse
. For enterprise accounts, We recommend you to use the resource alicloud_config_aggregator. - resource
Types 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.
- If you use an ordinary account, the
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.
- Organization
Enable stringStatus - Enterprise version configuration audit enabled status. Values:
REGISTRABLE
: Not enabled,BUILDING
: Building andREGISTERED
: Enabled. - Organization
Master intId - The ID of the Enterprise management account.
- Status string
- Status of resource monitoring. Values:
REGISTRABLE
: Not registered,BUILDING
: Under construction,REGISTERED
: Registered andREBUILDING
: Rebuilding.
- Id string
- The provider-assigned unique ID for this managed resource.
- Organization
Enable stringStatus - Enterprise version configuration audit enabled status. Values:
REGISTRABLE
: Not enabled,BUILDING
: Building andREGISTERED
: Enabled. - Organization
Master intId - The ID of the Enterprise management account.
- Status string
- Status of resource monitoring. Values:
REGISTRABLE
: Not registered,BUILDING
: Under construction,REGISTERED
: Registered andREBUILDING
: Rebuilding.
- id String
- The provider-assigned unique ID for this managed resource.
- organization
Enable StringStatus - Enterprise version configuration audit enabled status. Values:
REGISTRABLE
: Not enabled,BUILDING
: Building andREGISTERED
: Enabled. - organization
Master IntegerId - The ID of the Enterprise management account.
- status String
- Status of resource monitoring. Values:
REGISTRABLE
: Not registered,BUILDING
: Under construction,REGISTERED
: Registered andREBUILDING
: Rebuilding.
- id string
- The provider-assigned unique ID for this managed resource.
- organization
Enable stringStatus - Enterprise version configuration audit enabled status. Values:
REGISTRABLE
: Not enabled,BUILDING
: Building andREGISTERED
: Enabled. - organization
Master numberId - The ID of the Enterprise management account.
- status string
- Status of resource monitoring. Values:
REGISTRABLE
: Not registered,BUILDING
: Under construction,REGISTERED
: Registered andREBUILDING
: Rebuilding.
- id str
- The provider-assigned unique ID for this managed resource.
- organization_
enable_ strstatus - Enterprise version configuration audit enabled status. Values:
REGISTRABLE
: Not enabled,BUILDING
: Building andREGISTERED
: Enabled. - organization_
master_ intid - The ID of the Enterprise management account.
- status str
- Status of resource monitoring. Values:
REGISTRABLE
: Not registered,BUILDING
: Under construction,REGISTERED
: Registered andREBUILDING
: Rebuilding.
- id String
- The provider-assigned unique ID for this managed resource.
- organization
Enable StringStatus - Enterprise version configuration audit enabled status. Values:
REGISTRABLE
: Not enabled,BUILDING
: Building andREGISTERED
: Enabled. - organization
Master NumberId - The ID of the Enterprise management account.
- status String
- Status of resource monitoring. Values:
REGISTRABLE
: Not registered,BUILDING
: Under construction,REGISTERED
: Registered andREBUILDING
: 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.
- Enterprise
Edition bool - Whether to use the enterprise version configuration audit. Valid values:
true
andfalse
. Default valuefalse
. For enterprise accounts, We recommend you to use the resource alicloud_config_aggregator. - Organization
Enable stringStatus - Enterprise version configuration audit enabled status. Values:
REGISTRABLE
: Not enabled,BUILDING
: Building andREGISTERED
: Enabled. - Organization
Master intId - The ID of the Enterprise management account.
- Resource
Types 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.
- If you use an ordinary account, the
- Status string
- Status of resource monitoring. Values:
REGISTRABLE
: Not registered,BUILDING
: Under construction,REGISTERED
: Registered andREBUILDING
: Rebuilding.
- Enterprise
Edition bool - Whether to use the enterprise version configuration audit. Valid values:
true
andfalse
. Default valuefalse
. For enterprise accounts, We recommend you to use the resource alicloud_config_aggregator. - Organization
Enable stringStatus - Enterprise version configuration audit enabled status. Values:
REGISTRABLE
: Not enabled,BUILDING
: Building andREGISTERED
: Enabled. - Organization
Master intId - The ID of the Enterprise management account.
- Resource
Types []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.
- If you use an ordinary account, the
- Status string
- Status of resource monitoring. Values:
REGISTRABLE
: Not registered,BUILDING
: Under construction,REGISTERED
: Registered andREBUILDING
: Rebuilding.
- enterprise
Edition Boolean - Whether to use the enterprise version configuration audit. Valid values:
true
andfalse
. Default valuefalse
. For enterprise accounts, We recommend you to use the resource alicloud_config_aggregator. - organization
Enable StringStatus - Enterprise version configuration audit enabled status. Values:
REGISTRABLE
: Not enabled,BUILDING
: Building andREGISTERED
: Enabled. - organization
Master IntegerId - The ID of the Enterprise management account.
- resource
Types 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.
- If you use an ordinary account, the
- status String
- Status of resource monitoring. Values:
REGISTRABLE
: Not registered,BUILDING
: Under construction,REGISTERED
: Registered andREBUILDING
: Rebuilding.
- enterprise
Edition boolean - Whether to use the enterprise version configuration audit. Valid values:
true
andfalse
. Default valuefalse
. For enterprise accounts, We recommend you to use the resource alicloud_config_aggregator. - organization
Enable stringStatus - Enterprise version configuration audit enabled status. Values:
REGISTRABLE
: Not enabled,BUILDING
: Building andREGISTERED
: Enabled. - organization
Master numberId - The ID of the Enterprise management account.
- resource
Types 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.
- If you use an ordinary account, the
- status string
- Status of resource monitoring. Values:
REGISTRABLE
: Not registered,BUILDING
: Under construction,REGISTERED
: Registered andREBUILDING
: Rebuilding.
- enterprise_
edition bool - Whether to use the enterprise version configuration audit. Valid values:
true
andfalse
. Default valuefalse
. For enterprise accounts, We recommend you to use the resource alicloud_config_aggregator. - organization_
enable_ strstatus - Enterprise version configuration audit enabled status. Values:
REGISTRABLE
: Not enabled,BUILDING
: Building andREGISTERED
: Enabled. - organization_
master_ intid - 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.
- If you use an ordinary account, the
- status str
- Status of resource monitoring. Values:
REGISTRABLE
: Not registered,BUILDING
: Under construction,REGISTERED
: Registered andREBUILDING
: Rebuilding.
- enterprise
Edition Boolean - Whether to use the enterprise version configuration audit. Valid values:
true
andfalse
. Default valuefalse
. For enterprise accounts, We recommend you to use the resource alicloud_config_aggregator. - organization
Enable StringStatus - Enterprise version configuration audit enabled status. Values:
REGISTRABLE
: Not enabled,BUILDING
: Building andREGISTERED
: Enabled. - organization
Master NumberId - The ID of the Enterprise management account.
- resource
Types 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.
- If you use an ordinary account, the
- status String
- Status of resource monitoring. Values:
REGISTRABLE
: Not registered,BUILDING
: Under construction,REGISTERED
: Registered andREBUILDING
: Rebuilding.
Import
Alicloud Config Configuration Recorder can be imported using the id, e.g.
$ pulumi import alicloud:cfg/configurationRecorder:ConfigurationRecorder example 122378463********
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- Alibaba Cloud pulumi/pulumi-alicloud
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
alicloud
Terraform Provider.