1. Packages
  2. Ibm Provider
  3. API Docs
  4. getDnsCustomResolvers
ibm 1.78.0 published on Wednesday, Apr 30, 2025 by ibm-cloud

ibm.getDnsCustomResolvers

Explore with Pulumi AI

ibm logo
ibm 1.78.0 published on Wednesday, Apr 30, 2025 by ibm-cloud

    Provides a read-only data source for custom resolvers. You can then reference the fields of the data source in other resources within the same configuration using interpolation syntax. For more information about custom resolver, see List custom resolvers.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as ibm from "@pulumi/ibm";
    
    const test_cr = ibm.getDnsCustomResolvers({
        instanceId: ibm_dns_custom_resolver.test.instance_id,
    });
    
    import pulumi
    import pulumi_ibm as ibm
    
    test_cr = ibm.get_dns_custom_resolvers(instance_id=ibm_dns_custom_resolver["test"]["instance_id"])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/ibm/ibm"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := ibm.GetDnsCustomResolvers(ctx, &ibm.GetDnsCustomResolversArgs{
    			InstanceId: ibm_dns_custom_resolver.Test.Instance_id,
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Ibm = Pulumi.Ibm;
    
    return await Deployment.RunAsync(() => 
    {
        var test_cr = Ibm.GetDnsCustomResolvers.Invoke(new()
        {
            InstanceId = ibm_dns_custom_resolver.Test.Instance_id,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.ibm.IbmFunctions;
    import com.pulumi.ibm.inputs.GetDnsCustomResolversArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            final var test-cr = IbmFunctions.getDnsCustomResolvers(GetDnsCustomResolversArgs.builder()
                .instanceId(ibm_dns_custom_resolver.test().instance_id())
                .build());
    
        }
    }
    
    variables:
      test-cr:
        fn::invoke:
          function: ibm:getDnsCustomResolvers
          arguments:
            instanceId: ${ibm_dns_custom_resolver.test.instance_id}
    

    Using getDnsCustomResolvers

    Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

    function getDnsCustomResolvers(args: GetDnsCustomResolversArgs, opts?: InvokeOptions): Promise<GetDnsCustomResolversResult>
    function getDnsCustomResolversOutput(args: GetDnsCustomResolversOutputArgs, opts?: InvokeOptions): Output<GetDnsCustomResolversResult>
    def get_dns_custom_resolvers(id: Optional[str] = None,
                                 instance_id: Optional[str] = None,
                                 opts: Optional[InvokeOptions] = None) -> GetDnsCustomResolversResult
    def get_dns_custom_resolvers_output(id: Optional[pulumi.Input[str]] = None,
                                 instance_id: Optional[pulumi.Input[str]] = None,
                                 opts: Optional[InvokeOptions] = None) -> Output[GetDnsCustomResolversResult]
    func GetDnsCustomResolvers(ctx *Context, args *GetDnsCustomResolversArgs, opts ...InvokeOption) (*GetDnsCustomResolversResult, error)
    func GetDnsCustomResolversOutput(ctx *Context, args *GetDnsCustomResolversOutputArgs, opts ...InvokeOption) GetDnsCustomResolversResultOutput

    > Note: This function is named GetDnsCustomResolvers in the Go SDK.

    public static class GetDnsCustomResolvers 
    {
        public static Task<GetDnsCustomResolversResult> InvokeAsync(GetDnsCustomResolversArgs args, InvokeOptions? opts = null)
        public static Output<GetDnsCustomResolversResult> Invoke(GetDnsCustomResolversInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetDnsCustomResolversResult> getDnsCustomResolvers(GetDnsCustomResolversArgs args, InvokeOptions options)
    public static Output<GetDnsCustomResolversResult> getDnsCustomResolvers(GetDnsCustomResolversArgs args, InvokeOptions options)
    
    fn::invoke:
      function: ibm:index/getDnsCustomResolvers:getDnsCustomResolvers
      arguments:
        # arguments dictionary

    The following arguments are supported:

    InstanceId string
    The GUID of the private DNS service instance.
    Id string
    InstanceId string
    The GUID of the private DNS service instance.
    Id string
    instanceId String
    The GUID of the private DNS service instance.
    id String
    instanceId string
    The GUID of the private DNS service instance.
    id string
    instance_id str
    The GUID of the private DNS service instance.
    id str
    instanceId String
    The GUID of the private DNS service instance.
    id String

    getDnsCustomResolvers Result

    The following output properties are available:

    CustomResolvers List<GetDnsCustomResolversCustomResolver>
    (List) List of all private DNS custom resolvers.
    Id string
    InstanceId string
    CustomResolvers []GetDnsCustomResolversCustomResolver
    (List) List of all private DNS custom resolvers.
    Id string
    InstanceId string
    customResolvers List<GetDnsCustomResolversCustomResolver>
    (List) List of all private DNS custom resolvers.
    id String
    instanceId String
    customResolvers GetDnsCustomResolversCustomResolver[]
    (List) List of all private DNS custom resolvers.
    id string
    instanceId string
    custom_resolvers Sequence[GetDnsCustomResolversCustomResolver]
    (List) List of all private DNS custom resolvers.
    id str
    instance_id str
    customResolvers List<Property Map>
    (List) List of all private DNS custom resolvers.
    id String
    instanceId String

    Supporting Types

    GetDnsCustomResolversCustomResolver

    AllowDisruptiveUpdates bool
    (Boolean) Whether a disruptive update is allowed for the custom resolver.
    CustomResolverId string
    (String) Identifier of the custom resolver.
    Description string
    (String) Descriptive text of the custom resolver.
    Enabled bool
    (String) Whether the location is enabled or disabled.
    Health string
    (String) The status of DNS custom resolver's health. Supported values are CRITICAL, DEGRADED, HEALTHY.
    Locations List<GetDnsCustomResolversCustomResolverLocation>
    (List) The list of locations within the custom resolver.
    Name string
    (String) Name of the custom resolver.
    Profile string
    (String) The profile name of the custom resolver. Supported values are ESSENTIAL, ADVANCED, PREMIER.
    AllowDisruptiveUpdates bool
    (Boolean) Whether a disruptive update is allowed for the custom resolver.
    CustomResolverId string
    (String) Identifier of the custom resolver.
    Description string
    (String) Descriptive text of the custom resolver.
    Enabled bool
    (String) Whether the location is enabled or disabled.
    Health string
    (String) The status of DNS custom resolver's health. Supported values are CRITICAL, DEGRADED, HEALTHY.
    Locations []GetDnsCustomResolversCustomResolverLocation
    (List) The list of locations within the custom resolver.
    Name string
    (String) Name of the custom resolver.
    Profile string
    (String) The profile name of the custom resolver. Supported values are ESSENTIAL, ADVANCED, PREMIER.
    allowDisruptiveUpdates Boolean
    (Boolean) Whether a disruptive update is allowed for the custom resolver.
    customResolverId String
    (String) Identifier of the custom resolver.
    description String
    (String) Descriptive text of the custom resolver.
    enabled Boolean
    (String) Whether the location is enabled or disabled.
    health String
    (String) The status of DNS custom resolver's health. Supported values are CRITICAL, DEGRADED, HEALTHY.
    locations List<GetDnsCustomResolversCustomResolverLocation>
    (List) The list of locations within the custom resolver.
    name String
    (String) Name of the custom resolver.
    profile String
    (String) The profile name of the custom resolver. Supported values are ESSENTIAL, ADVANCED, PREMIER.
    allowDisruptiveUpdates boolean
    (Boolean) Whether a disruptive update is allowed for the custom resolver.
    customResolverId string
    (String) Identifier of the custom resolver.
    description string
    (String) Descriptive text of the custom resolver.
    enabled boolean
    (String) Whether the location is enabled or disabled.
    health string
    (String) The status of DNS custom resolver's health. Supported values are CRITICAL, DEGRADED, HEALTHY.
    locations GetDnsCustomResolversCustomResolverLocation[]
    (List) The list of locations within the custom resolver.
    name string
    (String) Name of the custom resolver.
    profile string
    (String) The profile name of the custom resolver. Supported values are ESSENTIAL, ADVANCED, PREMIER.
    allow_disruptive_updates bool
    (Boolean) Whether a disruptive update is allowed for the custom resolver.
    custom_resolver_id str
    (String) Identifier of the custom resolver.
    description str
    (String) Descriptive text of the custom resolver.
    enabled bool
    (String) Whether the location is enabled or disabled.
    health str
    (String) The status of DNS custom resolver's health. Supported values are CRITICAL, DEGRADED, HEALTHY.
    locations Sequence[GetDnsCustomResolversCustomResolverLocation]
    (List) The list of locations within the custom resolver.
    name str
    (String) Name of the custom resolver.
    profile str
    (String) The profile name of the custom resolver. Supported values are ESSENTIAL, ADVANCED, PREMIER.
    allowDisruptiveUpdates Boolean
    (Boolean) Whether a disruptive update is allowed for the custom resolver.
    customResolverId String
    (String) Identifier of the custom resolver.
    description String
    (String) Descriptive text of the custom resolver.
    enabled Boolean
    (String) Whether the location is enabled or disabled.
    health String
    (String) The status of DNS custom resolver's health. Supported values are CRITICAL, DEGRADED, HEALTHY.
    locations List<Property Map>
    (List) The list of locations within the custom resolver.
    name String
    (String) Name of the custom resolver.
    profile String
    (String) The profile name of the custom resolver. Supported values are ESSENTIAL, ADVANCED, PREMIER.

    GetDnsCustomResolversCustomResolverLocation

    DnsServerIp string
    (String) The DNS server IP.
    Enabled bool
    (String) Whether the location is enabled or disabled.
    Healthy bool
    (String) The health status.
    LocationId string
    (String) The location ID.
    SubnetCrn string
    (String) The subnet CRN.
    DnsServerIp string
    (String) The DNS server IP.
    Enabled bool
    (String) Whether the location is enabled or disabled.
    Healthy bool
    (String) The health status.
    LocationId string
    (String) The location ID.
    SubnetCrn string
    (String) The subnet CRN.
    dnsServerIp String
    (String) The DNS server IP.
    enabled Boolean
    (String) Whether the location is enabled or disabled.
    healthy Boolean
    (String) The health status.
    locationId String
    (String) The location ID.
    subnetCrn String
    (String) The subnet CRN.
    dnsServerIp string
    (String) The DNS server IP.
    enabled boolean
    (String) Whether the location is enabled or disabled.
    healthy boolean
    (String) The health status.
    locationId string
    (String) The location ID.
    subnetCrn string
    (String) The subnet CRN.
    dns_server_ip str
    (String) The DNS server IP.
    enabled bool
    (String) Whether the location is enabled or disabled.
    healthy bool
    (String) The health status.
    location_id str
    (String) The location ID.
    subnet_crn str
    (String) The subnet CRN.
    dnsServerIp String
    (String) The DNS server IP.
    enabled Boolean
    (String) Whether the location is enabled or disabled.
    healthy Boolean
    (String) The health status.
    locationId String
    (String) The location ID.
    subnetCrn String
    (String) The subnet CRN.

    Package Details

    Repository
    ibm ibm-cloud/terraform-provider-ibm
    License
    Notes
    This Pulumi package is based on the ibm Terraform Provider.
    ibm logo
    ibm 1.78.0 published on Wednesday, Apr 30, 2025 by ibm-cloud