1. Packages
  2. Oracle Cloud Infrastructure
  3. API Docs
  4. Core
  5. Vcn
Oracle Cloud Infrastructure v1.41.0 published on Wednesday, Jun 19, 2024 by Pulumi

oci.Core.Vcn

Explore with Pulumi AI

oci logo
Oracle Cloud Infrastructure v1.41.0 published on Wednesday, Jun 19, 2024 by Pulumi

    This resource provides the Vcn resource in Oracle Cloud Infrastructure Core service.

    The VCN automatically comes with a default route table, default security list, and default set of DHCP options. For managing these resources, see Managing Default VCN Resources

    Creates a new Virtual Cloud Network (VCN). For more information, see VCNs and Subnets.

    For the VCN, you specify a list of one or more IPv4 CIDR blocks that meet the following criteria:

    • The CIDR blocks must be valid.
    • They must not overlap with each other or with the on-premises network CIDR block.
    • The number of CIDR blocks does not exceed the limit of CIDR blocks allowed per VCN.

    For a CIDR block, Oracle recommends that you use one of the private IP address ranges specified in RFC 1918 (10.0.0.0/8, 172.16/12, and 192.168/16). Example: 172.16.0.0/16. The CIDR blocks can range from /16 to /30.

    For the purposes of access control, you must provide the OCID of the compartment where you want the VCN to reside. Consult an Oracle Cloud Infrastructure administrator in your organization if you’re not sure which compartment to use. Notice that the VCN doesn’t have to be in the same compartment as the subnets or other Networking Service components. For more information about compartments and access control, see Overview of the IAM Service. For information about OCIDs, see Resource Identifiers.

    You may optionally specify a display name for the VCN, otherwise a default is provided. It does not have to be unique, and you can change it. Avoid entering confidential information.

    You can also add a DNS label for the VCN, which is required if you want the instances to use the Interent and VCN Resolver option for DNS in the VCN. For more information, see DNS in Your Virtual Cloud Network.

    The VCN automatically comes with a default route table, default security list, and default set of DHCP options. The OCID for each is returned in the response. You can’t delete these default objects, but you can change their contents (that is, change the route rules, security list rules, and so on).

    The VCN and subnets you create are not accessible until you attach an internet gateway or set up a Site-to-Site VPN or FastConnect. For more information, see Overview of the Networking Service.

    Supported Aliases

    • oci.Core.VirtualNetwork

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as oci from "@pulumi/oci";
    
    const testVcn = new oci.core.Vcn("test_vcn", {
        compartmentId: compartmentId,
        byoipv6cidrDetails: [{
            byoipv6rangeId: testByoipv6range.id,
            ipv6cidrBlock: vcnByoipv6cidrDetailsIpv6cidrBlock,
        }],
        cidrBlock: vcnCidrBlock,
        cidrBlocks: vcnCidrBlocks,
        definedTags: {
            "Operations.CostCenter": "42",
        },
        displayName: vcnDisplayName,
        dnsLabel: vcnDnsLabel,
        freeformTags: {
            Department: "Finance",
        },
        ipv6privateCidrBlocks: vcnIpv6privateCidrBlocks,
        isIpv6enabled: vcnIsIpv6enabled,
        isOracleGuaAllocationEnabled: vcnIsOracleGuaAllocationEnabled,
    });
    
    import pulumi
    import pulumi_oci as oci
    
    test_vcn = oci.core.Vcn("test_vcn",
        compartment_id=compartment_id,
        byoipv6cidr_details=[oci.core.VcnByoipv6cidrDetailArgs(
            byoipv6range_id=test_byoipv6range["id"],
            ipv6cidr_block=vcn_byoipv6cidr_details_ipv6cidr_block,
        )],
        cidr_block=vcn_cidr_block,
        cidr_blocks=vcn_cidr_blocks,
        defined_tags={
            "Operations.CostCenter": "42",
        },
        display_name=vcn_display_name,
        dns_label=vcn_dns_label,
        freeform_tags={
            "Department": "Finance",
        },
        ipv6private_cidr_blocks=vcn_ipv6private_cidr_blocks,
        is_ipv6enabled=vcn_is_ipv6enabled,
        is_oracle_gua_allocation_enabled=vcn_is_oracle_gua_allocation_enabled)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-oci/sdk/go/oci/Core"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := Core.NewVcn(ctx, "test_vcn", &Core.VcnArgs{
    			CompartmentId: pulumi.Any(compartmentId),
    			Byoipv6cidrDetails: core.VcnByoipv6cidrDetailArray{
    				&core.VcnByoipv6cidrDetailArgs{
    					Byoipv6rangeId: pulumi.Any(testByoipv6range.Id),
    					Ipv6cidrBlock:  pulumi.Any(vcnByoipv6cidrDetailsIpv6cidrBlock),
    				},
    			},
    			CidrBlock:  pulumi.Any(vcnCidrBlock),
    			CidrBlocks: pulumi.Any(vcnCidrBlocks),
    			DefinedTags: pulumi.Map{
    				"Operations.CostCenter": pulumi.Any("42"),
    			},
    			DisplayName: pulumi.Any(vcnDisplayName),
    			DnsLabel:    pulumi.Any(vcnDnsLabel),
    			FreeformTags: pulumi.Map{
    				"Department": pulumi.Any("Finance"),
    			},
    			Ipv6privateCidrBlocks:        pulumi.Any(vcnIpv6privateCidrBlocks),
    			IsIpv6enabled:                pulumi.Any(vcnIsIpv6enabled),
    			IsOracleGuaAllocationEnabled: pulumi.Any(vcnIsOracleGuaAllocationEnabled),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Oci = Pulumi.Oci;
    
    return await Deployment.RunAsync(() => 
    {
        var testVcn = new Oci.Core.Vcn("test_vcn", new()
        {
            CompartmentId = compartmentId,
            Byoipv6cidrDetails = new[]
            {
                new Oci.Core.Inputs.VcnByoipv6cidrDetailArgs
                {
                    Byoipv6rangeId = testByoipv6range.Id,
                    Ipv6cidrBlock = vcnByoipv6cidrDetailsIpv6cidrBlock,
                },
            },
            CidrBlock = vcnCidrBlock,
            CidrBlocks = vcnCidrBlocks,
            DefinedTags = 
            {
                { "Operations.CostCenter", "42" },
            },
            DisplayName = vcnDisplayName,
            DnsLabel = vcnDnsLabel,
            FreeformTags = 
            {
                { "Department", "Finance" },
            },
            Ipv6privateCidrBlocks = vcnIpv6privateCidrBlocks,
            IsIpv6enabled = vcnIsIpv6enabled,
            IsOracleGuaAllocationEnabled = vcnIsOracleGuaAllocationEnabled,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.oci.Core.Vcn;
    import com.pulumi.oci.Core.VcnArgs;
    import com.pulumi.oci.Core.inputs.VcnByoipv6cidrDetailArgs;
    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 testVcn = new Vcn("testVcn", VcnArgs.builder()
                .compartmentId(compartmentId)
                .byoipv6cidrDetails(VcnByoipv6cidrDetailArgs.builder()
                    .byoipv6rangeId(testByoipv6range.id())
                    .ipv6cidrBlock(vcnByoipv6cidrDetailsIpv6cidrBlock)
                    .build())
                .cidrBlock(vcnCidrBlock)
                .cidrBlocks(vcnCidrBlocks)
                .definedTags(Map.of("Operations.CostCenter", "42"))
                .displayName(vcnDisplayName)
                .dnsLabel(vcnDnsLabel)
                .freeformTags(Map.of("Department", "Finance"))
                .ipv6privateCidrBlocks(vcnIpv6privateCidrBlocks)
                .isIpv6enabled(vcnIsIpv6enabled)
                .isOracleGuaAllocationEnabled(vcnIsOracleGuaAllocationEnabled)
                .build());
    
        }
    }
    
    resources:
      testVcn:
        type: oci:Core:Vcn
        name: test_vcn
        properties:
          compartmentId: ${compartmentId}
          byoipv6cidrDetails:
            - byoipv6rangeId: ${testByoipv6range.id}
              ipv6cidrBlock: ${vcnByoipv6cidrDetailsIpv6cidrBlock}
          cidrBlock: ${vcnCidrBlock}
          cidrBlocks: ${vcnCidrBlocks}
          definedTags:
            Operations.CostCenter: '42'
          displayName: ${vcnDisplayName}
          dnsLabel: ${vcnDnsLabel}
          freeformTags:
            Department: Finance
          ipv6privateCidrBlocks: ${vcnIpv6privateCidrBlocks}
          isIpv6enabled: ${vcnIsIpv6enabled}
          isOracleGuaAllocationEnabled: ${vcnIsOracleGuaAllocationEnabled}
    

    Create Vcn Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new Vcn(name: string, args: VcnArgs, opts?: CustomResourceOptions);
    @overload
    def Vcn(resource_name: str,
            args: VcnArgs,
            opts: Optional[ResourceOptions] = None)
    
    @overload
    def Vcn(resource_name: str,
            opts: Optional[ResourceOptions] = None,
            compartment_id: Optional[str] = None,
            byoipv6cidr_details: Optional[Sequence[_core.VcnByoipv6cidrDetailArgs]] = None,
            cidr_block: Optional[str] = None,
            cidr_blocks: Optional[Sequence[str]] = None,
            defined_tags: Optional[Mapping[str, Any]] = None,
            display_name: Optional[str] = None,
            dns_label: Optional[str] = None,
            freeform_tags: Optional[Mapping[str, Any]] = None,
            ipv6private_cidr_blocks: Optional[Sequence[str]] = None,
            is_ipv6enabled: Optional[bool] = None,
            is_oracle_gua_allocation_enabled: Optional[bool] = None)
    func NewVcn(ctx *Context, name string, args VcnArgs, opts ...ResourceOption) (*Vcn, error)
    public Vcn(string name, VcnArgs args, CustomResourceOptions? opts = null)
    public Vcn(String name, VcnArgs args)
    public Vcn(String name, VcnArgs args, CustomResourceOptions options)
    
    type: oci:Core:Vcn
    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 VcnArgs
    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 VcnArgs
    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 VcnArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args VcnArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args VcnArgs
    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 vcnResource = new Oci.Core.Vcn("vcnResource", new()
    {
        CompartmentId = "string",
        Byoipv6cidrDetails = new[]
        {
            new Oci.Core.Inputs.VcnByoipv6cidrDetailArgs
            {
                Byoipv6rangeId = "string",
                Ipv6cidrBlock = "string",
            },
        },
        CidrBlock = "string",
        CidrBlocks = new[]
        {
            "string",
        },
        DefinedTags = 
        {
            { "string", "any" },
        },
        DisplayName = "string",
        DnsLabel = "string",
        FreeformTags = 
        {
            { "string", "any" },
        },
        Ipv6privateCidrBlocks = new[]
        {
            "string",
        },
        IsIpv6enabled = false,
        IsOracleGuaAllocationEnabled = false,
    });
    
    example, err := Core.NewVcn(ctx, "vcnResource", &Core.VcnArgs{
    	CompartmentId: pulumi.String("string"),
    	Byoipv6cidrDetails: core.VcnByoipv6cidrDetailArray{
    		&core.VcnByoipv6cidrDetailArgs{
    			Byoipv6rangeId: pulumi.String("string"),
    			Ipv6cidrBlock:  pulumi.String("string"),
    		},
    	},
    	CidrBlock: pulumi.String("string"),
    	CidrBlocks: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	DefinedTags: pulumi.Map{
    		"string": pulumi.Any("any"),
    	},
    	DisplayName: pulumi.String("string"),
    	DnsLabel:    pulumi.String("string"),
    	FreeformTags: pulumi.Map{
    		"string": pulumi.Any("any"),
    	},
    	Ipv6privateCidrBlocks: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	IsIpv6enabled:                pulumi.Bool(false),
    	IsOracleGuaAllocationEnabled: pulumi.Bool(false),
    })
    
    var vcnResource = new Vcn("vcnResource", VcnArgs.builder()
        .compartmentId("string")
        .byoipv6cidrDetails(VcnByoipv6cidrDetailArgs.builder()
            .byoipv6rangeId("string")
            .ipv6cidrBlock("string")
            .build())
        .cidrBlock("string")
        .cidrBlocks("string")
        .definedTags(Map.of("string", "any"))
        .displayName("string")
        .dnsLabel("string")
        .freeformTags(Map.of("string", "any"))
        .ipv6privateCidrBlocks("string")
        .isIpv6enabled(false)
        .isOracleGuaAllocationEnabled(false)
        .build());
    
    vcn_resource = oci.core.Vcn("vcnResource",
        compartment_id="string",
        byoipv6cidr_details=[oci.core.VcnByoipv6cidrDetailArgs(
            byoipv6range_id="string",
            ipv6cidr_block="string",
        )],
        cidr_block="string",
        cidr_blocks=["string"],
        defined_tags={
            "string": "any",
        },
        display_name="string",
        dns_label="string",
        freeform_tags={
            "string": "any",
        },
        ipv6private_cidr_blocks=["string"],
        is_ipv6enabled=False,
        is_oracle_gua_allocation_enabled=False)
    
    const vcnResource = new oci.core.Vcn("vcnResource", {
        compartmentId: "string",
        byoipv6cidrDetails: [{
            byoipv6rangeId: "string",
            ipv6cidrBlock: "string",
        }],
        cidrBlock: "string",
        cidrBlocks: ["string"],
        definedTags: {
            string: "any",
        },
        displayName: "string",
        dnsLabel: "string",
        freeformTags: {
            string: "any",
        },
        ipv6privateCidrBlocks: ["string"],
        isIpv6enabled: false,
        isOracleGuaAllocationEnabled: false,
    });
    
    type: oci:Core:Vcn
    properties:
        byoipv6cidrDetails:
            - byoipv6rangeId: string
              ipv6cidrBlock: string
        cidrBlock: string
        cidrBlocks:
            - string
        compartmentId: string
        definedTags:
            string: any
        displayName: string
        dnsLabel: string
        freeformTags:
            string: any
        ipv6privateCidrBlocks:
            - string
        isIpv6enabled: false
        isOracleGuaAllocationEnabled: false
    

    Vcn 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 Vcn resource accepts the following input properties:

    CompartmentId string
    (Updatable) The OCID of the compartment to contain the VCN.
    Byoipv6cidrDetails List<VcnByoipv6cidrDetail>
    The list of BYOIPv6 OCIDs and BYOIPv6 prefixes required to create a VCN that uses BYOIPv6 address ranges.
    CidrBlock string
    Deprecated. Do not set this value. Use cidr_blocks instead. Example: 10.0.0.0/16
    CidrBlocks List<string>
    (Updatable) The list of one or more IPv4 CIDR blocks for the VCN that meet the following criteria:

    • The CIDR blocks must be valid.
    • They must not overlap with each other or with the on-premises network CIDR block.
    • The number of CIDR blocks must not exceed the limit of CIDR blocks allowed per VCN. It is an error to set both cidr_block and cidr_blocks. Note: cidr_blocks update must be restricted to one operation at a time (either add/remove or modify one single cidr_block) or the operation will be declined. new cidr_block to be added must be placed at the end of the list. Once you migrate to using cidr_blocks from cidr_block, you will not be able to switch back. Important: Do not specify a value for cidr_block. Use this parameter instead.
    DefinedTags Dictionary<string, object>
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    DisplayName string
    (Updatable) A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
    DnsLabel string

    A DNS label for the VCN, used in conjunction with the VNIC's hostname and subnet's DNS label to form a fully qualified domain name (FQDN) for each VNIC within this subnet (for example, bminstance1.subnet123.vcn1.oraclevcn.com). Not required to be unique, but it's a best practice to set unique DNS labels for VCNs in your tenancy. Must be an alphanumeric string that begins with a letter. The value cannot be changed. You must set this value if you want instances to be able to use hostnames to resolve other instances in the VCN. Otherwise the Internet and VCN Resolver will not work.

    For more information, see DNS in Your Virtual Cloud Network.

    Example: vcn1

    FreeformTags Dictionary<string, object>
    (Updatable) Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
    Ipv6privateCidrBlocks List<string>

    The list of one or more ULA or Private IPv6 CIDR blocks for the vcn that meets the following criteria:

    • The CIDR blocks must be valid.
    • Multiple CIDR blocks must not overlap each other or the on-premises network prefix.
    • The number of CIDR blocks must not exceed the limit of IPv6 prefixes allowed to a VCN.

    Important: Do not specify a value for ipv6cidr_block. Use this parameter instead.

    IsIpv6enabled bool
    Whether IPv6 is enabled for the VCN. Default is false. If enabled, Oracle will assign the VCN a IPv6 /56 CIDR block. You may skip having Oracle allocate the VCN a IPv6 /56 CIDR block by setting isOracleGuaAllocationEnabled to false. For important details about IPv6 addressing in a VCN, see IPv6 Addresses. Example: true
    IsOracleGuaAllocationEnabled bool

    Specifies whether to skip Oracle allocated IPv6 GUA. By default, Oracle will allocate one GUA of /56 size for an IPv6 enabled VCN.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    CompartmentId string
    (Updatable) The OCID of the compartment to contain the VCN.
    Byoipv6cidrDetails []VcnByoipv6cidrDetailArgs
    The list of BYOIPv6 OCIDs and BYOIPv6 prefixes required to create a VCN that uses BYOIPv6 address ranges.
    CidrBlock string
    Deprecated. Do not set this value. Use cidr_blocks instead. Example: 10.0.0.0/16
    CidrBlocks []string
    (Updatable) The list of one or more IPv4 CIDR blocks for the VCN that meet the following criteria:

    • The CIDR blocks must be valid.
    • They must not overlap with each other or with the on-premises network CIDR block.
    • The number of CIDR blocks must not exceed the limit of CIDR blocks allowed per VCN. It is an error to set both cidr_block and cidr_blocks. Note: cidr_blocks update must be restricted to one operation at a time (either add/remove or modify one single cidr_block) or the operation will be declined. new cidr_block to be added must be placed at the end of the list. Once you migrate to using cidr_blocks from cidr_block, you will not be able to switch back. Important: Do not specify a value for cidr_block. Use this parameter instead.
    DefinedTags map[string]interface{}
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    DisplayName string
    (Updatable) A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
    DnsLabel string

    A DNS label for the VCN, used in conjunction with the VNIC's hostname and subnet's DNS label to form a fully qualified domain name (FQDN) for each VNIC within this subnet (for example, bminstance1.subnet123.vcn1.oraclevcn.com). Not required to be unique, but it's a best practice to set unique DNS labels for VCNs in your tenancy. Must be an alphanumeric string that begins with a letter. The value cannot be changed. You must set this value if you want instances to be able to use hostnames to resolve other instances in the VCN. Otherwise the Internet and VCN Resolver will not work.

    For more information, see DNS in Your Virtual Cloud Network.

    Example: vcn1

    FreeformTags map[string]interface{}
    (Updatable) Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
    Ipv6privateCidrBlocks []string

    The list of one or more ULA or Private IPv6 CIDR blocks for the vcn that meets the following criteria:

    • The CIDR blocks must be valid.
    • Multiple CIDR blocks must not overlap each other or the on-premises network prefix.
    • The number of CIDR blocks must not exceed the limit of IPv6 prefixes allowed to a VCN.

    Important: Do not specify a value for ipv6cidr_block. Use this parameter instead.

    IsIpv6enabled bool
    Whether IPv6 is enabled for the VCN. Default is false. If enabled, Oracle will assign the VCN a IPv6 /56 CIDR block. You may skip having Oracle allocate the VCN a IPv6 /56 CIDR block by setting isOracleGuaAllocationEnabled to false. For important details about IPv6 addressing in a VCN, see IPv6 Addresses. Example: true
    IsOracleGuaAllocationEnabled bool

    Specifies whether to skip Oracle allocated IPv6 GUA. By default, Oracle will allocate one GUA of /56 size for an IPv6 enabled VCN.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    compartmentId String
    (Updatable) The OCID of the compartment to contain the VCN.
    byoipv6cidrDetails List<VcnByoipv6cidrDetail>
    The list of BYOIPv6 OCIDs and BYOIPv6 prefixes required to create a VCN that uses BYOIPv6 address ranges.
    cidrBlock String
    Deprecated. Do not set this value. Use cidr_blocks instead. Example: 10.0.0.0/16
    cidrBlocks List<String>
    (Updatable) The list of one or more IPv4 CIDR blocks for the VCN that meet the following criteria:

    • The CIDR blocks must be valid.
    • They must not overlap with each other or with the on-premises network CIDR block.
    • The number of CIDR blocks must not exceed the limit of CIDR blocks allowed per VCN. It is an error to set both cidr_block and cidr_blocks. Note: cidr_blocks update must be restricted to one operation at a time (either add/remove or modify one single cidr_block) or the operation will be declined. new cidr_block to be added must be placed at the end of the list. Once you migrate to using cidr_blocks from cidr_block, you will not be able to switch back. Important: Do not specify a value for cidr_block. Use this parameter instead.
    definedTags Map<String,Object>
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    displayName String
    (Updatable) A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
    dnsLabel String

    A DNS label for the VCN, used in conjunction with the VNIC's hostname and subnet's DNS label to form a fully qualified domain name (FQDN) for each VNIC within this subnet (for example, bminstance1.subnet123.vcn1.oraclevcn.com). Not required to be unique, but it's a best practice to set unique DNS labels for VCNs in your tenancy. Must be an alphanumeric string that begins with a letter. The value cannot be changed. You must set this value if you want instances to be able to use hostnames to resolve other instances in the VCN. Otherwise the Internet and VCN Resolver will not work.

    For more information, see DNS in Your Virtual Cloud Network.

    Example: vcn1

    freeformTags Map<String,Object>
    (Updatable) Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
    ipv6privateCidrBlocks List<String>

    The list of one or more ULA or Private IPv6 CIDR blocks for the vcn that meets the following criteria:

    • The CIDR blocks must be valid.
    • Multiple CIDR blocks must not overlap each other or the on-premises network prefix.
    • The number of CIDR blocks must not exceed the limit of IPv6 prefixes allowed to a VCN.

    Important: Do not specify a value for ipv6cidr_block. Use this parameter instead.

    isIpv6enabled Boolean
    Whether IPv6 is enabled for the VCN. Default is false. If enabled, Oracle will assign the VCN a IPv6 /56 CIDR block. You may skip having Oracle allocate the VCN a IPv6 /56 CIDR block by setting isOracleGuaAllocationEnabled to false. For important details about IPv6 addressing in a VCN, see IPv6 Addresses. Example: true
    isOracleGuaAllocationEnabled Boolean

    Specifies whether to skip Oracle allocated IPv6 GUA. By default, Oracle will allocate one GUA of /56 size for an IPv6 enabled VCN.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    compartmentId string
    (Updatable) The OCID of the compartment to contain the VCN.
    byoipv6cidrDetails VcnByoipv6cidrDetail[]
    The list of BYOIPv6 OCIDs and BYOIPv6 prefixes required to create a VCN that uses BYOIPv6 address ranges.
    cidrBlock string
    Deprecated. Do not set this value. Use cidr_blocks instead. Example: 10.0.0.0/16
    cidrBlocks string[]
    (Updatable) The list of one or more IPv4 CIDR blocks for the VCN that meet the following criteria:

    • The CIDR blocks must be valid.
    • They must not overlap with each other or with the on-premises network CIDR block.
    • The number of CIDR blocks must not exceed the limit of CIDR blocks allowed per VCN. It is an error to set both cidr_block and cidr_blocks. Note: cidr_blocks update must be restricted to one operation at a time (either add/remove or modify one single cidr_block) or the operation will be declined. new cidr_block to be added must be placed at the end of the list. Once you migrate to using cidr_blocks from cidr_block, you will not be able to switch back. Important: Do not specify a value for cidr_block. Use this parameter instead.
    definedTags {[key: string]: any}
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    displayName string
    (Updatable) A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
    dnsLabel string

    A DNS label for the VCN, used in conjunction with the VNIC's hostname and subnet's DNS label to form a fully qualified domain name (FQDN) for each VNIC within this subnet (for example, bminstance1.subnet123.vcn1.oraclevcn.com). Not required to be unique, but it's a best practice to set unique DNS labels for VCNs in your tenancy. Must be an alphanumeric string that begins with a letter. The value cannot be changed. You must set this value if you want instances to be able to use hostnames to resolve other instances in the VCN. Otherwise the Internet and VCN Resolver will not work.

    For more information, see DNS in Your Virtual Cloud Network.

    Example: vcn1

    freeformTags {[key: string]: any}
    (Updatable) Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
    ipv6privateCidrBlocks string[]

    The list of one or more ULA or Private IPv6 CIDR blocks for the vcn that meets the following criteria:

    • The CIDR blocks must be valid.
    • Multiple CIDR blocks must not overlap each other or the on-premises network prefix.
    • The number of CIDR blocks must not exceed the limit of IPv6 prefixes allowed to a VCN.

    Important: Do not specify a value for ipv6cidr_block. Use this parameter instead.

    isIpv6enabled boolean
    Whether IPv6 is enabled for the VCN. Default is false. If enabled, Oracle will assign the VCN a IPv6 /56 CIDR block. You may skip having Oracle allocate the VCN a IPv6 /56 CIDR block by setting isOracleGuaAllocationEnabled to false. For important details about IPv6 addressing in a VCN, see IPv6 Addresses. Example: true
    isOracleGuaAllocationEnabled boolean

    Specifies whether to skip Oracle allocated IPv6 GUA. By default, Oracle will allocate one GUA of /56 size for an IPv6 enabled VCN.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    compartment_id str
    (Updatable) The OCID of the compartment to contain the VCN.
    byoipv6cidr_details Sequence[core.VcnByoipv6cidrDetailArgs]
    The list of BYOIPv6 OCIDs and BYOIPv6 prefixes required to create a VCN that uses BYOIPv6 address ranges.
    cidr_block str
    Deprecated. Do not set this value. Use cidr_blocks instead. Example: 10.0.0.0/16
    cidr_blocks Sequence[str]
    (Updatable) The list of one or more IPv4 CIDR blocks for the VCN that meet the following criteria:

    • The CIDR blocks must be valid.
    • They must not overlap with each other or with the on-premises network CIDR block.
    • The number of CIDR blocks must not exceed the limit of CIDR blocks allowed per VCN. It is an error to set both cidr_block and cidr_blocks. Note: cidr_blocks update must be restricted to one operation at a time (either add/remove or modify one single cidr_block) or the operation will be declined. new cidr_block to be added must be placed at the end of the list. Once you migrate to using cidr_blocks from cidr_block, you will not be able to switch back. Important: Do not specify a value for cidr_block. Use this parameter instead.
    defined_tags Mapping[str, Any]
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    display_name str
    (Updatable) A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
    dns_label str

    A DNS label for the VCN, used in conjunction with the VNIC's hostname and subnet's DNS label to form a fully qualified domain name (FQDN) for each VNIC within this subnet (for example, bminstance1.subnet123.vcn1.oraclevcn.com). Not required to be unique, but it's a best practice to set unique DNS labels for VCNs in your tenancy. Must be an alphanumeric string that begins with a letter. The value cannot be changed. You must set this value if you want instances to be able to use hostnames to resolve other instances in the VCN. Otherwise the Internet and VCN Resolver will not work.

    For more information, see DNS in Your Virtual Cloud Network.

    Example: vcn1

    freeform_tags Mapping[str, Any]
    (Updatable) Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
    ipv6private_cidr_blocks Sequence[str]

    The list of one or more ULA or Private IPv6 CIDR blocks for the vcn that meets the following criteria:

    • The CIDR blocks must be valid.
    • Multiple CIDR blocks must not overlap each other or the on-premises network prefix.
    • The number of CIDR blocks must not exceed the limit of IPv6 prefixes allowed to a VCN.

    Important: Do not specify a value for ipv6cidr_block. Use this parameter instead.

    is_ipv6enabled bool
    Whether IPv6 is enabled for the VCN. Default is false. If enabled, Oracle will assign the VCN a IPv6 /56 CIDR block. You may skip having Oracle allocate the VCN a IPv6 /56 CIDR block by setting isOracleGuaAllocationEnabled to false. For important details about IPv6 addressing in a VCN, see IPv6 Addresses. Example: true
    is_oracle_gua_allocation_enabled bool

    Specifies whether to skip Oracle allocated IPv6 GUA. By default, Oracle will allocate one GUA of /56 size for an IPv6 enabled VCN.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    compartmentId String
    (Updatable) The OCID of the compartment to contain the VCN.
    byoipv6cidrDetails List<Property Map>
    The list of BYOIPv6 OCIDs and BYOIPv6 prefixes required to create a VCN that uses BYOIPv6 address ranges.
    cidrBlock String
    Deprecated. Do not set this value. Use cidr_blocks instead. Example: 10.0.0.0/16
    cidrBlocks List<String>
    (Updatable) The list of one or more IPv4 CIDR blocks for the VCN that meet the following criteria:

    • The CIDR blocks must be valid.
    • They must not overlap with each other or with the on-premises network CIDR block.
    • The number of CIDR blocks must not exceed the limit of CIDR blocks allowed per VCN. It is an error to set both cidr_block and cidr_blocks. Note: cidr_blocks update must be restricted to one operation at a time (either add/remove or modify one single cidr_block) or the operation will be declined. new cidr_block to be added must be placed at the end of the list. Once you migrate to using cidr_blocks from cidr_block, you will not be able to switch back. Important: Do not specify a value for cidr_block. Use this parameter instead.
    definedTags Map<Any>
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    displayName String
    (Updatable) A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
    dnsLabel String

    A DNS label for the VCN, used in conjunction with the VNIC's hostname and subnet's DNS label to form a fully qualified domain name (FQDN) for each VNIC within this subnet (for example, bminstance1.subnet123.vcn1.oraclevcn.com). Not required to be unique, but it's a best practice to set unique DNS labels for VCNs in your tenancy. Must be an alphanumeric string that begins with a letter. The value cannot be changed. You must set this value if you want instances to be able to use hostnames to resolve other instances in the VCN. Otherwise the Internet and VCN Resolver will not work.

    For more information, see DNS in Your Virtual Cloud Network.

    Example: vcn1

    freeformTags Map<Any>
    (Updatable) Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
    ipv6privateCidrBlocks List<String>

    The list of one or more ULA or Private IPv6 CIDR blocks for the vcn that meets the following criteria:

    • The CIDR blocks must be valid.
    • Multiple CIDR blocks must not overlap each other or the on-premises network prefix.
    • The number of CIDR blocks must not exceed the limit of IPv6 prefixes allowed to a VCN.

    Important: Do not specify a value for ipv6cidr_block. Use this parameter instead.

    isIpv6enabled Boolean
    Whether IPv6 is enabled for the VCN. Default is false. If enabled, Oracle will assign the VCN a IPv6 /56 CIDR block. You may skip having Oracle allocate the VCN a IPv6 /56 CIDR block by setting isOracleGuaAllocationEnabled to false. For important details about IPv6 addressing in a VCN, see IPv6 Addresses. Example: true
    isOracleGuaAllocationEnabled Boolean

    Specifies whether to skip Oracle allocated IPv6 GUA. By default, Oracle will allocate one GUA of /56 size for an IPv6 enabled VCN.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    Outputs

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

    Byoipv6cidrBlocks List<string>
    The list of BYOIPv6 prefixes required to create a VCN that uses BYOIPv6 ranges.
    DefaultDhcpOptionsId string
    The OCID for the VCN's default set of DHCP options.
    DefaultRouteTableId string
    The OCID for the VCN's default route table.
    DefaultSecurityListId string
    The OCID for the VCN's default security list.
    Id string
    The provider-assigned unique ID for this managed resource.
    Ipv6cidrBlocks List<string>
    For an IPv6-enabled VCN, this is the list of IPv6 prefixes for the VCN's IP address space. The prefixes are provided by Oracle and the sizes are always /56.
    State string
    The VCN's current state.
    TimeCreated string
    The date and time the VCN was created, in the format defined by RFC3339. Example: 2016-08-25T21:10:29.600Z
    VcnDomainName string
    The VCN's domain name, which consists of the VCN's DNS label, and the oraclevcn.com domain.
    Byoipv6cidrBlocks []string
    The list of BYOIPv6 prefixes required to create a VCN that uses BYOIPv6 ranges.
    DefaultDhcpOptionsId string
    The OCID for the VCN's default set of DHCP options.
    DefaultRouteTableId string
    The OCID for the VCN's default route table.
    DefaultSecurityListId string
    The OCID for the VCN's default security list.
    Id string
    The provider-assigned unique ID for this managed resource.
    Ipv6cidrBlocks []string
    For an IPv6-enabled VCN, this is the list of IPv6 prefixes for the VCN's IP address space. The prefixes are provided by Oracle and the sizes are always /56.
    State string
    The VCN's current state.
    TimeCreated string
    The date and time the VCN was created, in the format defined by RFC3339. Example: 2016-08-25T21:10:29.600Z
    VcnDomainName string
    The VCN's domain name, which consists of the VCN's DNS label, and the oraclevcn.com domain.
    byoipv6cidrBlocks List<String>
    The list of BYOIPv6 prefixes required to create a VCN that uses BYOIPv6 ranges.
    defaultDhcpOptionsId String
    The OCID for the VCN's default set of DHCP options.
    defaultRouteTableId String
    The OCID for the VCN's default route table.
    defaultSecurityListId String
    The OCID for the VCN's default security list.
    id String
    The provider-assigned unique ID for this managed resource.
    ipv6cidrBlocks List<String>
    For an IPv6-enabled VCN, this is the list of IPv6 prefixes for the VCN's IP address space. The prefixes are provided by Oracle and the sizes are always /56.
    state String
    The VCN's current state.
    timeCreated String
    The date and time the VCN was created, in the format defined by RFC3339. Example: 2016-08-25T21:10:29.600Z
    vcnDomainName String
    The VCN's domain name, which consists of the VCN's DNS label, and the oraclevcn.com domain.
    byoipv6cidrBlocks string[]
    The list of BYOIPv6 prefixes required to create a VCN that uses BYOIPv6 ranges.
    defaultDhcpOptionsId string
    The OCID for the VCN's default set of DHCP options.
    defaultRouteTableId string
    The OCID for the VCN's default route table.
    defaultSecurityListId string
    The OCID for the VCN's default security list.
    id string
    The provider-assigned unique ID for this managed resource.
    ipv6cidrBlocks string[]
    For an IPv6-enabled VCN, this is the list of IPv6 prefixes for the VCN's IP address space. The prefixes are provided by Oracle and the sizes are always /56.
    state string
    The VCN's current state.
    timeCreated string
    The date and time the VCN was created, in the format defined by RFC3339. Example: 2016-08-25T21:10:29.600Z
    vcnDomainName string
    The VCN's domain name, which consists of the VCN's DNS label, and the oraclevcn.com domain.
    byoipv6cidr_blocks Sequence[str]
    The list of BYOIPv6 prefixes required to create a VCN that uses BYOIPv6 ranges.
    default_dhcp_options_id str
    The OCID for the VCN's default set of DHCP options.
    default_route_table_id str
    The OCID for the VCN's default route table.
    default_security_list_id str
    The OCID for the VCN's default security list.
    id str
    The provider-assigned unique ID for this managed resource.
    ipv6cidr_blocks Sequence[str]
    For an IPv6-enabled VCN, this is the list of IPv6 prefixes for the VCN's IP address space. The prefixes are provided by Oracle and the sizes are always /56.
    state str
    The VCN's current state.
    time_created str
    The date and time the VCN was created, in the format defined by RFC3339. Example: 2016-08-25T21:10:29.600Z
    vcn_domain_name str
    The VCN's domain name, which consists of the VCN's DNS label, and the oraclevcn.com domain.
    byoipv6cidrBlocks List<String>
    The list of BYOIPv6 prefixes required to create a VCN that uses BYOIPv6 ranges.
    defaultDhcpOptionsId String
    The OCID for the VCN's default set of DHCP options.
    defaultRouteTableId String
    The OCID for the VCN's default route table.
    defaultSecurityListId String
    The OCID for the VCN's default security list.
    id String
    The provider-assigned unique ID for this managed resource.
    ipv6cidrBlocks List<String>
    For an IPv6-enabled VCN, this is the list of IPv6 prefixes for the VCN's IP address space. The prefixes are provided by Oracle and the sizes are always /56.
    state String
    The VCN's current state.
    timeCreated String
    The date and time the VCN was created, in the format defined by RFC3339. Example: 2016-08-25T21:10:29.600Z
    vcnDomainName String
    The VCN's domain name, which consists of the VCN's DNS label, and the oraclevcn.com domain.

    Look up Existing Vcn Resource

    Get an existing Vcn 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?: VcnState, opts?: CustomResourceOptions): Vcn
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            byoipv6cidr_blocks: Optional[Sequence[str]] = None,
            byoipv6cidr_details: Optional[Sequence[_core.VcnByoipv6cidrDetailArgs]] = None,
            cidr_block: Optional[str] = None,
            cidr_blocks: Optional[Sequence[str]] = None,
            compartment_id: Optional[str] = None,
            default_dhcp_options_id: Optional[str] = None,
            default_route_table_id: Optional[str] = None,
            default_security_list_id: Optional[str] = None,
            defined_tags: Optional[Mapping[str, Any]] = None,
            display_name: Optional[str] = None,
            dns_label: Optional[str] = None,
            freeform_tags: Optional[Mapping[str, Any]] = None,
            ipv6cidr_blocks: Optional[Sequence[str]] = None,
            ipv6private_cidr_blocks: Optional[Sequence[str]] = None,
            is_ipv6enabled: Optional[bool] = None,
            is_oracle_gua_allocation_enabled: Optional[bool] = None,
            state: Optional[str] = None,
            time_created: Optional[str] = None,
            vcn_domain_name: Optional[str] = None) -> Vcn
    func GetVcn(ctx *Context, name string, id IDInput, state *VcnState, opts ...ResourceOption) (*Vcn, error)
    public static Vcn Get(string name, Input<string> id, VcnState? state, CustomResourceOptions? opts = null)
    public static Vcn get(String name, Output<String> id, VcnState 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:
    Byoipv6cidrBlocks List<string>
    The list of BYOIPv6 prefixes required to create a VCN that uses BYOIPv6 ranges.
    Byoipv6cidrDetails List<VcnByoipv6cidrDetail>
    The list of BYOIPv6 OCIDs and BYOIPv6 prefixes required to create a VCN that uses BYOIPv6 address ranges.
    CidrBlock string
    Deprecated. Do not set this value. Use cidr_blocks instead. Example: 10.0.0.0/16
    CidrBlocks List<string>
    (Updatable) The list of one or more IPv4 CIDR blocks for the VCN that meet the following criteria:

    • The CIDR blocks must be valid.
    • They must not overlap with each other or with the on-premises network CIDR block.
    • The number of CIDR blocks must not exceed the limit of CIDR blocks allowed per VCN. It is an error to set both cidr_block and cidr_blocks. Note: cidr_blocks update must be restricted to one operation at a time (either add/remove or modify one single cidr_block) or the operation will be declined. new cidr_block to be added must be placed at the end of the list. Once you migrate to using cidr_blocks from cidr_block, you will not be able to switch back. Important: Do not specify a value for cidr_block. Use this parameter instead.
    CompartmentId string
    (Updatable) The OCID of the compartment to contain the VCN.
    DefaultDhcpOptionsId string
    The OCID for the VCN's default set of DHCP options.
    DefaultRouteTableId string
    The OCID for the VCN's default route table.
    DefaultSecurityListId string
    The OCID for the VCN's default security list.
    DefinedTags Dictionary<string, object>
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    DisplayName string
    (Updatable) A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
    DnsLabel string

    A DNS label for the VCN, used in conjunction with the VNIC's hostname and subnet's DNS label to form a fully qualified domain name (FQDN) for each VNIC within this subnet (for example, bminstance1.subnet123.vcn1.oraclevcn.com). Not required to be unique, but it's a best practice to set unique DNS labels for VCNs in your tenancy. Must be an alphanumeric string that begins with a letter. The value cannot be changed. You must set this value if you want instances to be able to use hostnames to resolve other instances in the VCN. Otherwise the Internet and VCN Resolver will not work.

    For more information, see DNS in Your Virtual Cloud Network.

    Example: vcn1

    FreeformTags Dictionary<string, object>
    (Updatable) Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
    Ipv6cidrBlocks List<string>
    For an IPv6-enabled VCN, this is the list of IPv6 prefixes for the VCN's IP address space. The prefixes are provided by Oracle and the sizes are always /56.
    Ipv6privateCidrBlocks List<string>

    The list of one or more ULA or Private IPv6 CIDR blocks for the vcn that meets the following criteria:

    • The CIDR blocks must be valid.
    • Multiple CIDR blocks must not overlap each other or the on-premises network prefix.
    • The number of CIDR blocks must not exceed the limit of IPv6 prefixes allowed to a VCN.

    Important: Do not specify a value for ipv6cidr_block. Use this parameter instead.

    IsIpv6enabled bool
    Whether IPv6 is enabled for the VCN. Default is false. If enabled, Oracle will assign the VCN a IPv6 /56 CIDR block. You may skip having Oracle allocate the VCN a IPv6 /56 CIDR block by setting isOracleGuaAllocationEnabled to false. For important details about IPv6 addressing in a VCN, see IPv6 Addresses. Example: true
    IsOracleGuaAllocationEnabled bool

    Specifies whether to skip Oracle allocated IPv6 GUA. By default, Oracle will allocate one GUA of /56 size for an IPv6 enabled VCN.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    State string
    The VCN's current state.
    TimeCreated string
    The date and time the VCN was created, in the format defined by RFC3339. Example: 2016-08-25T21:10:29.600Z
    VcnDomainName string
    The VCN's domain name, which consists of the VCN's DNS label, and the oraclevcn.com domain.
    Byoipv6cidrBlocks []string
    The list of BYOIPv6 prefixes required to create a VCN that uses BYOIPv6 ranges.
    Byoipv6cidrDetails []VcnByoipv6cidrDetailArgs
    The list of BYOIPv6 OCIDs and BYOIPv6 prefixes required to create a VCN that uses BYOIPv6 address ranges.
    CidrBlock string
    Deprecated. Do not set this value. Use cidr_blocks instead. Example: 10.0.0.0/16
    CidrBlocks []string
    (Updatable) The list of one or more IPv4 CIDR blocks for the VCN that meet the following criteria:

    • The CIDR blocks must be valid.
    • They must not overlap with each other or with the on-premises network CIDR block.
    • The number of CIDR blocks must not exceed the limit of CIDR blocks allowed per VCN. It is an error to set both cidr_block and cidr_blocks. Note: cidr_blocks update must be restricted to one operation at a time (either add/remove or modify one single cidr_block) or the operation will be declined. new cidr_block to be added must be placed at the end of the list. Once you migrate to using cidr_blocks from cidr_block, you will not be able to switch back. Important: Do not specify a value for cidr_block. Use this parameter instead.
    CompartmentId string
    (Updatable) The OCID of the compartment to contain the VCN.
    DefaultDhcpOptionsId string
    The OCID for the VCN's default set of DHCP options.
    DefaultRouteTableId string
    The OCID for the VCN's default route table.
    DefaultSecurityListId string
    The OCID for the VCN's default security list.
    DefinedTags map[string]interface{}
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    DisplayName string
    (Updatable) A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
    DnsLabel string

    A DNS label for the VCN, used in conjunction with the VNIC's hostname and subnet's DNS label to form a fully qualified domain name (FQDN) for each VNIC within this subnet (for example, bminstance1.subnet123.vcn1.oraclevcn.com). Not required to be unique, but it's a best practice to set unique DNS labels for VCNs in your tenancy. Must be an alphanumeric string that begins with a letter. The value cannot be changed. You must set this value if you want instances to be able to use hostnames to resolve other instances in the VCN. Otherwise the Internet and VCN Resolver will not work.

    For more information, see DNS in Your Virtual Cloud Network.

    Example: vcn1

    FreeformTags map[string]interface{}
    (Updatable) Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
    Ipv6cidrBlocks []string
    For an IPv6-enabled VCN, this is the list of IPv6 prefixes for the VCN's IP address space. The prefixes are provided by Oracle and the sizes are always /56.
    Ipv6privateCidrBlocks []string

    The list of one or more ULA or Private IPv6 CIDR blocks for the vcn that meets the following criteria:

    • The CIDR blocks must be valid.
    • Multiple CIDR blocks must not overlap each other or the on-premises network prefix.
    • The number of CIDR blocks must not exceed the limit of IPv6 prefixes allowed to a VCN.

    Important: Do not specify a value for ipv6cidr_block. Use this parameter instead.

    IsIpv6enabled bool
    Whether IPv6 is enabled for the VCN. Default is false. If enabled, Oracle will assign the VCN a IPv6 /56 CIDR block. You may skip having Oracle allocate the VCN a IPv6 /56 CIDR block by setting isOracleGuaAllocationEnabled to false. For important details about IPv6 addressing in a VCN, see IPv6 Addresses. Example: true
    IsOracleGuaAllocationEnabled bool

    Specifies whether to skip Oracle allocated IPv6 GUA. By default, Oracle will allocate one GUA of /56 size for an IPv6 enabled VCN.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    State string
    The VCN's current state.
    TimeCreated string
    The date and time the VCN was created, in the format defined by RFC3339. Example: 2016-08-25T21:10:29.600Z
    VcnDomainName string
    The VCN's domain name, which consists of the VCN's DNS label, and the oraclevcn.com domain.
    byoipv6cidrBlocks List<String>
    The list of BYOIPv6 prefixes required to create a VCN that uses BYOIPv6 ranges.
    byoipv6cidrDetails List<VcnByoipv6cidrDetail>
    The list of BYOIPv6 OCIDs and BYOIPv6 prefixes required to create a VCN that uses BYOIPv6 address ranges.
    cidrBlock String
    Deprecated. Do not set this value. Use cidr_blocks instead. Example: 10.0.0.0/16
    cidrBlocks List<String>
    (Updatable) The list of one or more IPv4 CIDR blocks for the VCN that meet the following criteria:

    • The CIDR blocks must be valid.
    • They must not overlap with each other or with the on-premises network CIDR block.
    • The number of CIDR blocks must not exceed the limit of CIDR blocks allowed per VCN. It is an error to set both cidr_block and cidr_blocks. Note: cidr_blocks update must be restricted to one operation at a time (either add/remove or modify one single cidr_block) or the operation will be declined. new cidr_block to be added must be placed at the end of the list. Once you migrate to using cidr_blocks from cidr_block, you will not be able to switch back. Important: Do not specify a value for cidr_block. Use this parameter instead.
    compartmentId String
    (Updatable) The OCID of the compartment to contain the VCN.
    defaultDhcpOptionsId String
    The OCID for the VCN's default set of DHCP options.
    defaultRouteTableId String
    The OCID for the VCN's default route table.
    defaultSecurityListId String
    The OCID for the VCN's default security list.
    definedTags Map<String,Object>
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    displayName String
    (Updatable) A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
    dnsLabel String

    A DNS label for the VCN, used in conjunction with the VNIC's hostname and subnet's DNS label to form a fully qualified domain name (FQDN) for each VNIC within this subnet (for example, bminstance1.subnet123.vcn1.oraclevcn.com). Not required to be unique, but it's a best practice to set unique DNS labels for VCNs in your tenancy. Must be an alphanumeric string that begins with a letter. The value cannot be changed. You must set this value if you want instances to be able to use hostnames to resolve other instances in the VCN. Otherwise the Internet and VCN Resolver will not work.

    For more information, see DNS in Your Virtual Cloud Network.

    Example: vcn1

    freeformTags Map<String,Object>
    (Updatable) Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
    ipv6cidrBlocks List<String>
    For an IPv6-enabled VCN, this is the list of IPv6 prefixes for the VCN's IP address space. The prefixes are provided by Oracle and the sizes are always /56.
    ipv6privateCidrBlocks List<String>

    The list of one or more ULA or Private IPv6 CIDR blocks for the vcn that meets the following criteria:

    • The CIDR blocks must be valid.
    • Multiple CIDR blocks must not overlap each other or the on-premises network prefix.
    • The number of CIDR blocks must not exceed the limit of IPv6 prefixes allowed to a VCN.

    Important: Do not specify a value for ipv6cidr_block. Use this parameter instead.

    isIpv6enabled Boolean
    Whether IPv6 is enabled for the VCN. Default is false. If enabled, Oracle will assign the VCN a IPv6 /56 CIDR block. You may skip having Oracle allocate the VCN a IPv6 /56 CIDR block by setting isOracleGuaAllocationEnabled to false. For important details about IPv6 addressing in a VCN, see IPv6 Addresses. Example: true
    isOracleGuaAllocationEnabled Boolean

    Specifies whether to skip Oracle allocated IPv6 GUA. By default, Oracle will allocate one GUA of /56 size for an IPv6 enabled VCN.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    state String
    The VCN's current state.
    timeCreated String
    The date and time the VCN was created, in the format defined by RFC3339. Example: 2016-08-25T21:10:29.600Z
    vcnDomainName String
    The VCN's domain name, which consists of the VCN's DNS label, and the oraclevcn.com domain.
    byoipv6cidrBlocks string[]
    The list of BYOIPv6 prefixes required to create a VCN that uses BYOIPv6 ranges.
    byoipv6cidrDetails VcnByoipv6cidrDetail[]
    The list of BYOIPv6 OCIDs and BYOIPv6 prefixes required to create a VCN that uses BYOIPv6 address ranges.
    cidrBlock string
    Deprecated. Do not set this value. Use cidr_blocks instead. Example: 10.0.0.0/16
    cidrBlocks string[]
    (Updatable) The list of one or more IPv4 CIDR blocks for the VCN that meet the following criteria:

    • The CIDR blocks must be valid.
    • They must not overlap with each other or with the on-premises network CIDR block.
    • The number of CIDR blocks must not exceed the limit of CIDR blocks allowed per VCN. It is an error to set both cidr_block and cidr_blocks. Note: cidr_blocks update must be restricted to one operation at a time (either add/remove or modify one single cidr_block) or the operation will be declined. new cidr_block to be added must be placed at the end of the list. Once you migrate to using cidr_blocks from cidr_block, you will not be able to switch back. Important: Do not specify a value for cidr_block. Use this parameter instead.
    compartmentId string
    (Updatable) The OCID of the compartment to contain the VCN.
    defaultDhcpOptionsId string
    The OCID for the VCN's default set of DHCP options.
    defaultRouteTableId string
    The OCID for the VCN's default route table.
    defaultSecurityListId string
    The OCID for the VCN's default security list.
    definedTags {[key: string]: any}
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    displayName string
    (Updatable) A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
    dnsLabel string

    A DNS label for the VCN, used in conjunction with the VNIC's hostname and subnet's DNS label to form a fully qualified domain name (FQDN) for each VNIC within this subnet (for example, bminstance1.subnet123.vcn1.oraclevcn.com). Not required to be unique, but it's a best practice to set unique DNS labels for VCNs in your tenancy. Must be an alphanumeric string that begins with a letter. The value cannot be changed. You must set this value if you want instances to be able to use hostnames to resolve other instances in the VCN. Otherwise the Internet and VCN Resolver will not work.

    For more information, see DNS in Your Virtual Cloud Network.

    Example: vcn1

    freeformTags {[key: string]: any}
    (Updatable) Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
    ipv6cidrBlocks string[]
    For an IPv6-enabled VCN, this is the list of IPv6 prefixes for the VCN's IP address space. The prefixes are provided by Oracle and the sizes are always /56.
    ipv6privateCidrBlocks string[]

    The list of one or more ULA or Private IPv6 CIDR blocks for the vcn that meets the following criteria:

    • The CIDR blocks must be valid.
    • Multiple CIDR blocks must not overlap each other or the on-premises network prefix.
    • The number of CIDR blocks must not exceed the limit of IPv6 prefixes allowed to a VCN.

    Important: Do not specify a value for ipv6cidr_block. Use this parameter instead.

    isIpv6enabled boolean
    Whether IPv6 is enabled for the VCN. Default is false. If enabled, Oracle will assign the VCN a IPv6 /56 CIDR block. You may skip having Oracle allocate the VCN a IPv6 /56 CIDR block by setting isOracleGuaAllocationEnabled to false. For important details about IPv6 addressing in a VCN, see IPv6 Addresses. Example: true
    isOracleGuaAllocationEnabled boolean

    Specifies whether to skip Oracle allocated IPv6 GUA. By default, Oracle will allocate one GUA of /56 size for an IPv6 enabled VCN.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    state string
    The VCN's current state.
    timeCreated string
    The date and time the VCN was created, in the format defined by RFC3339. Example: 2016-08-25T21:10:29.600Z
    vcnDomainName string
    The VCN's domain name, which consists of the VCN's DNS label, and the oraclevcn.com domain.
    byoipv6cidr_blocks Sequence[str]
    The list of BYOIPv6 prefixes required to create a VCN that uses BYOIPv6 ranges.
    byoipv6cidr_details Sequence[core.VcnByoipv6cidrDetailArgs]
    The list of BYOIPv6 OCIDs and BYOIPv6 prefixes required to create a VCN that uses BYOIPv6 address ranges.
    cidr_block str
    Deprecated. Do not set this value. Use cidr_blocks instead. Example: 10.0.0.0/16
    cidr_blocks Sequence[str]
    (Updatable) The list of one or more IPv4 CIDR blocks for the VCN that meet the following criteria:

    • The CIDR blocks must be valid.
    • They must not overlap with each other or with the on-premises network CIDR block.
    • The number of CIDR blocks must not exceed the limit of CIDR blocks allowed per VCN. It is an error to set both cidr_block and cidr_blocks. Note: cidr_blocks update must be restricted to one operation at a time (either add/remove or modify one single cidr_block) or the operation will be declined. new cidr_block to be added must be placed at the end of the list. Once you migrate to using cidr_blocks from cidr_block, you will not be able to switch back. Important: Do not specify a value for cidr_block. Use this parameter instead.
    compartment_id str
    (Updatable) The OCID of the compartment to contain the VCN.
    default_dhcp_options_id str
    The OCID for the VCN's default set of DHCP options.
    default_route_table_id str
    The OCID for the VCN's default route table.
    default_security_list_id str
    The OCID for the VCN's default security list.
    defined_tags Mapping[str, Any]
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    display_name str
    (Updatable) A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
    dns_label str

    A DNS label for the VCN, used in conjunction with the VNIC's hostname and subnet's DNS label to form a fully qualified domain name (FQDN) for each VNIC within this subnet (for example, bminstance1.subnet123.vcn1.oraclevcn.com). Not required to be unique, but it's a best practice to set unique DNS labels for VCNs in your tenancy. Must be an alphanumeric string that begins with a letter. The value cannot be changed. You must set this value if you want instances to be able to use hostnames to resolve other instances in the VCN. Otherwise the Internet and VCN Resolver will not work.

    For more information, see DNS in Your Virtual Cloud Network.

    Example: vcn1

    freeform_tags Mapping[str, Any]
    (Updatable) Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
    ipv6cidr_blocks Sequence[str]
    For an IPv6-enabled VCN, this is the list of IPv6 prefixes for the VCN's IP address space. The prefixes are provided by Oracle and the sizes are always /56.
    ipv6private_cidr_blocks Sequence[str]

    The list of one or more ULA or Private IPv6 CIDR blocks for the vcn that meets the following criteria:

    • The CIDR blocks must be valid.
    • Multiple CIDR blocks must not overlap each other or the on-premises network prefix.
    • The number of CIDR blocks must not exceed the limit of IPv6 prefixes allowed to a VCN.

    Important: Do not specify a value for ipv6cidr_block. Use this parameter instead.

    is_ipv6enabled bool
    Whether IPv6 is enabled for the VCN. Default is false. If enabled, Oracle will assign the VCN a IPv6 /56 CIDR block. You may skip having Oracle allocate the VCN a IPv6 /56 CIDR block by setting isOracleGuaAllocationEnabled to false. For important details about IPv6 addressing in a VCN, see IPv6 Addresses. Example: true
    is_oracle_gua_allocation_enabled bool

    Specifies whether to skip Oracle allocated IPv6 GUA. By default, Oracle will allocate one GUA of /56 size for an IPv6 enabled VCN.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    state str
    The VCN's current state.
    time_created str
    The date and time the VCN was created, in the format defined by RFC3339. Example: 2016-08-25T21:10:29.600Z
    vcn_domain_name str
    The VCN's domain name, which consists of the VCN's DNS label, and the oraclevcn.com domain.
    byoipv6cidrBlocks List<String>
    The list of BYOIPv6 prefixes required to create a VCN that uses BYOIPv6 ranges.
    byoipv6cidrDetails List<Property Map>
    The list of BYOIPv6 OCIDs and BYOIPv6 prefixes required to create a VCN that uses BYOIPv6 address ranges.
    cidrBlock String
    Deprecated. Do not set this value. Use cidr_blocks instead. Example: 10.0.0.0/16
    cidrBlocks List<String>
    (Updatable) The list of one or more IPv4 CIDR blocks for the VCN that meet the following criteria:

    • The CIDR blocks must be valid.
    • They must not overlap with each other or with the on-premises network CIDR block.
    • The number of CIDR blocks must not exceed the limit of CIDR blocks allowed per VCN. It is an error to set both cidr_block and cidr_blocks. Note: cidr_blocks update must be restricted to one operation at a time (either add/remove or modify one single cidr_block) or the operation will be declined. new cidr_block to be added must be placed at the end of the list. Once you migrate to using cidr_blocks from cidr_block, you will not be able to switch back. Important: Do not specify a value for cidr_block. Use this parameter instead.
    compartmentId String
    (Updatable) The OCID of the compartment to contain the VCN.
    defaultDhcpOptionsId String
    The OCID for the VCN's default set of DHCP options.
    defaultRouteTableId String
    The OCID for the VCN's default route table.
    defaultSecurityListId String
    The OCID for the VCN's default security list.
    definedTags Map<Any>
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    displayName String
    (Updatable) A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
    dnsLabel String

    A DNS label for the VCN, used in conjunction with the VNIC's hostname and subnet's DNS label to form a fully qualified domain name (FQDN) for each VNIC within this subnet (for example, bminstance1.subnet123.vcn1.oraclevcn.com). Not required to be unique, but it's a best practice to set unique DNS labels for VCNs in your tenancy. Must be an alphanumeric string that begins with a letter. The value cannot be changed. You must set this value if you want instances to be able to use hostnames to resolve other instances in the VCN. Otherwise the Internet and VCN Resolver will not work.

    For more information, see DNS in Your Virtual Cloud Network.

    Example: vcn1

    freeformTags Map<Any>
    (Updatable) Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
    ipv6cidrBlocks List<String>
    For an IPv6-enabled VCN, this is the list of IPv6 prefixes for the VCN's IP address space. The prefixes are provided by Oracle and the sizes are always /56.
    ipv6privateCidrBlocks List<String>

    The list of one or more ULA or Private IPv6 CIDR blocks for the vcn that meets the following criteria:

    • The CIDR blocks must be valid.
    • Multiple CIDR blocks must not overlap each other or the on-premises network prefix.
    • The number of CIDR blocks must not exceed the limit of IPv6 prefixes allowed to a VCN.

    Important: Do not specify a value for ipv6cidr_block. Use this parameter instead.

    isIpv6enabled Boolean
    Whether IPv6 is enabled for the VCN. Default is false. If enabled, Oracle will assign the VCN a IPv6 /56 CIDR block. You may skip having Oracle allocate the VCN a IPv6 /56 CIDR block by setting isOracleGuaAllocationEnabled to false. For important details about IPv6 addressing in a VCN, see IPv6 Addresses. Example: true
    isOracleGuaAllocationEnabled Boolean

    Specifies whether to skip Oracle allocated IPv6 GUA. By default, Oracle will allocate one GUA of /56 size for an IPv6 enabled VCN.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    state String
    The VCN's current state.
    timeCreated String
    The date and time the VCN was created, in the format defined by RFC3339. Example: 2016-08-25T21:10:29.600Z
    vcnDomainName String
    The VCN's domain name, which consists of the VCN's DNS label, and the oraclevcn.com domain.

    Supporting Types

    VcnByoipv6cidrDetail, VcnByoipv6cidrDetailArgs

    Byoipv6rangeId string
    The OCID of the ByoipRange resource to which the CIDR block belongs.
    Ipv6cidrBlock string
    An IPv6 prefix required to create a VCN with a BYOIP prefix. It could be the whole prefix identified in byoipv6RangeId, or a subrange. Example: 2001:0db8:0123::/48
    Byoipv6rangeId string
    The OCID of the ByoipRange resource to which the CIDR block belongs.
    Ipv6cidrBlock string
    An IPv6 prefix required to create a VCN with a BYOIP prefix. It could be the whole prefix identified in byoipv6RangeId, or a subrange. Example: 2001:0db8:0123::/48
    byoipv6rangeId String
    The OCID of the ByoipRange resource to which the CIDR block belongs.
    ipv6cidrBlock String
    An IPv6 prefix required to create a VCN with a BYOIP prefix. It could be the whole prefix identified in byoipv6RangeId, or a subrange. Example: 2001:0db8:0123::/48
    byoipv6rangeId string
    The OCID of the ByoipRange resource to which the CIDR block belongs.
    ipv6cidrBlock string
    An IPv6 prefix required to create a VCN with a BYOIP prefix. It could be the whole prefix identified in byoipv6RangeId, or a subrange. Example: 2001:0db8:0123::/48
    byoipv6range_id str
    The OCID of the ByoipRange resource to which the CIDR block belongs.
    ipv6cidr_block str
    An IPv6 prefix required to create a VCN with a BYOIP prefix. It could be the whole prefix identified in byoipv6RangeId, or a subrange. Example: 2001:0db8:0123::/48
    byoipv6rangeId String
    The OCID of the ByoipRange resource to which the CIDR block belongs.
    ipv6cidrBlock String
    An IPv6 prefix required to create a VCN with a BYOIP prefix. It could be the whole prefix identified in byoipv6RangeId, or a subrange. Example: 2001:0db8:0123::/48

    Import

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

    $ pulumi import oci:Core/vcn:Vcn test_vcn "id"
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    oci pulumi/pulumi-oci
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the oci Terraform Provider.
    oci logo
    Oracle Cloud Infrastructure v1.41.0 published on Wednesday, Jun 19, 2024 by Pulumi