1. Packages
  2. Oracle Cloud Infrastructure
  3. API Docs
  4. Dns
  5. SteeringPolicyAttachment
Oracle Cloud Infrastructure v2.11.0 published on Thursday, Sep 19, 2024 by Pulumi

oci.Dns.SteeringPolicyAttachment

Explore with Pulumi AI

oci logo
Oracle Cloud Infrastructure v2.11.0 published on Thursday, Sep 19, 2024 by Pulumi

    This resource provides the Steering Policy Attachment resource in Oracle Cloud Infrastructure DNS service.

    Creates a new attachment between a steering policy and a domain, giving the policy permission to answer queries for the specified domain. A steering policy must be attached to a domain for the policy to answer DNS queries for that domain.

    For the purposes of access control, the attachment is automatically placed into the same compartment as the domain’s zone.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as oci from "@pulumi/oci";
    
    const testSteeringPolicyAttachment = new oci.dns.SteeringPolicyAttachment("test_steering_policy_attachment", {
        domainName: steeringPolicyAttachmentDomainName,
        steeringPolicyId: testSteeringPolicy.id,
        zoneId: testZone.id,
        displayName: steeringPolicyAttachmentDisplayName,
    });
    
    import pulumi
    import pulumi_oci as oci
    
    test_steering_policy_attachment = oci.dns.SteeringPolicyAttachment("test_steering_policy_attachment",
        domain_name=steering_policy_attachment_domain_name,
        steering_policy_id=test_steering_policy["id"],
        zone_id=test_zone["id"],
        display_name=steering_policy_attachment_display_name)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-oci/sdk/v2/go/oci/Dns"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := Dns.NewSteeringPolicyAttachment(ctx, "test_steering_policy_attachment", &Dns.SteeringPolicyAttachmentArgs{
    			DomainName:       pulumi.Any(steeringPolicyAttachmentDomainName),
    			SteeringPolicyId: pulumi.Any(testSteeringPolicy.Id),
    			ZoneId:           pulumi.Any(testZone.Id),
    			DisplayName:      pulumi.Any(steeringPolicyAttachmentDisplayName),
    		})
    		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 testSteeringPolicyAttachment = new Oci.Dns.SteeringPolicyAttachment("test_steering_policy_attachment", new()
        {
            DomainName = steeringPolicyAttachmentDomainName,
            SteeringPolicyId = testSteeringPolicy.Id,
            ZoneId = testZone.Id,
            DisplayName = steeringPolicyAttachmentDisplayName,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.oci.Dns.SteeringPolicyAttachment;
    import com.pulumi.oci.Dns.SteeringPolicyAttachmentArgs;
    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 testSteeringPolicyAttachment = new SteeringPolicyAttachment("testSteeringPolicyAttachment", SteeringPolicyAttachmentArgs.builder()
                .domainName(steeringPolicyAttachmentDomainName)
                .steeringPolicyId(testSteeringPolicy.id())
                .zoneId(testZone.id())
                .displayName(steeringPolicyAttachmentDisplayName)
                .build());
    
        }
    }
    
    resources:
      testSteeringPolicyAttachment:
        type: oci:Dns:SteeringPolicyAttachment
        name: test_steering_policy_attachment
        properties:
          domainName: ${steeringPolicyAttachmentDomainName}
          steeringPolicyId: ${testSteeringPolicy.id}
          zoneId: ${testZone.id}
          displayName: ${steeringPolicyAttachmentDisplayName}
    

    Create SteeringPolicyAttachment Resource

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

    Constructor syntax

    new SteeringPolicyAttachment(name: string, args: SteeringPolicyAttachmentArgs, opts?: CustomResourceOptions);
    @overload
    def SteeringPolicyAttachment(resource_name: str,
                                 args: SteeringPolicyAttachmentArgs,
                                 opts: Optional[ResourceOptions] = None)
    
    @overload
    def SteeringPolicyAttachment(resource_name: str,
                                 opts: Optional[ResourceOptions] = None,
                                 domain_name: Optional[str] = None,
                                 steering_policy_id: Optional[str] = None,
                                 zone_id: Optional[str] = None,
                                 display_name: Optional[str] = None)
    func NewSteeringPolicyAttachment(ctx *Context, name string, args SteeringPolicyAttachmentArgs, opts ...ResourceOption) (*SteeringPolicyAttachment, error)
    public SteeringPolicyAttachment(string name, SteeringPolicyAttachmentArgs args, CustomResourceOptions? opts = null)
    public SteeringPolicyAttachment(String name, SteeringPolicyAttachmentArgs args)
    public SteeringPolicyAttachment(String name, SteeringPolicyAttachmentArgs args, CustomResourceOptions options)
    
    type: oci:Dns:SteeringPolicyAttachment
    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 SteeringPolicyAttachmentArgs
    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 SteeringPolicyAttachmentArgs
    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 SteeringPolicyAttachmentArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args SteeringPolicyAttachmentArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args SteeringPolicyAttachmentArgs
    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 steeringPolicyAttachmentResource = new Oci.Dns.SteeringPolicyAttachment("steeringPolicyAttachmentResource", new()
    {
        DomainName = "string",
        SteeringPolicyId = "string",
        ZoneId = "string",
        DisplayName = "string",
    });
    
    example, err := Dns.NewSteeringPolicyAttachment(ctx, "steeringPolicyAttachmentResource", &Dns.SteeringPolicyAttachmentArgs{
    	DomainName:       pulumi.String("string"),
    	SteeringPolicyId: pulumi.String("string"),
    	ZoneId:           pulumi.String("string"),
    	DisplayName:      pulumi.String("string"),
    })
    
    var steeringPolicyAttachmentResource = new SteeringPolicyAttachment("steeringPolicyAttachmentResource", SteeringPolicyAttachmentArgs.builder()
        .domainName("string")
        .steeringPolicyId("string")
        .zoneId("string")
        .displayName("string")
        .build());
    
    steering_policy_attachment_resource = oci.dns.SteeringPolicyAttachment("steeringPolicyAttachmentResource",
        domain_name="string",
        steering_policy_id="string",
        zone_id="string",
        display_name="string")
    
    const steeringPolicyAttachmentResource = new oci.dns.SteeringPolicyAttachment("steeringPolicyAttachmentResource", {
        domainName: "string",
        steeringPolicyId: "string",
        zoneId: "string",
        displayName: "string",
    });
    
    type: oci:Dns:SteeringPolicyAttachment
    properties:
        displayName: string
        domainName: string
        steeringPolicyId: string
        zoneId: string
    

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

    DomainName string
    The attached domain within the attached zone. domain_name is case insensitive.
    SteeringPolicyId string
    The OCID of the attached steering policy.
    ZoneId string

    The OCID of the attached zone.

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

    DisplayName string
    (Updatable) A user-friendly name for the steering policy attachment. Does not have to be unique and can be changed. Avoid entering confidential information.
    DomainName string
    The attached domain within the attached zone. domain_name is case insensitive.
    SteeringPolicyId string
    The OCID of the attached steering policy.
    ZoneId string

    The OCID of the attached zone.

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

    DisplayName string
    (Updatable) A user-friendly name for the steering policy attachment. Does not have to be unique and can be changed. Avoid entering confidential information.
    domainName String
    The attached domain within the attached zone. domain_name is case insensitive.
    steeringPolicyId String
    The OCID of the attached steering policy.
    zoneId String

    The OCID of the attached zone.

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

    displayName String
    (Updatable) A user-friendly name for the steering policy attachment. Does not have to be unique and can be changed. Avoid entering confidential information.
    domainName string
    The attached domain within the attached zone. domain_name is case insensitive.
    steeringPolicyId string
    The OCID of the attached steering policy.
    zoneId string

    The OCID of the attached zone.

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

    displayName string
    (Updatable) A user-friendly name for the steering policy attachment. Does not have to be unique and can be changed. Avoid entering confidential information.
    domain_name str
    The attached domain within the attached zone. domain_name is case insensitive.
    steering_policy_id str
    The OCID of the attached steering policy.
    zone_id str

    The OCID of the attached zone.

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

    display_name str
    (Updatable) A user-friendly name for the steering policy attachment. Does not have to be unique and can be changed. Avoid entering confidential information.
    domainName String
    The attached domain within the attached zone. domain_name is case insensitive.
    steeringPolicyId String
    The OCID of the attached steering policy.
    zoneId String

    The OCID of the attached zone.

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

    displayName String
    (Updatable) A user-friendly name for the steering policy attachment. Does not have to be unique and can be changed. Avoid entering confidential information.

    Outputs

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

    CompartmentId string
    The OCID of the compartment containing the steering policy attachment.
    Id string
    The provider-assigned unique ID for this managed resource.
    Rtypes List<string>
    The record types covered by the attachment at the domain. The set of record types is determined by aggregating the record types from the answers defined in the steering policy.
    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, expressed in RFC 3339 timestamp format.
    CompartmentId string
    The OCID of the compartment containing the steering policy attachment.
    Id string
    The provider-assigned unique ID for this managed resource.
    Rtypes []string
    The record types covered by the attachment at the domain. The set of record types is determined by aggregating the record types from the answers defined in the steering policy.
    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, expressed in RFC 3339 timestamp format.
    compartmentId String
    The OCID of the compartment containing the steering policy attachment.
    id String
    The provider-assigned unique ID for this managed resource.
    rtypes List<String>
    The record types covered by the attachment at the domain. The set of record types is determined by aggregating the record types from the answers defined in the steering policy.
    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, expressed in RFC 3339 timestamp format.
    compartmentId string
    The OCID of the compartment containing the steering policy attachment.
    id string
    The provider-assigned unique ID for this managed resource.
    rtypes string[]
    The record types covered by the attachment at the domain. The set of record types is determined by aggregating the record types from the answers defined in the steering policy.
    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, expressed in RFC 3339 timestamp format.
    compartment_id str
    The OCID of the compartment containing the steering policy attachment.
    id str
    The provider-assigned unique ID for this managed resource.
    rtypes Sequence[str]
    The record types covered by the attachment at the domain. The set of record types is determined by aggregating the record types from the answers defined in the steering policy.
    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, expressed in RFC 3339 timestamp format.
    compartmentId String
    The OCID of the compartment containing the steering policy attachment.
    id String
    The provider-assigned unique ID for this managed resource.
    rtypes List<String>
    The record types covered by the attachment at the domain. The set of record types is determined by aggregating the record types from the answers defined in the steering policy.
    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, expressed in RFC 3339 timestamp format.

    Look up Existing SteeringPolicyAttachment Resource

    Get an existing SteeringPolicyAttachment 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?: SteeringPolicyAttachmentState, opts?: CustomResourceOptions): SteeringPolicyAttachment
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            compartment_id: Optional[str] = None,
            display_name: Optional[str] = None,
            domain_name: Optional[str] = None,
            rtypes: Optional[Sequence[str]] = None,
            self: Optional[str] = None,
            state: Optional[str] = None,
            steering_policy_id: Optional[str] = None,
            time_created: Optional[str] = None,
            zone_id: Optional[str] = None) -> SteeringPolicyAttachment
    func GetSteeringPolicyAttachment(ctx *Context, name string, id IDInput, state *SteeringPolicyAttachmentState, opts ...ResourceOption) (*SteeringPolicyAttachment, error)
    public static SteeringPolicyAttachment Get(string name, Input<string> id, SteeringPolicyAttachmentState? state, CustomResourceOptions? opts = null)
    public static SteeringPolicyAttachment get(String name, Output<String> id, SteeringPolicyAttachmentState 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 steering policy attachment.
    DisplayName string
    (Updatable) A user-friendly name for the steering policy attachment. Does not have to be unique and can be changed. Avoid entering confidential information.
    DomainName string
    The attached domain within the attached zone. domain_name is case insensitive.
    Rtypes List<string>
    The record types covered by the attachment at the domain. The set of record types is determined by aggregating the record types from the answers defined in the steering policy.
    Self string
    The canonical absolute URL of the resource.
    State string
    The current state of the resource.
    SteeringPolicyId string
    The OCID of the attached steering policy.
    TimeCreated string
    The date and time the resource was created, expressed in RFC 3339 timestamp format.
    ZoneId string

    The OCID of the attached zone.

    ** 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
    The OCID of the compartment containing the steering policy attachment.
    DisplayName string
    (Updatable) A user-friendly name for the steering policy attachment. Does not have to be unique and can be changed. Avoid entering confidential information.
    DomainName string
    The attached domain within the attached zone. domain_name is case insensitive.
    Rtypes []string
    The record types covered by the attachment at the domain. The set of record types is determined by aggregating the record types from the answers defined in the steering policy.
    Self string
    The canonical absolute URL of the resource.
    State string
    The current state of the resource.
    SteeringPolicyId string
    The OCID of the attached steering policy.
    TimeCreated string
    The date and time the resource was created, expressed in RFC 3339 timestamp format.
    ZoneId string

    The OCID of the attached zone.

    ** 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
    The OCID of the compartment containing the steering policy attachment.
    displayName String
    (Updatable) A user-friendly name for the steering policy attachment. Does not have to be unique and can be changed. Avoid entering confidential information.
    domainName String
    The attached domain within the attached zone. domain_name is case insensitive.
    rtypes List<String>
    The record types covered by the attachment at the domain. The set of record types is determined by aggregating the record types from the answers defined in the steering policy.
    self String
    The canonical absolute URL of the resource.
    state String
    The current state of the resource.
    steeringPolicyId String
    The OCID of the attached steering policy.
    timeCreated String
    The date and time the resource was created, expressed in RFC 3339 timestamp format.
    zoneId String

    The OCID of the attached zone.

    ** 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
    The OCID of the compartment containing the steering policy attachment.
    displayName string
    (Updatable) A user-friendly name for the steering policy attachment. Does not have to be unique and can be changed. Avoid entering confidential information.
    domainName string
    The attached domain within the attached zone. domain_name is case insensitive.
    rtypes string[]
    The record types covered by the attachment at the domain. The set of record types is determined by aggregating the record types from the answers defined in the steering policy.
    self string
    The canonical absolute URL of the resource.
    state string
    The current state of the resource.
    steeringPolicyId string
    The OCID of the attached steering policy.
    timeCreated string
    The date and time the resource was created, expressed in RFC 3339 timestamp format.
    zoneId string

    The OCID of the attached zone.

    ** 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
    The OCID of the compartment containing the steering policy attachment.
    display_name str
    (Updatable) A user-friendly name for the steering policy attachment. Does not have to be unique and can be changed. Avoid entering confidential information.
    domain_name str
    The attached domain within the attached zone. domain_name is case insensitive.
    rtypes Sequence[str]
    The record types covered by the attachment at the domain. The set of record types is determined by aggregating the record types from the answers defined in the steering policy.
    self str
    The canonical absolute URL of the resource.
    state str
    The current state of the resource.
    steering_policy_id str
    The OCID of the attached steering policy.
    time_created str
    The date and time the resource was created, expressed in RFC 3339 timestamp format.
    zone_id str

    The OCID of the attached zone.

    ** 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
    The OCID of the compartment containing the steering policy attachment.
    displayName String
    (Updatable) A user-friendly name for the steering policy attachment. Does not have to be unique and can be changed. Avoid entering confidential information.
    domainName String
    The attached domain within the attached zone. domain_name is case insensitive.
    rtypes List<String>
    The record types covered by the attachment at the domain. The set of record types is determined by aggregating the record types from the answers defined in the steering policy.
    self String
    The canonical absolute URL of the resource.
    state String
    The current state of the resource.
    steeringPolicyId String
    The OCID of the attached steering policy.
    timeCreated String
    The date and time the resource was created, expressed in RFC 3339 timestamp format.
    zoneId String

    The OCID of the attached zone.

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

    Import

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

    $ pulumi import oci:Dns/steeringPolicyAttachment:SteeringPolicyAttachment test_steering_policy_attachment "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 v2.11.0 published on Thursday, Sep 19, 2024 by Pulumi