PrivateZone

class PrivateZone : KotlinCustomResource

This topic describes how to configure PrivateZone access. PrivateZone is a VPC-based resolution and management service for private domain names. After you set a PrivateZone access, the Cloud Connect Network (CCN) and Virtual Border Router (VBR) attached to a CEN instance can access the PrivateZone service through CEN. For information about CEN Private Zone and how to use it, see Manage CEN Private Zone.

NOTE: Available since v1.83.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.AlicloudFunctions;
import com.pulumi.alicloud.inputs.GetRegionsArgs;
import com.pulumi.alicloud.vpc.Network;
import com.pulumi.alicloud.vpc.NetworkArgs;
import com.pulumi.alicloud.cen.Instance;
import com.pulumi.alicloud.cen.InstanceArgs;
import com.pulumi.alicloud.cen.InstanceAttachment;
import com.pulumi.alicloud.cen.InstanceAttachmentArgs;
import com.pulumi.alicloud.cen.PrivateZone;
import com.pulumi.alicloud.cen.PrivateZoneArgs;
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 defaultRegions = AlicloudFunctions.getRegions(GetRegionsArgs.builder()
.current(true)
.build());
var exampleNetwork = new Network("exampleNetwork", NetworkArgs.builder()
.vpcName("tf_example")
.cidrBlock("172.17.3.0/24")
.build());
var exampleInstance = new Instance("exampleInstance", InstanceArgs.builder()
.cenInstanceName("tf_example")
.description("an example for cen")
.build());
var exampleInstanceAttachment = new InstanceAttachment("exampleInstanceAttachment", InstanceAttachmentArgs.builder()
.instanceId(exampleInstance.id())
.childInstanceId(exampleNetwork.id())
.childInstanceType("VPC")
.childInstanceRegionId(defaultRegions.applyValue(getRegionsResult -> getRegionsResult.regions()[0].id()))
.build());
var defaultPrivateZone = new PrivateZone("defaultPrivateZone", PrivateZoneArgs.builder()
.accessRegionId(defaultRegions.applyValue(getRegionsResult -> getRegionsResult.regions()[0].id()))
.cenId(exampleInstanceAttachment.instanceId())
.hostRegionId(defaultRegions.applyValue(getRegionsResult -> getRegionsResult.regions()[0].id()))
.hostVpcId(exampleNetwork.id())
.build());
}
}

Import

CEN Private Zone can be imported using the id, e.g.

$ pulumi import alicloud:cen/privateZone:PrivateZone example cen-abc123456:cn-hangzhou

Properties

Link copied to clipboard
val accessRegionId: Output<String>

The access region. The access region is the region of the cloud resource that accesses the PrivateZone service through CEN.

Link copied to clipboard
val cenId: Output<String>

The ID of the CEN instance.

Link copied to clipboard
val hostRegionId: Output<String>

The service region. The service region is the target region of the PrivateZone service to be accessed through CEN.

Link copied to clipboard
val hostVpcId: Output<String>

The VPC that belongs to the service region. ->NOTE: The "alicloud.cen.PrivateZone" resource depends on the related "alicloud.cen.InstanceAttachment" resource.

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 PrivateZone service. Valid values: "Creating", "Active", "Deleting".

Link copied to clipboard
val urn: Output<String>