1. Packages
  2. Oracle Cloud Infrastructure
  3. API Docs
  4. Core
  5. DrgRouteDistribution
Oracle Cloud Infrastructure v1.40.0 published on Wednesday, Jun 12, 2024 by Pulumi

oci.Core.DrgRouteDistribution

Explore with Pulumi AI

oci logo
Oracle Cloud Infrastructure v1.40.0 published on Wednesday, Jun 12, 2024 by Pulumi

    This resource provides the Drg Route Distribution resource in Oracle Cloud Infrastructure Core service.

    Creates a new route distribution for the specified DRG. Assign the route distribution as an import distribution to a DRG route table using the UpdateDrgRouteTable or CreateDrgRouteTable operations. Assign the route distribution as an export distribution to a DRG attachment using the UpdateDrgAttachment or CreateDrgAttachment operations.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as oci from "@pulumi/oci";
    
    const testDrgRouteDistribution = new oci.core.DrgRouteDistribution("test_drg_route_distribution", {
        distributionType: drgRouteDistributionDistributionType,
        drgId: testDrg.id,
        definedTags: {
            "Operations.CostCenter": "42",
        },
        displayName: drgRouteDistributionDisplayName,
        freeformTags: {
            Department: "Finance",
        },
    });
    
    import pulumi
    import pulumi_oci as oci
    
    test_drg_route_distribution = oci.core.DrgRouteDistribution("test_drg_route_distribution",
        distribution_type=drg_route_distribution_distribution_type,
        drg_id=test_drg["id"],
        defined_tags={
            "Operations.CostCenter": "42",
        },
        display_name=drg_route_distribution_display_name,
        freeform_tags={
            "Department": "Finance",
        })
    
    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.NewDrgRouteDistribution(ctx, "test_drg_route_distribution", &Core.DrgRouteDistributionArgs{
    			DistributionType: pulumi.Any(drgRouteDistributionDistributionType),
    			DrgId:            pulumi.Any(testDrg.Id),
    			DefinedTags: pulumi.Map{
    				"Operations.CostCenter": pulumi.Any("42"),
    			},
    			DisplayName: pulumi.Any(drgRouteDistributionDisplayName),
    			FreeformTags: pulumi.Map{
    				"Department": pulumi.Any("Finance"),
    			},
    		})
    		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 testDrgRouteDistribution = new Oci.Core.DrgRouteDistribution("test_drg_route_distribution", new()
        {
            DistributionType = drgRouteDistributionDistributionType,
            DrgId = testDrg.Id,
            DefinedTags = 
            {
                { "Operations.CostCenter", "42" },
            },
            DisplayName = drgRouteDistributionDisplayName,
            FreeformTags = 
            {
                { "Department", "Finance" },
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.oci.Core.DrgRouteDistribution;
    import com.pulumi.oci.Core.DrgRouteDistributionArgs;
    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 testDrgRouteDistribution = new DrgRouteDistribution("testDrgRouteDistribution", DrgRouteDistributionArgs.builder()
                .distributionType(drgRouteDistributionDistributionType)
                .drgId(testDrg.id())
                .definedTags(Map.of("Operations.CostCenter", "42"))
                .displayName(drgRouteDistributionDisplayName)
                .freeformTags(Map.of("Department", "Finance"))
                .build());
    
        }
    }
    
    resources:
      testDrgRouteDistribution:
        type: oci:Core:DrgRouteDistribution
        name: test_drg_route_distribution
        properties:
          distributionType: ${drgRouteDistributionDistributionType}
          drgId: ${testDrg.id}
          definedTags:
            Operations.CostCenter: '42'
          displayName: ${drgRouteDistributionDisplayName}
          freeformTags:
            Department: Finance
    

    Create DrgRouteDistribution Resource

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

    Constructor syntax

    new DrgRouteDistribution(name: string, args: DrgRouteDistributionArgs, opts?: CustomResourceOptions);
    @overload
    def DrgRouteDistribution(resource_name: str,
                             args: DrgRouteDistributionArgs,
                             opts: Optional[ResourceOptions] = None)
    
    @overload
    def DrgRouteDistribution(resource_name: str,
                             opts: Optional[ResourceOptions] = None,
                             distribution_type: Optional[str] = None,
                             drg_id: Optional[str] = None,
                             defined_tags: Optional[Mapping[str, Any]] = None,
                             display_name: Optional[str] = None,
                             freeform_tags: Optional[Mapping[str, Any]] = None)
    func NewDrgRouteDistribution(ctx *Context, name string, args DrgRouteDistributionArgs, opts ...ResourceOption) (*DrgRouteDistribution, error)
    public DrgRouteDistribution(string name, DrgRouteDistributionArgs args, CustomResourceOptions? opts = null)
    public DrgRouteDistribution(String name, DrgRouteDistributionArgs args)
    public DrgRouteDistribution(String name, DrgRouteDistributionArgs args, CustomResourceOptions options)
    
    type: oci:Core:DrgRouteDistribution
    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 DrgRouteDistributionArgs
    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 DrgRouteDistributionArgs
    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 DrgRouteDistributionArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args DrgRouteDistributionArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args DrgRouteDistributionArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Example

    The following reference example uses placeholder values for all input properties.

    var drgRouteDistributionResource = new Oci.Core.DrgRouteDistribution("drgRouteDistributionResource", new()
    {
        DistributionType = "string",
        DrgId = "string",
        DefinedTags = 
        {
            { "string", "any" },
        },
        DisplayName = "string",
        FreeformTags = 
        {
            { "string", "any" },
        },
    });
    
    example, err := Core.NewDrgRouteDistribution(ctx, "drgRouteDistributionResource", &Core.DrgRouteDistributionArgs{
    	DistributionType: pulumi.String("string"),
    	DrgId:            pulumi.String("string"),
    	DefinedTags: pulumi.Map{
    		"string": pulumi.Any("any"),
    	},
    	DisplayName: pulumi.String("string"),
    	FreeformTags: pulumi.Map{
    		"string": pulumi.Any("any"),
    	},
    })
    
    var drgRouteDistributionResource = new DrgRouteDistribution("drgRouteDistributionResource", DrgRouteDistributionArgs.builder()
        .distributionType("string")
        .drgId("string")
        .definedTags(Map.of("string", "any"))
        .displayName("string")
        .freeformTags(Map.of("string", "any"))
        .build());
    
    drg_route_distribution_resource = oci.core.DrgRouteDistribution("drgRouteDistributionResource",
        distribution_type="string",
        drg_id="string",
        defined_tags={
            "string": "any",
        },
        display_name="string",
        freeform_tags={
            "string": "any",
        })
    
    const drgRouteDistributionResource = new oci.core.DrgRouteDistribution("drgRouteDistributionResource", {
        distributionType: "string",
        drgId: "string",
        definedTags: {
            string: "any",
        },
        displayName: "string",
        freeformTags: {
            string: "any",
        },
    });
    
    type: oci:Core:DrgRouteDistribution
    properties:
        definedTags:
            string: any
        displayName: string
        distributionType: string
        drgId: string
        freeformTags:
            string: any
    

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

    DistributionType string
    Whether this distribution defines how routes get imported into route tables or exported through DRG attachments.
    DrgId string
    The OCID of the DRG the DRG route table belongs to.
    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.
    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"}

    ** 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

    DistributionType string
    Whether this distribution defines how routes get imported into route tables or exported through DRG attachments.
    DrgId string
    The OCID of the DRG the DRG route table belongs to.
    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.
    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"}

    ** 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

    distributionType String
    Whether this distribution defines how routes get imported into route tables or exported through DRG attachments.
    drgId String
    The OCID of the DRG the DRG route table belongs to.
    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.
    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"}

    ** 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

    distributionType string
    Whether this distribution defines how routes get imported into route tables or exported through DRG attachments.
    drgId string
    The OCID of the DRG the DRG route table belongs to.
    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.
    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"}

    ** 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

    distribution_type str
    Whether this distribution defines how routes get imported into route tables or exported through DRG attachments.
    drg_id str
    The OCID of the DRG the DRG route table belongs to.
    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.
    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"}

    ** 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

    distributionType String
    Whether this distribution defines how routes get imported into route tables or exported through DRG attachments.
    drgId String
    The OCID of the DRG the DRG route table belongs to.
    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.
    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"}

    ** 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 DrgRouteDistribution resource produces the following output properties:

    CompartmentId string
    The OCID of the compartment containing the route distribution.
    Id string
    The provider-assigned unique ID for this managed resource.
    State string
    The route distribution's current state.
    TimeCreated string
    The date and time the route distribution was created, in the format defined by RFC3339. Example: 2016-08-25T21:10:29.600Z
    CompartmentId string
    The OCID of the compartment containing the route distribution.
    Id string
    The provider-assigned unique ID for this managed resource.
    State string
    The route distribution's current state.
    TimeCreated string
    The date and time the route distribution was created, in the format defined by RFC3339. Example: 2016-08-25T21:10:29.600Z
    compartmentId String
    The OCID of the compartment containing the route distribution.
    id String
    The provider-assigned unique ID for this managed resource.
    state String
    The route distribution's current state.
    timeCreated String
    The date and time the route distribution was created, in the format defined by RFC3339. Example: 2016-08-25T21:10:29.600Z
    compartmentId string
    The OCID of the compartment containing the route distribution.
    id string
    The provider-assigned unique ID for this managed resource.
    state string
    The route distribution's current state.
    timeCreated string
    The date and time the route distribution was created, in the format defined by RFC3339. Example: 2016-08-25T21:10:29.600Z
    compartment_id str
    The OCID of the compartment containing the route distribution.
    id str
    The provider-assigned unique ID for this managed resource.
    state str
    The route distribution's current state.
    time_created str
    The date and time the route distribution was created, in the format defined by RFC3339. Example: 2016-08-25T21:10:29.600Z
    compartmentId String
    The OCID of the compartment containing the route distribution.
    id String
    The provider-assigned unique ID for this managed resource.
    state String
    The route distribution's current state.
    timeCreated String
    The date and time the route distribution was created, in the format defined by RFC3339. Example: 2016-08-25T21:10:29.600Z

    Look up Existing DrgRouteDistribution Resource

    Get an existing DrgRouteDistribution 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?: DrgRouteDistributionState, opts?: CustomResourceOptions): DrgRouteDistribution
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            compartment_id: Optional[str] = None,
            defined_tags: Optional[Mapping[str, Any]] = None,
            display_name: Optional[str] = None,
            distribution_type: Optional[str] = None,
            drg_id: Optional[str] = None,
            freeform_tags: Optional[Mapping[str, Any]] = None,
            state: Optional[str] = None,
            time_created: Optional[str] = None) -> DrgRouteDistribution
    func GetDrgRouteDistribution(ctx *Context, name string, id IDInput, state *DrgRouteDistributionState, opts ...ResourceOption) (*DrgRouteDistribution, error)
    public static DrgRouteDistribution Get(string name, Input<string> id, DrgRouteDistributionState? state, CustomResourceOptions? opts = null)
    public static DrgRouteDistribution get(String name, Output<String> id, DrgRouteDistributionState 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:
    CompartmentId string
    The OCID of the compartment containing the route distribution.
    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.
    DistributionType string
    Whether this distribution defines how routes get imported into route tables or exported through DRG attachments.
    DrgId string
    The OCID of the DRG the DRG route table belongs to.
    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"}

    ** 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 route distribution's current state.
    TimeCreated string
    The date and time the route distribution was created, in the format defined by RFC3339. Example: 2016-08-25T21:10:29.600Z
    CompartmentId string
    The OCID of the compartment containing the route distribution.
    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.
    DistributionType string
    Whether this distribution defines how routes get imported into route tables or exported through DRG attachments.
    DrgId string
    The OCID of the DRG the DRG route table belongs to.
    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"}

    ** 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 route distribution's current state.
    TimeCreated string
    The date and time the route distribution was created, in the format defined by RFC3339. Example: 2016-08-25T21:10:29.600Z
    compartmentId String
    The OCID of the compartment containing the route distribution.
    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.
    distributionType String
    Whether this distribution defines how routes get imported into route tables or exported through DRG attachments.
    drgId String
    The OCID of the DRG the DRG route table belongs to.
    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"}

    ** 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 route distribution's current state.
    timeCreated String
    The date and time the route distribution was created, in the format defined by RFC3339. Example: 2016-08-25T21:10:29.600Z
    compartmentId string
    The OCID of the compartment containing the route distribution.
    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.
    distributionType string
    Whether this distribution defines how routes get imported into route tables or exported through DRG attachments.
    drgId string
    The OCID of the DRG the DRG route table belongs to.
    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"}

    ** 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 route distribution's current state.
    timeCreated string
    The date and time the route distribution was created, in the format defined by RFC3339. Example: 2016-08-25T21:10:29.600Z
    compartment_id str
    The OCID of the compartment containing the route distribution.
    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.
    distribution_type str
    Whether this distribution defines how routes get imported into route tables or exported through DRG attachments.
    drg_id str
    The OCID of the DRG the DRG route table belongs to.
    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"}

    ** 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 route distribution's current state.
    time_created str
    The date and time the route distribution was created, in the format defined by RFC3339. Example: 2016-08-25T21:10:29.600Z
    compartmentId String
    The OCID of the compartment containing the route distribution.
    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.
    distributionType String
    Whether this distribution defines how routes get imported into route tables or exported through DRG attachments.
    drgId String
    The OCID of the DRG the DRG route table belongs to.
    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"}

    ** 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 route distribution's current state.
    timeCreated String
    The date and time the route distribution was created, in the format defined by RFC3339. Example: 2016-08-25T21:10:29.600Z

    Import

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

    $ pulumi import oci:Core/drgRouteDistribution:DrgRouteDistribution test_drg_route_distribution "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.40.0 published on Wednesday, Jun 12, 2024 by Pulumi