Cisco NX-OS v0.0.2 published on Friday, Sep 29, 2023 by lbrlabs
nxos.getNtpServer
Explore with Pulumi AI
This data source can read an ntp server or peer.
- API Documentation: datetimeNtpProvider
Example Usage
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Nxos = Pulumi.Nxos;
return await Deployment.RunAsync(() => 
{
    var example = Nxos.GetNtpServer.Invoke(new()
    {
        Name = "1.2.3.4",
    });
});
package main
import (
	"github.com/lbrlabs/pulumi-nxos/sdk/go/nxos"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := nxos.LookupNtpServer(ctx, &nxos.LookupNtpServerArgs{
			Name: "1.2.3.4",
		}, nil)
		if err != nil {
			return err
		}
		return nil
	})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.nxos.NxosFunctions;
import com.pulumi.nxos.inputs.GetNtpServerArgs;
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 example = NxosFunctions.getNtpServer(GetNtpServerArgs.builder()
            .name("1.2.3.4")
            .build());
    }
}
import * as pulumi from "@pulumi/pulumi";
import * as nxos from "@pulumi/nxos";
const example = nxos.getNtpServer({
    name: "1.2.3.4",
});
import pulumi
import pulumi_nxos as nxos
example = nxos.get_ntp_server(name="1.2.3.4")
variables:
  example:
    fn::invoke:
      Function: nxos:getNtpServer
      Arguments:
        name: 1.2.3.4
Using getNtpServer
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 getNtpServer(args: GetNtpServerArgs, opts?: InvokeOptions): Promise<GetNtpServerResult>
function getNtpServerOutput(args: GetNtpServerOutputArgs, opts?: InvokeOptions): Output<GetNtpServerResult>def get_ntp_server(device: Optional[str] = None,
                   name: Optional[str] = None,
                   opts: Optional[InvokeOptions] = None) -> GetNtpServerResult
def get_ntp_server_output(device: Optional[pulumi.Input[str]] = None,
                   name: Optional[pulumi.Input[str]] = None,
                   opts: Optional[InvokeOptions] = None) -> Output[GetNtpServerResult]func LookupNtpServer(ctx *Context, args *LookupNtpServerArgs, opts ...InvokeOption) (*LookupNtpServerResult, error)
func LookupNtpServerOutput(ctx *Context, args *LookupNtpServerOutputArgs, opts ...InvokeOption) LookupNtpServerResultOutput> Note: This function is named LookupNtpServer in the Go SDK.
public static class GetNtpServer 
{
    public static Task<GetNtpServerResult> InvokeAsync(GetNtpServerArgs args, InvokeOptions? opts = null)
    public static Output<GetNtpServerResult> Invoke(GetNtpServerInvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<GetNtpServerResult> getNtpServer(GetNtpServerArgs args, InvokeOptions options)
public static Output<GetNtpServerResult> getNtpServer(GetNtpServerArgs args, InvokeOptions options)
fn::invoke:
  function: nxos:index/getNtpServer:getNtpServer
  arguments:
    # arguments dictionaryThe following arguments are supported:
getNtpServer Result
The following output properties are available:
- Id string
- The distinguished name of the object.
- KeyId int
- NTP provider key ID. Possible range is from 1to65535.
- MaxPoll int
- NTP maximum interval default in seconds. Possible range is from 4to16.
- MinPoll int
- NTP minimum interval default in seconds. Possible range is from 4to16.
- Name string
- NTP server.
- Type string
- NTP provider type. Possible values are serverorpeer.
- Vrf string
- Identifies the VRF for the NTP providers.
- Device string
- A device name from the provider configuration.
- Id string
- The distinguished name of the object.
- KeyId int
- NTP provider key ID. Possible range is from 1to65535.
- MaxPoll int
- NTP maximum interval default in seconds. Possible range is from 4to16.
- MinPoll int
- NTP minimum interval default in seconds. Possible range is from 4to16.
- Name string
- NTP server.
- Type string
- NTP provider type. Possible values are serverorpeer.
- Vrf string
- Identifies the VRF for the NTP providers.
- Device string
- A device name from the provider configuration.
- id String
- The distinguished name of the object.
- keyId Integer
- NTP provider key ID. Possible range is from 1to65535.
- maxPoll Integer
- NTP maximum interval default in seconds. Possible range is from 4to16.
- minPoll Integer
- NTP minimum interval default in seconds. Possible range is from 4to16.
- name String
- NTP server.
- type String
- NTP provider type. Possible values are serverorpeer.
- vrf String
- Identifies the VRF for the NTP providers.
- device String
- A device name from the provider configuration.
- id string
- The distinguished name of the object.
- keyId number
- NTP provider key ID. Possible range is from 1to65535.
- maxPoll number
- NTP maximum interval default in seconds. Possible range is from 4to16.
- minPoll number
- NTP minimum interval default in seconds. Possible range is from 4to16.
- name string
- NTP server.
- type string
- NTP provider type. Possible values are serverorpeer.
- vrf string
- Identifies the VRF for the NTP providers.
- device string
- A device name from the provider configuration.
- id str
- The distinguished name of the object.
- key_id int
- NTP provider key ID. Possible range is from 1to65535.
- max_poll int
- NTP maximum interval default in seconds. Possible range is from 4to16.
- min_poll int
- NTP minimum interval default in seconds. Possible range is from 4to16.
- name str
- NTP server.
- type str
- NTP provider type. Possible values are serverorpeer.
- vrf str
- Identifies the VRF for the NTP providers.
- device str
- A device name from the provider configuration.
- id String
- The distinguished name of the object.
- keyId Number
- NTP provider key ID. Possible range is from 1to65535.
- maxPoll Number
- NTP maximum interval default in seconds. Possible range is from 4to16.
- minPoll Number
- NTP minimum interval default in seconds. Possible range is from 4to16.
- name String
- NTP server.
- type String
- NTP provider type. Possible values are serverorpeer.
- vrf String
- Identifies the VRF for the NTP providers.
- device String
- A device name from the provider configuration.
Package Details
- Repository
- nxos lbrlabs/pulumi-nxos
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the nxosTerraform Provider.