Aggregator

class Aggregator : KotlinCustomResource

Provides a Cloud Config Aggregator resource. For information about Cloud Config Aggregate Config Rule and how to use it, see What is Aggregator.

NOTE: Available since v1.124.0.

Example Usage

Basic Usage

package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.resourcemanager.ResourcemanagerFunctions;
import com.pulumi.alicloud.resourcemanager.inputs.GetAccountsArgs;
import com.pulumi.alicloud.cfg.Aggregator;
import com.pulumi.alicloud.cfg.AggregatorArgs;
import com.pulumi.alicloud.cfg.inputs.AggregatorAggregatorAccountArgs;
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) {
final var config = ctx.config();
final var name = config.get("name").orElse("tf_example");
final var defaultAccounts = ResourcemanagerFunctions.getAccounts(GetAccountsArgs.builder()
.status("CreateSuccess")
.build());
var defaultAggregator = new Aggregator("defaultAggregator", AggregatorArgs.builder()
.aggregatorAccounts(AggregatorAggregatorAccountArgs.builder()
.accountId(defaultAccounts.applyValue(getAccountsResult -> getAccountsResult.accounts()[0].accountId()))
.accountName(defaultAccounts.applyValue(getAccountsResult -> getAccountsResult.accounts()[0].displayName()))
.accountType("ResourceDirectory")
.build())
.aggregatorName(name)
.description(name)
.aggregatorType("CUSTOM")
.build());
}
}

Import

Cloud Config Aggregator can be imported using the id, e.g.

$ pulumi import alicloud:cfg/aggregator:Aggregator example <id>

Properties

Link copied to clipboard

The information of account in aggregator. If the aggregator_type is RD, it is optional and means add all members in the resource directory to the account group. See aggregator_accounts below. NOTE: the field aggregator_accounts is not required from version 1.148.0.

Link copied to clipboard
val aggregatorName: Output<String>

The name of aggregator.

Link copied to clipboard
val aggregatorType: Output<String>

The type of aggregator. Valid values: CUSTOM, RD. The Default value: CUSTOM.

Link copied to clipboard
val description: Output<String>

The description of aggregator.

Link copied to clipboard
val id: Output<String>
Link copied to clipboard
val pulumiChildResources: Set<KotlinResource>
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
val status: Output<String>

The status of the resource. Valid values: 0: creating 1: normal 2: deleting.

Link copied to clipboard
val urn: Output<String>