UNPKG

@pulumiverse/fortios

Version:

A Pulumi package for creating and managing Fortios resources. Based on terraform-provider-fortios: version v1.16.0

86 lines 3.76 kB
"use strict"; // *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. *** // *** Do not edit by hand unless you're certain you know what you are doing! *** Object.defineProperty(exports, "__esModule", { value: true }); exports.SyslogSetting = void 0; const pulumi = require("@pulumi/pulumi"); const utilities = require("../utilities"); /** * Provides a resource to configure logging to remote Syslog logging servers. * * !> **Warning:** The resource will be deprecated and replaced by new resource `fortios.log/syslogd.Setting`, we recommend that you use the new resource. * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as fortios from "@pulumiverse/fortios"; * * const test2 = new fortios.log.SyslogSetting("test2", { * facility: "local7", * format: "csv", * mode: "udp", * port: "514", * server: "2.2.2.2", * sourceIp: "10.2.2.199", * status: "enable", * }); * ``` */ class SyslogSetting extends pulumi.CustomResource { /** * Get an existing SyslogSetting resource's state with the given name, ID, and optional extra * properties used to qualify the lookup. * * @param name The _unique_ name of the resulting resource. * @param id The _unique_ provider ID of the resource to lookup. * @param state Any extra arguments used during the lookup. * @param opts Optional settings to control the behavior of the CustomResource. */ static get(name, id, state, opts) { return new SyslogSetting(name, state, Object.assign(Object.assign({}, opts), { id: id })); } /** * Returns true if the given object is an instance of SyslogSetting. This is designed to work even * when multiple copies of the Pulumi SDK have been loaded into the same process. */ static isInstance(obj) { if (obj === undefined || obj === null) { return false; } return obj['__pulumiType'] === SyslogSetting.__pulumiType; } constructor(name, argsOrState, opts) { let resourceInputs = {}; opts = opts || {}; if (opts.id) { const state = argsOrState; resourceInputs["facility"] = state ? state.facility : undefined; resourceInputs["format"] = state ? state.format : undefined; resourceInputs["mode"] = state ? state.mode : undefined; resourceInputs["port"] = state ? state.port : undefined; resourceInputs["server"] = state ? state.server : undefined; resourceInputs["sourceIp"] = state ? state.sourceIp : undefined; resourceInputs["status"] = state ? state.status : undefined; } else { const args = argsOrState; if ((!args || args.status === undefined) && !opts.urn) { throw new Error("Missing required property 'status'"); } resourceInputs["facility"] = args ? args.facility : undefined; resourceInputs["format"] = args ? args.format : undefined; resourceInputs["mode"] = args ? args.mode : undefined; resourceInputs["port"] = args ? args.port : undefined; resourceInputs["server"] = args ? args.server : undefined; resourceInputs["sourceIp"] = args ? args.sourceIp : undefined; resourceInputs["status"] = args ? args.status : undefined; } opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts); super(SyslogSetting.__pulumiType, name, resourceInputs, opts); } } exports.SyslogSetting = SyslogSetting; /** @internal */ SyslogSetting.__pulumiType = 'fortios:log/syslogSetting:SyslogSetting'; //# sourceMappingURL=syslogSetting.js.map