1. Packages
  2. Oracle Cloud Infrastructure
  3. API Docs
  4. Dns
  5. getTsigKeys
Oracle Cloud Infrastructure v1.27.0 published on Friday, Mar 15, 2024 by Pulumi

oci.Dns.getTsigKeys

Explore with Pulumi AI

oci logo
Oracle Cloud Infrastructure v1.27.0 published on Friday, Mar 15, 2024 by Pulumi

    This data source provides the list of Tsig Keys in Oracle Cloud Infrastructure DNS service.

    Gets a list of all TSIG keys in the specified compartment.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as oci from "@pulumi/oci";
    
    const testTsigKeys = oci.Dns.getTsigKeys({
        compartmentId: _var.compartment_id,
        id: _var.tsig_key_id,
        name: _var.tsig_key_name,
        state: _var.tsig_key_state,
    });
    
    import pulumi
    import pulumi_oci as oci
    
    test_tsig_keys = oci.Dns.get_tsig_keys(compartment_id=var["compartment_id"],
        id=var["tsig_key_id"],
        name=var["tsig_key_name"],
        state=var["tsig_key_state"])
    
    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.GetTsigKeys(ctx, &dns.GetTsigKeysArgs{
    			CompartmentId: _var.Compartment_id,
    			Id:            pulumi.StringRef(_var.Tsig_key_id),
    			Name:          pulumi.StringRef(_var.Tsig_key_name),
    			State:         pulumi.StringRef(_var.Tsig_key_state),
    		}, nil)
    		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 testTsigKeys = Oci.Dns.GetTsigKeys.Invoke(new()
        {
            CompartmentId = @var.Compartment_id,
            Id = @var.Tsig_key_id,
            Name = @var.Tsig_key_name,
            State = @var.Tsig_key_state,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.oci.Dns.DnsFunctions;
    import com.pulumi.oci.Dns.inputs.GetTsigKeysArgs;
    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 testTsigKeys = DnsFunctions.getTsigKeys(GetTsigKeysArgs.builder()
                .compartmentId(var_.compartment_id())
                .id(var_.tsig_key_id())
                .name(var_.tsig_key_name())
                .state(var_.tsig_key_state())
                .build());
    
        }
    }
    
    variables:
      testTsigKeys:
        fn::invoke:
          Function: oci:Dns:getTsigKeys
          Arguments:
            compartmentId: ${var.compartment_id}
            id: ${var.tsig_key_id}
            name: ${var.tsig_key_name}
            state: ${var.tsig_key_state}
    

    Using getTsigKeys

    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 getTsigKeys(args: GetTsigKeysArgs, opts?: InvokeOptions): Promise<GetTsigKeysResult>
    function getTsigKeysOutput(args: GetTsigKeysOutputArgs, opts?: InvokeOptions): Output<GetTsigKeysResult>
    def get_tsig_keys(compartment_id: Optional[str] = None,
                      filters: Optional[Sequence[_dns.GetTsigKeysFilter]] = None,
                      id: Optional[str] = None,
                      name: Optional[str] = None,
                      state: Optional[str] = None,
                      opts: Optional[InvokeOptions] = None) -> GetTsigKeysResult
    def get_tsig_keys_output(compartment_id: Optional[pulumi.Input[str]] = None,
                      filters: Optional[pulumi.Input[Sequence[pulumi.Input[_dns.GetTsigKeysFilterArgs]]]] = None,
                      id: Optional[pulumi.Input[str]] = None,
                      name: Optional[pulumi.Input[str]] = None,
                      state: Optional[pulumi.Input[str]] = None,
                      opts: Optional[InvokeOptions] = None) -> Output[GetTsigKeysResult]
    func GetTsigKeys(ctx *Context, args *GetTsigKeysArgs, opts ...InvokeOption) (*GetTsigKeysResult, error)
    func GetTsigKeysOutput(ctx *Context, args *GetTsigKeysOutputArgs, opts ...InvokeOption) GetTsigKeysResultOutput

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

    public static class GetTsigKeys 
    {
        public static Task<GetTsigKeysResult> InvokeAsync(GetTsigKeysArgs args, InvokeOptions? opts = null)
        public static Output<GetTsigKeysResult> Invoke(GetTsigKeysInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetTsigKeysResult> getTsigKeys(GetTsigKeysArgs args, InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: oci:Dns/getTsigKeys:getTsigKeys
      arguments:
        # arguments dictionary

    The following arguments are supported:

    CompartmentId string
    The OCID of the compartment the resource belongs to.
    Filters List<GetTsigKeysFilter>
    Id string
    The OCID of a resource.
    Name string
    The name of a resource.
    State string
    The state of a resource.
    CompartmentId string
    The OCID of the compartment the resource belongs to.
    Filters []GetTsigKeysFilter
    Id string
    The OCID of a resource.
    Name string
    The name of a resource.
    State string
    The state of a resource.
    compartmentId String
    The OCID of the compartment the resource belongs to.
    filters List<GetTsigKeysFilter>
    id String
    The OCID of a resource.
    name String
    The name of a resource.
    state String
    The state of a resource.
    compartmentId string
    The OCID of the compartment the resource belongs to.
    filters GetTsigKeysFilter[]
    id string
    The OCID of a resource.
    name string
    The name of a resource.
    state string
    The state of a resource.
    compartment_id str
    The OCID of the compartment the resource belongs to.
    filters GetTsigKeysFilter]
    id str
    The OCID of a resource.
    name str
    The name of a resource.
    state str
    The state of a resource.
    compartmentId String
    The OCID of the compartment the resource belongs to.
    filters List<Property Map>
    id String
    The OCID of a resource.
    name String
    The name of a resource.
    state String
    The state of a resource.

    getTsigKeys Result

    The following output properties are available:

    CompartmentId string
    The OCID of the compartment containing the TSIG key.
    TsigKeys List<GetTsigKeysTsigKey>
    The list of tsig_keys.
    Filters List<GetTsigKeysFilter>
    Id string
    The OCID of the resource.
    Name string
    A globally unique domain name identifying the key for a given pair of hosts.
    State string
    The current state of the resource.
    CompartmentId string
    The OCID of the compartment containing the TSIG key.
    TsigKeys []GetTsigKeysTsigKey
    The list of tsig_keys.
    Filters []GetTsigKeysFilter
    Id string
    The OCID of the resource.
    Name string
    A globally unique domain name identifying the key for a given pair of hosts.
    State string
    The current state of the resource.
    compartmentId String
    The OCID of the compartment containing the TSIG key.
    tsigKeys List<GetTsigKeysTsigKey>
    The list of tsig_keys.
    filters List<GetTsigKeysFilter>
    id String
    The OCID of the resource.
    name String
    A globally unique domain name identifying the key for a given pair of hosts.
    state String
    The current state of the resource.
    compartmentId string
    The OCID of the compartment containing the TSIG key.
    tsigKeys GetTsigKeysTsigKey[]
    The list of tsig_keys.
    filters GetTsigKeysFilter[]
    id string
    The OCID of the resource.
    name string
    A globally unique domain name identifying the key for a given pair of hosts.
    state string
    The current state of the resource.
    compartment_id str
    The OCID of the compartment containing the TSIG key.
    tsig_keys GetTsigKeysTsigKey]
    The list of tsig_keys.
    filters GetTsigKeysFilter]
    id str
    The OCID of the resource.
    name str
    A globally unique domain name identifying the key for a given pair of hosts.
    state str
    The current state of the resource.
    compartmentId String
    The OCID of the compartment containing the TSIG key.
    tsigKeys List<Property Map>
    The list of tsig_keys.
    filters List<Property Map>
    id String
    The OCID of the resource.
    name String
    A globally unique domain name identifying the key for a given pair of hosts.
    state String
    The current state of the resource.

    Supporting Types

    GetTsigKeysFilter

    Name string
    The name of a resource.
    Values List<string>
    Regex bool
    Name string
    The name of a resource.
    Values []string
    Regex bool
    name String
    The name of a resource.
    values List<String>
    regex Boolean
    name string
    The name of a resource.
    values string[]
    regex boolean
    name str
    The name of a resource.
    values Sequence[str]
    regex bool
    name String
    The name of a resource.
    values List<String>
    regex Boolean

    GetTsigKeysTsigKey

    Algorithm string
    TSIG key algorithms are encoded as domain names, but most consist of only one non-empty label, which is not required to be explicitly absolute. Applicable algorithms include: hmac-sha1, hmac-sha224, hmac-sha256, hmac-sha512. For more information on these algorithms, see RFC 4635.
    CompartmentId string
    The OCID of the compartment the resource belongs to.
    DefinedTags Dictionary<string, object>
    Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags.
    FreeformTags Dictionary<string, object>
    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.
    Id string
    The OCID of a resource.
    Name string
    The name of a resource.
    Secret string
    A base64 string encoding the binary shared secret.
    Self string
    The canonical absolute URL of the resource.
    State string
    The state of a resource.
    TimeCreated string
    The date and time the resource was created, expressed in RFC 3339 timestamp format.
    TimeUpdated string
    The date and time the resource was last updated, expressed in RFC 3339 timestamp format.
    Algorithm string
    TSIG key algorithms are encoded as domain names, but most consist of only one non-empty label, which is not required to be explicitly absolute. Applicable algorithms include: hmac-sha1, hmac-sha224, hmac-sha256, hmac-sha512. For more information on these algorithms, see RFC 4635.
    CompartmentId string
    The OCID of the compartment the resource belongs to.
    DefinedTags map[string]interface{}
    Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags.
    FreeformTags map[string]interface{}
    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.
    Id string
    The OCID of a resource.
    Name string
    The name of a resource.
    Secret string
    A base64 string encoding the binary shared secret.
    Self string
    The canonical absolute URL of the resource.
    State string
    The state of a resource.
    TimeCreated string
    The date and time the resource was created, expressed in RFC 3339 timestamp format.
    TimeUpdated string
    The date and time the resource was last updated, expressed in RFC 3339 timestamp format.
    algorithm String
    TSIG key algorithms are encoded as domain names, but most consist of only one non-empty label, which is not required to be explicitly absolute. Applicable algorithms include: hmac-sha1, hmac-sha224, hmac-sha256, hmac-sha512. For more information on these algorithms, see RFC 4635.
    compartmentId String
    The OCID of the compartment the resource belongs to.
    definedTags Map<String,Object>
    Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags.
    freeformTags Map<String,Object>
    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.
    id String
    The OCID of a resource.
    name String
    The name of a resource.
    secret String
    A base64 string encoding the binary shared secret.
    self String
    The canonical absolute URL of the resource.
    state String
    The state of a resource.
    timeCreated String
    The date and time the resource was created, expressed in RFC 3339 timestamp format.
    timeUpdated String
    The date and time the resource was last updated, expressed in RFC 3339 timestamp format.
    algorithm string
    TSIG key algorithms are encoded as domain names, but most consist of only one non-empty label, which is not required to be explicitly absolute. Applicable algorithms include: hmac-sha1, hmac-sha224, hmac-sha256, hmac-sha512. For more information on these algorithms, see RFC 4635.
    compartmentId string
    The OCID of the compartment the resource belongs to.
    definedTags {[key: string]: any}
    Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags.
    freeformTags {[key: string]: any}
    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.
    id string
    The OCID of a resource.
    name string
    The name of a resource.
    secret string
    A base64 string encoding the binary shared secret.
    self string
    The canonical absolute URL of the resource.
    state string
    The state of a resource.
    timeCreated string
    The date and time the resource was created, expressed in RFC 3339 timestamp format.
    timeUpdated string
    The date and time the resource was last updated, expressed in RFC 3339 timestamp format.
    algorithm str
    TSIG key algorithms are encoded as domain names, but most consist of only one non-empty label, which is not required to be explicitly absolute. Applicable algorithms include: hmac-sha1, hmac-sha224, hmac-sha256, hmac-sha512. For more information on these algorithms, see RFC 4635.
    compartment_id str
    The OCID of the compartment the resource belongs to.
    defined_tags Mapping[str, Any]
    Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags.
    freeform_tags Mapping[str, Any]
    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.
    id str
    The OCID of a resource.
    name str
    The name of a resource.
    secret str
    A base64 string encoding the binary shared secret.
    self str
    The canonical absolute URL of the resource.
    state str
    The state of a resource.
    time_created str
    The date and time the resource was created, expressed in RFC 3339 timestamp format.
    time_updated str
    The date and time the resource was last updated, expressed in RFC 3339 timestamp format.
    algorithm String
    TSIG key algorithms are encoded as domain names, but most consist of only one non-empty label, which is not required to be explicitly absolute. Applicable algorithms include: hmac-sha1, hmac-sha224, hmac-sha256, hmac-sha512. For more information on these algorithms, see RFC 4635.
    compartmentId String
    The OCID of the compartment the resource belongs to.
    definedTags Map<Any>
    Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags.
    freeformTags Map<Any>
    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.
    id String
    The OCID of a resource.
    name String
    The name of a resource.
    secret String
    A base64 string encoding the binary shared secret.
    self String
    The canonical absolute URL of the resource.
    state String
    The state of a resource.
    timeCreated String
    The date and time the resource was created, expressed in RFC 3339 timestamp format.
    timeUpdated String
    The date and time the resource was last updated, expressed in RFC 3339 timestamp format.

    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.27.0 published on Friday, Mar 15, 2024 by Pulumi