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

oci.Dns.View

Explore with Pulumi AI

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

    This resource provides the View resource in Oracle Cloud Infrastructure DNS service.

    Creates a new view in the specified compartment.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as oci from "@pulumi/oci";
    
    const testView = new oci.dns.View("test_view", {
        compartmentId: compartmentId,
        scope: "PRIVATE",
        definedTags: viewDefinedTags,
        displayName: viewDisplayName,
        freeformTags: viewFreeformTags,
    });
    
    import pulumi
    import pulumi_oci as oci
    
    test_view = oci.dns.View("test_view",
        compartment_id=compartment_id,
        scope="PRIVATE",
        defined_tags=view_defined_tags,
        display_name=view_display_name,
        freeform_tags=view_freeform_tags)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-oci/sdk/go/oci/Dns"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := Dns.NewView(ctx, "test_view", &Dns.ViewArgs{
    			CompartmentId: pulumi.Any(compartmentId),
    			Scope:         pulumi.String("PRIVATE"),
    			DefinedTags:   pulumi.Any(viewDefinedTags),
    			DisplayName:   pulumi.Any(viewDisplayName),
    			FreeformTags:  pulumi.Any(viewFreeformTags),
    		})
    		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 testView = new Oci.Dns.View("test_view", new()
        {
            CompartmentId = compartmentId,
            Scope = "PRIVATE",
            DefinedTags = viewDefinedTags,
            DisplayName = viewDisplayName,
            FreeformTags = viewFreeformTags,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.oci.Dns.View;
    import com.pulumi.oci.Dns.ViewArgs;
    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 testView = new View("testView", ViewArgs.builder()
                .compartmentId(compartmentId)
                .scope("PRIVATE")
                .definedTags(viewDefinedTags)
                .displayName(viewDisplayName)
                .freeformTags(viewFreeformTags)
                .build());
    
        }
    }
    
    resources:
      testView:
        type: oci:Dns:View
        name: test_view
        properties:
          compartmentId: ${compartmentId}
          scope: PRIVATE
          definedTags: ${viewDefinedTags}
          displayName: ${viewDisplayName}
          freeformTags: ${viewFreeformTags}
    

    Create View Resource

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

    Constructor syntax

    new View(name: string, args: ViewArgs, opts?: CustomResourceOptions);
    @overload
    def View(resource_name: str,
             args: ViewArgs,
             opts: Optional[ResourceOptions] = None)
    
    @overload
    def View(resource_name: str,
             opts: Optional[ResourceOptions] = None,
             compartment_id: Optional[str] = None,
             defined_tags: Optional[Mapping[str, Any]] = None,
             display_name: Optional[str] = None,
             freeform_tags: Optional[Mapping[str, Any]] = None,
             scope: Optional[str] = None)
    func NewView(ctx *Context, name string, args ViewArgs, opts ...ResourceOption) (*View, error)
    public View(string name, ViewArgs args, CustomResourceOptions? opts = null)
    public View(String name, ViewArgs args)
    public View(String name, ViewArgs args, CustomResourceOptions options)
    
    type: oci:Dns:View
    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 ViewArgs
    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 ViewArgs
    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 ViewArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args ViewArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args ViewArgs
    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 viewResource = new Oci.Dns.View("viewResource", new()
    {
        CompartmentId = "string",
        DefinedTags = 
        {
            { "string", "any" },
        },
        DisplayName = "string",
        FreeformTags = 
        {
            { "string", "any" },
        },
        Scope = "string",
    });
    
    example, err := Dns.NewView(ctx, "viewResource", &Dns.ViewArgs{
    	CompartmentId: pulumi.String("string"),
    	DefinedTags: pulumi.Map{
    		"string": pulumi.Any("any"),
    	},
    	DisplayName: pulumi.String("string"),
    	FreeformTags: pulumi.Map{
    		"string": pulumi.Any("any"),
    	},
    	Scope: pulumi.String("string"),
    })
    
    var viewResource = new View("viewResource", ViewArgs.builder()
        .compartmentId("string")
        .definedTags(Map.of("string", "any"))
        .displayName("string")
        .freeformTags(Map.of("string", "any"))
        .scope("string")
        .build());
    
    view_resource = oci.dns.View("viewResource",
        compartment_id="string",
        defined_tags={
            "string": "any",
        },
        display_name="string",
        freeform_tags={
            "string": "any",
        },
        scope="string")
    
    const viewResource = new oci.dns.View("viewResource", {
        compartmentId: "string",
        definedTags: {
            string: "any",
        },
        displayName: "string",
        freeformTags: {
            string: "any",
        },
        scope: "string",
    });
    
    type: oci:Dns:View
    properties:
        compartmentId: string
        definedTags:
            string: any
        displayName: string
        freeformTags:
            string: any
        scope: string
    

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

    CompartmentId string
    (Updatable) The OCID of the owning compartment.
    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) The display name of the view.
    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"}

    Scope string

    If specified, must be PRIVATE when creating a view for private zones.

    ** 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 owning compartment.
    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) The display name of the view.
    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"}

    Scope string

    If specified, must be PRIVATE when creating a view for private zones.

    ** 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 owning compartment.
    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) The display name of the view.
    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"}

    scope String

    If specified, must be PRIVATE when creating a view for private zones.

    ** 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 owning compartment.
    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) The display name of the view.
    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"}

    scope string

    If specified, must be PRIVATE when creating a view for private zones.

    ** 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 owning compartment.
    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) The display name of the view.
    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"}

    scope str

    If specified, must be PRIVATE when creating a view for private zones.

    ** 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 owning compartment.
    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) The display name of the view.
    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"}

    scope String

    If specified, must be PRIVATE when creating a view for private zones.

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

    Id string
    The provider-assigned unique ID for this managed resource.
    IsProtected bool
    A Boolean flag indicating whether or not parts of the resource are unable to be explicitly managed.
    Self string
    The canonical absolute URL of the resource.
    State string
    The current state of the resource.
    TimeCreated string
    The date and time the resource was created in "YYYY-MM-ddThh:mm:ssZ" format with a Z offset, as defined by RFC 3339.
    TimeUpdated string
    The date and time the resource was last updated in "YYYY-MM-ddThh:mm:ssZ" format with a Z offset, as defined by RFC 3339.
    Id string
    The provider-assigned unique ID for this managed resource.
    IsProtected bool
    A Boolean flag indicating whether or not parts of the resource are unable to be explicitly managed.
    Self string
    The canonical absolute URL of the resource.
    State string
    The current state of the resource.
    TimeCreated string
    The date and time the resource was created in "YYYY-MM-ddThh:mm:ssZ" format with a Z offset, as defined by RFC 3339.
    TimeUpdated string
    The date and time the resource was last updated in "YYYY-MM-ddThh:mm:ssZ" format with a Z offset, as defined by RFC 3339.
    id String
    The provider-assigned unique ID for this managed resource.
    isProtected Boolean
    A Boolean flag indicating whether or not parts of the resource are unable to be explicitly managed.
    self String
    The canonical absolute URL of the resource.
    state String
    The current state of the resource.
    timeCreated String
    The date and time the resource was created in "YYYY-MM-ddThh:mm:ssZ" format with a Z offset, as defined by RFC 3339.
    timeUpdated String
    The date and time the resource was last updated in "YYYY-MM-ddThh:mm:ssZ" format with a Z offset, as defined by RFC 3339.
    id string
    The provider-assigned unique ID for this managed resource.
    isProtected boolean
    A Boolean flag indicating whether or not parts of the resource are unable to be explicitly managed.
    self string
    The canonical absolute URL of the resource.
    state string
    The current state of the resource.
    timeCreated string
    The date and time the resource was created in "YYYY-MM-ddThh:mm:ssZ" format with a Z offset, as defined by RFC 3339.
    timeUpdated string
    The date and time the resource was last updated in "YYYY-MM-ddThh:mm:ssZ" format with a Z offset, as defined by RFC 3339.
    id str
    The provider-assigned unique ID for this managed resource.
    is_protected bool
    A Boolean flag indicating whether or not parts of the resource are unable to be explicitly managed.
    self str
    The canonical absolute URL of the resource.
    state str
    The current state of the resource.
    time_created str
    The date and time the resource was created in "YYYY-MM-ddThh:mm:ssZ" format with a Z offset, as defined by RFC 3339.
    time_updated str
    The date and time the resource was last updated in "YYYY-MM-ddThh:mm:ssZ" format with a Z offset, as defined by RFC 3339.
    id String
    The provider-assigned unique ID for this managed resource.
    isProtected Boolean
    A Boolean flag indicating whether or not parts of the resource are unable to be explicitly managed.
    self String
    The canonical absolute URL of the resource.
    state String
    The current state of the resource.
    timeCreated String
    The date and time the resource was created in "YYYY-MM-ddThh:mm:ssZ" format with a Z offset, as defined by RFC 3339.
    timeUpdated String
    The date and time the resource was last updated in "YYYY-MM-ddThh:mm:ssZ" format with a Z offset, as defined by RFC 3339.

    Look up Existing View Resource

    Get an existing View 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?: ViewState, opts?: CustomResourceOptions): View
    @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,
            freeform_tags: Optional[Mapping[str, Any]] = None,
            is_protected: Optional[bool] = None,
            scope: Optional[str] = None,
            self: Optional[str] = None,
            state: Optional[str] = None,
            time_created: Optional[str] = None,
            time_updated: Optional[str] = None) -> View
    func GetView(ctx *Context, name string, id IDInput, state *ViewState, opts ...ResourceOption) (*View, error)
    public static View Get(string name, Input<string> id, ViewState? state, CustomResourceOptions? opts = null)
    public static View get(String name, Output<String> id, ViewState 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
    (Updatable) The OCID of the owning compartment.
    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) The display name of the view.
    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"}

    IsProtected bool
    A Boolean flag indicating whether or not parts of the resource are unable to be explicitly managed.
    Scope string

    If specified, must be PRIVATE when creating a view for private zones.

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

    Self string
    The canonical absolute URL of the resource.
    State string
    The current state of the resource.
    TimeCreated string
    The date and time the resource was created in "YYYY-MM-ddThh:mm:ssZ" format with a Z offset, as defined by RFC 3339.
    TimeUpdated string
    The date and time the resource was last updated in "YYYY-MM-ddThh:mm:ssZ" format with a Z offset, as defined by RFC 3339.
    CompartmentId string
    (Updatable) The OCID of the owning compartment.
    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) The display name of the view.
    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"}

    IsProtected bool
    A Boolean flag indicating whether or not parts of the resource are unable to be explicitly managed.
    Scope string

    If specified, must be PRIVATE when creating a view for private zones.

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

    Self string
    The canonical absolute URL of the resource.
    State string
    The current state of the resource.
    TimeCreated string
    The date and time the resource was created in "YYYY-MM-ddThh:mm:ssZ" format with a Z offset, as defined by RFC 3339.
    TimeUpdated string
    The date and time the resource was last updated in "YYYY-MM-ddThh:mm:ssZ" format with a Z offset, as defined by RFC 3339.
    compartmentId String
    (Updatable) The OCID of the owning compartment.
    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) The display name of the view.
    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"}

    isProtected Boolean
    A Boolean flag indicating whether or not parts of the resource are unable to be explicitly managed.
    scope String

    If specified, must be PRIVATE when creating a view for private zones.

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

    self String
    The canonical absolute URL of the resource.
    state String
    The current state of the resource.
    timeCreated String
    The date and time the resource was created in "YYYY-MM-ddThh:mm:ssZ" format with a Z offset, as defined by RFC 3339.
    timeUpdated String
    The date and time the resource was last updated in "YYYY-MM-ddThh:mm:ssZ" format with a Z offset, as defined by RFC 3339.
    compartmentId string
    (Updatable) The OCID of the owning compartment.
    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) The display name of the view.
    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"}

    isProtected boolean
    A Boolean flag indicating whether or not parts of the resource are unable to be explicitly managed.
    scope string

    If specified, must be PRIVATE when creating a view for private zones.

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

    self string
    The canonical absolute URL of the resource.
    state string
    The current state of the resource.
    timeCreated string
    The date and time the resource was created in "YYYY-MM-ddThh:mm:ssZ" format with a Z offset, as defined by RFC 3339.
    timeUpdated string
    The date and time the resource was last updated in "YYYY-MM-ddThh:mm:ssZ" format with a Z offset, as defined by RFC 3339.
    compartment_id str
    (Updatable) The OCID of the owning compartment.
    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) The display name of the view.
    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"}

    is_protected bool
    A Boolean flag indicating whether or not parts of the resource are unable to be explicitly managed.
    scope str

    If specified, must be PRIVATE when creating a view for private zones.

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

    self str
    The canonical absolute URL of the resource.
    state str
    The current state of the resource.
    time_created str
    The date and time the resource was created in "YYYY-MM-ddThh:mm:ssZ" format with a Z offset, as defined by RFC 3339.
    time_updated str
    The date and time the resource was last updated in "YYYY-MM-ddThh:mm:ssZ" format with a Z offset, as defined by RFC 3339.
    compartmentId String
    (Updatable) The OCID of the owning compartment.
    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) The display name of the view.
    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"}

    isProtected Boolean
    A Boolean flag indicating whether or not parts of the resource are unable to be explicitly managed.
    scope String

    If specified, must be PRIVATE when creating a view for private zones.

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

    self String
    The canonical absolute URL of the resource.
    state String
    The current state of the resource.
    timeCreated String
    The date and time the resource was created in "YYYY-MM-ddThh:mm:ssZ" format with a Z offset, as defined by RFC 3339.
    timeUpdated String
    The date and time the resource was last updated in "YYYY-MM-ddThh:mm:ssZ" format with a Z offset, as defined by RFC 3339.

    Import

    Views can be imported using their OCID, e.g.

    $ pulumi import oci:Dns/view:View test_view "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