1. Packages
  2. Fortios
  3. API Docs
  4. fmg
  5. SystemNtp
Fortios v0.0.5 published on Tuesday, Apr 9, 2024 by pulumiverse

fortios.fmg.SystemNtp

Explore with Pulumi AI

fortios logo
Fortios v0.0.5 published on Tuesday, Apr 9, 2024 by pulumiverse

    This resource supports modifying system ntp setting for FortiManager.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as fortios from "@pulumiverse/fortios";
    
    const test1 = new fortios.fmg.SystemNtp("test1", {
        server: "ntp1.fortinet.com",
        status: "enable",
        syncInterval: 30,
    });
    
    import pulumi
    import pulumiverse_fortios as fortios
    
    test1 = fortios.fmg.SystemNtp("test1",
        server="ntp1.fortinet.com",
        status="enable",
        sync_interval=30)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    	"github.com/pulumiverse/pulumi-fortios/sdk/go/fortios/fmg"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := fmg.NewSystemNtp(ctx, "test1", &fmg.SystemNtpArgs{
    			Server:       pulumi.String("ntp1.fortinet.com"),
    			Status:       pulumi.String("enable"),
    			SyncInterval: pulumi.Int(30),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Fortios = Pulumiverse.Fortios;
    
    return await Deployment.RunAsync(() => 
    {
        var test1 = new Fortios.Fmg.SystemNtp("test1", new()
        {
            Server = "ntp1.fortinet.com",
            Status = "enable",
            SyncInterval = 30,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.fortios.fmg.SystemNtp;
    import com.pulumi.fortios.fmg.SystemNtpArgs;
    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 test1 = new SystemNtp("test1", SystemNtpArgs.builder()        
                .server("ntp1.fortinet.com")
                .status("enable")
                .syncInterval(30)
                .build());
    
        }
    }
    
    resources:
      test1:
        type: fortios:fmg:SystemNtp
        properties:
          server: ntp1.fortinet.com
          status: enable
          syncInterval: 30
    

    Create SystemNtp Resource

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

    Constructor syntax

    new SystemNtp(name: string, args: SystemNtpArgs, opts?: CustomResourceOptions);
    @overload
    def SystemNtp(resource_name: str,
                  args: SystemNtpArgs,
                  opts: Optional[ResourceOptions] = None)
    
    @overload
    def SystemNtp(resource_name: str,
                  opts: Optional[ResourceOptions] = None,
                  server: Optional[str] = None,
                  status: Optional[str] = None,
                  sync_interval: Optional[int] = None)
    func NewSystemNtp(ctx *Context, name string, args SystemNtpArgs, opts ...ResourceOption) (*SystemNtp, error)
    public SystemNtp(string name, SystemNtpArgs args, CustomResourceOptions? opts = null)
    public SystemNtp(String name, SystemNtpArgs args)
    public SystemNtp(String name, SystemNtpArgs args, CustomResourceOptions options)
    
    type: fortios:fmg:SystemNtp
    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 SystemNtpArgs
    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 SystemNtpArgs
    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 SystemNtpArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args SystemNtpArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args SystemNtpArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Example

    The following reference example uses placeholder values for all input properties.

    var systemNtpResource = new Fortios.Fmg.SystemNtp("systemNtpResource", new()
    {
        Server = "string",
        Status = "string",
        SyncInterval = 0,
    });
    
    example, err := fmg.NewSystemNtp(ctx, "systemNtpResource", &fmg.SystemNtpArgs{
    	Server:       pulumi.String("string"),
    	Status:       pulumi.String("string"),
    	SyncInterval: pulumi.Int(0),
    })
    
    var systemNtpResource = new SystemNtp("systemNtpResource", SystemNtpArgs.builder()
        .server("string")
        .status("string")
        .syncInterval(0)
        .build());
    
    system_ntp_resource = fortios.fmg.SystemNtp("systemNtpResource",
        server="string",
        status="string",
        sync_interval=0)
    
    const systemNtpResource = new fortios.fmg.SystemNtp("systemNtpResource", {
        server: "string",
        status: "string",
        syncInterval: 0,
    });
    
    type: fortios:fmg:SystemNtp
    properties:
        server: string
        status: string
        syncInterval: 0
    

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

    Server string
    IP address/hostname of NTP Server.
    Status string
    Enable/disable NTP.
    SyncInterval int
    NTP sync interval (minute).
    Server string
    IP address/hostname of NTP Server.
    Status string
    Enable/disable NTP.
    SyncInterval int
    NTP sync interval (minute).
    server String
    IP address/hostname of NTP Server.
    status String
    Enable/disable NTP.
    syncInterval Integer
    NTP sync interval (minute).
    server string
    IP address/hostname of NTP Server.
    status string
    Enable/disable NTP.
    syncInterval number
    NTP sync interval (minute).
    server str
    IP address/hostname of NTP Server.
    status str
    Enable/disable NTP.
    sync_interval int
    NTP sync interval (minute).
    server String
    IP address/hostname of NTP Server.
    status String
    Enable/disable NTP.
    syncInterval Number
    NTP sync interval (minute).

    Outputs

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

    Id string
    The provider-assigned unique ID for this managed resource.
    Id string
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.
    id string
    The provider-assigned unique ID for this managed resource.
    id str
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing SystemNtp Resource

    Get an existing SystemNtp 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?: SystemNtpState, opts?: CustomResourceOptions): SystemNtp
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            server: Optional[str] = None,
            status: Optional[str] = None,
            sync_interval: Optional[int] = None) -> SystemNtp
    func GetSystemNtp(ctx *Context, name string, id IDInput, state *SystemNtpState, opts ...ResourceOption) (*SystemNtp, error)
    public static SystemNtp Get(string name, Input<string> id, SystemNtpState? state, CustomResourceOptions? opts = null)
    public static SystemNtp get(String name, Output<String> id, SystemNtpState 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:
    Server string
    IP address/hostname of NTP Server.
    Status string
    Enable/disable NTP.
    SyncInterval int
    NTP sync interval (minute).
    Server string
    IP address/hostname of NTP Server.
    Status string
    Enable/disable NTP.
    SyncInterval int
    NTP sync interval (minute).
    server String
    IP address/hostname of NTP Server.
    status String
    Enable/disable NTP.
    syncInterval Integer
    NTP sync interval (minute).
    server string
    IP address/hostname of NTP Server.
    status string
    Enable/disable NTP.
    syncInterval number
    NTP sync interval (minute).
    server str
    IP address/hostname of NTP Server.
    status str
    Enable/disable NTP.
    sync_interval int
    NTP sync interval (minute).
    server String
    IP address/hostname of NTP Server.
    status String
    Enable/disable NTP.
    syncInterval Number
    NTP sync interval (minute).

    Package Details

    Repository
    fortios pulumiverse/pulumi-fortios
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the fortios Terraform Provider.
    fortios logo
    Fortios v0.0.5 published on Tuesday, Apr 9, 2024 by pulumiverse