UNPKG

@pulumiverse/fortios

Version:

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

249 lines 16.6 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.Fortiguard = void 0; const pulumi = require("@pulumi/pulumi"); const utilities = require("../utilities"); /** * Configure FortiGuard services. * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as fortios from "@pulumiverse/fortios"; * * const trname = new fortios.system.Fortiguard("trname", { * antispamCache: "enable", * antispamCacheMpercent: 2, * antispamCacheTtl: 1800, * antispamExpiration: 1618617600, * antispamForceOff: "disable", * antispamLicense: 1, * antispamTimeout: 7, * autoJoinForticloud: "enable", * ddnsServerIp: "0.0.0.0", * ddnsServerPort: 443, * loadBalanceServers: 1, * outbreakPreventionCache: "enable", * outbreakPreventionCacheMpercent: 2, * outbreakPreventionCacheTtl: 300, * outbreakPreventionExpiration: 1618617600, * outbreakPreventionForceOff: "disable", * outbreakPreventionLicense: 1, * outbreakPreventionTimeout: 7, * port: "8888", * sdnsServerIp: "\"208.91.112.220\" ", * sdnsServerPort: 53, * sourceIp: "0.0.0.0", * sourceIp6: "::", * updateServerLocation: "usa", * webfilterCache: "enable", * webfilterCacheTtl: 3600, * webfilterExpiration: 1618617600, * webfilterForceOff: "disable", * webfilterLicense: 1, * webfilterTimeout: 15, * }); * ``` * * ## Import * * System Fortiguard can be imported using any of these accepted formats: * * ```sh * $ pulumi import fortios:system/fortiguard:Fortiguard labelname SystemFortiguard * ``` * * If you do not want to import arguments of block: * * $ export "FORTIOS_IMPORT_TABLE"="false" * * ```sh * $ pulumi import fortios:system/fortiguard:Fortiguard labelname SystemFortiguard * ``` * * $ unset "FORTIOS_IMPORT_TABLE" */ class Fortiguard extends pulumi.CustomResource { /** * Get an existing Fortiguard 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 Fortiguard(name, state, Object.assign(Object.assign({}, opts), { id: id })); } /** * Returns true if the given object is an instance of Fortiguard. 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'] === Fortiguard.__pulumiType; } constructor(name, argsOrState, opts) { let resourceInputs = {}; opts = opts || {}; if (opts.id) { const state = argsOrState; resourceInputs["antispamCache"] = state ? state.antispamCache : undefined; resourceInputs["antispamCacheMpercent"] = state ? state.antispamCacheMpercent : undefined; resourceInputs["antispamCacheMpermille"] = state ? state.antispamCacheMpermille : undefined; resourceInputs["antispamCacheTtl"] = state ? state.antispamCacheTtl : undefined; resourceInputs["antispamExpiration"] = state ? state.antispamExpiration : undefined; resourceInputs["antispamForceOff"] = state ? state.antispamForceOff : undefined; resourceInputs["antispamLicense"] = state ? state.antispamLicense : undefined; resourceInputs["antispamTimeout"] = state ? state.antispamTimeout : undefined; resourceInputs["anycastSdnsServerIp"] = state ? state.anycastSdnsServerIp : undefined; resourceInputs["anycastSdnsServerPort"] = state ? state.anycastSdnsServerPort : undefined; resourceInputs["autoFirmwareUpgrade"] = state ? state.autoFirmwareUpgrade : undefined; resourceInputs["autoFirmwareUpgradeDay"] = state ? state.autoFirmwareUpgradeDay : undefined; resourceInputs["autoFirmwareUpgradeDelay"] = state ? state.autoFirmwareUpgradeDelay : undefined; resourceInputs["autoFirmwareUpgradeEndHour"] = state ? state.autoFirmwareUpgradeEndHour : undefined; resourceInputs["autoFirmwareUpgradeStartHour"] = state ? state.autoFirmwareUpgradeStartHour : undefined; resourceInputs["autoJoinForticloud"] = state ? state.autoJoinForticloud : undefined; resourceInputs["ddnsServerIp"] = state ? state.ddnsServerIp : undefined; resourceInputs["ddnsServerIp6"] = state ? state.ddnsServerIp6 : undefined; resourceInputs["ddnsServerPort"] = state ? state.ddnsServerPort : undefined; resourceInputs["fdsLicenseExpiringDays"] = state ? state.fdsLicenseExpiringDays : undefined; resourceInputs["fortiguardAnycast"] = state ? state.fortiguardAnycast : undefined; resourceInputs["fortiguardAnycastSource"] = state ? state.fortiguardAnycastSource : undefined; resourceInputs["guiPromptAutoUpgrade"] = state ? state.guiPromptAutoUpgrade : undefined; resourceInputs["interface"] = state ? state.interface : undefined; resourceInputs["interfaceSelectMethod"] = state ? state.interfaceSelectMethod : undefined; resourceInputs["loadBalanceServers"] = state ? state.loadBalanceServers : undefined; resourceInputs["outbreakPreventionCache"] = state ? state.outbreakPreventionCache : undefined; resourceInputs["outbreakPreventionCacheMpercent"] = state ? state.outbreakPreventionCacheMpercent : undefined; resourceInputs["outbreakPreventionCacheMpermille"] = state ? state.outbreakPreventionCacheMpermille : undefined; resourceInputs["outbreakPreventionCacheTtl"] = state ? state.outbreakPreventionCacheTtl : undefined; resourceInputs["outbreakPreventionExpiration"] = state ? state.outbreakPreventionExpiration : undefined; resourceInputs["outbreakPreventionForceOff"] = state ? state.outbreakPreventionForceOff : undefined; resourceInputs["outbreakPreventionLicense"] = state ? state.outbreakPreventionLicense : undefined; resourceInputs["outbreakPreventionTimeout"] = state ? state.outbreakPreventionTimeout : undefined; resourceInputs["persistentConnection"] = state ? state.persistentConnection : undefined; resourceInputs["port"] = state ? state.port : undefined; resourceInputs["protocol"] = state ? state.protocol : undefined; resourceInputs["proxyPassword"] = state ? state.proxyPassword : undefined; resourceInputs["proxyServerIp"] = state ? state.proxyServerIp : undefined; resourceInputs["proxyServerPort"] = state ? state.proxyServerPort : undefined; resourceInputs["proxyUsername"] = state ? state.proxyUsername : undefined; resourceInputs["sandboxInlineScan"] = state ? state.sandboxInlineScan : undefined; resourceInputs["sandboxRegion"] = state ? state.sandboxRegion : undefined; resourceInputs["sdnsOptions"] = state ? state.sdnsOptions : undefined; resourceInputs["sdnsServerIp"] = state ? state.sdnsServerIp : undefined; resourceInputs["sdnsServerPort"] = state ? state.sdnsServerPort : undefined; resourceInputs["serviceAccountId"] = state ? state.serviceAccountId : undefined; resourceInputs["sourceIp"] = state ? state.sourceIp : undefined; resourceInputs["sourceIp6"] = state ? state.sourceIp6 : undefined; resourceInputs["updateBuildProxy"] = state ? state.updateBuildProxy : undefined; resourceInputs["updateDldb"] = state ? state.updateDldb : undefined; resourceInputs["updateExtdb"] = state ? state.updateExtdb : undefined; resourceInputs["updateFfdb"] = state ? state.updateFfdb : undefined; resourceInputs["updateServerLocation"] = state ? state.updateServerLocation : undefined; resourceInputs["updateUwdb"] = state ? state.updateUwdb : undefined; resourceInputs["vdom"] = state ? state.vdom : undefined; resourceInputs["vdomparam"] = state ? state.vdomparam : undefined; resourceInputs["videofilterExpiration"] = state ? state.videofilterExpiration : undefined; resourceInputs["videofilterLicense"] = state ? state.videofilterLicense : undefined; resourceInputs["webfilterCache"] = state ? state.webfilterCache : undefined; resourceInputs["webfilterCacheTtl"] = state ? state.webfilterCacheTtl : undefined; resourceInputs["webfilterExpiration"] = state ? state.webfilterExpiration : undefined; resourceInputs["webfilterForceOff"] = state ? state.webfilterForceOff : undefined; resourceInputs["webfilterLicense"] = state ? state.webfilterLicense : undefined; resourceInputs["webfilterTimeout"] = state ? state.webfilterTimeout : undefined; } else { const args = argsOrState; if ((!args || args.antispamTimeout === undefined) && !opts.urn) { throw new Error("Missing required property 'antispamTimeout'"); } if ((!args || args.outbreakPreventionTimeout === undefined) && !opts.urn) { throw new Error("Missing required property 'outbreakPreventionTimeout'"); } if ((!args || args.webfilterTimeout === undefined) && !opts.urn) { throw new Error("Missing required property 'webfilterTimeout'"); } resourceInputs["antispamCache"] = args ? args.antispamCache : undefined; resourceInputs["antispamCacheMpercent"] = args ? args.antispamCacheMpercent : undefined; resourceInputs["antispamCacheMpermille"] = args ? args.antispamCacheMpermille : undefined; resourceInputs["antispamCacheTtl"] = args ? args.antispamCacheTtl : undefined; resourceInputs["antispamExpiration"] = args ? args.antispamExpiration : undefined; resourceInputs["antispamForceOff"] = args ? args.antispamForceOff : undefined; resourceInputs["antispamLicense"] = args ? args.antispamLicense : undefined; resourceInputs["antispamTimeout"] = args ? args.antispamTimeout : undefined; resourceInputs["anycastSdnsServerIp"] = args ? args.anycastSdnsServerIp : undefined; resourceInputs["anycastSdnsServerPort"] = args ? args.anycastSdnsServerPort : undefined; resourceInputs["autoFirmwareUpgrade"] = args ? args.autoFirmwareUpgrade : undefined; resourceInputs["autoFirmwareUpgradeDay"] = args ? args.autoFirmwareUpgradeDay : undefined; resourceInputs["autoFirmwareUpgradeDelay"] = args ? args.autoFirmwareUpgradeDelay : undefined; resourceInputs["autoFirmwareUpgradeEndHour"] = args ? args.autoFirmwareUpgradeEndHour : undefined; resourceInputs["autoFirmwareUpgradeStartHour"] = args ? args.autoFirmwareUpgradeStartHour : undefined; resourceInputs["autoJoinForticloud"] = args ? args.autoJoinForticloud : undefined; resourceInputs["ddnsServerIp"] = args ? args.ddnsServerIp : undefined; resourceInputs["ddnsServerIp6"] = args ? args.ddnsServerIp6 : undefined; resourceInputs["ddnsServerPort"] = args ? args.ddnsServerPort : undefined; resourceInputs["fdsLicenseExpiringDays"] = args ? args.fdsLicenseExpiringDays : undefined; resourceInputs["fortiguardAnycast"] = args ? args.fortiguardAnycast : undefined; resourceInputs["fortiguardAnycastSource"] = args ? args.fortiguardAnycastSource : undefined; resourceInputs["guiPromptAutoUpgrade"] = args ? args.guiPromptAutoUpgrade : undefined; resourceInputs["interface"] = args ? args.interface : undefined; resourceInputs["interfaceSelectMethod"] = args ? args.interfaceSelectMethod : undefined; resourceInputs["loadBalanceServers"] = args ? args.loadBalanceServers : undefined; resourceInputs["outbreakPreventionCache"] = args ? args.outbreakPreventionCache : undefined; resourceInputs["outbreakPreventionCacheMpercent"] = args ? args.outbreakPreventionCacheMpercent : undefined; resourceInputs["outbreakPreventionCacheMpermille"] = args ? args.outbreakPreventionCacheMpermille : undefined; resourceInputs["outbreakPreventionCacheTtl"] = args ? args.outbreakPreventionCacheTtl : undefined; resourceInputs["outbreakPreventionExpiration"] = args ? args.outbreakPreventionExpiration : undefined; resourceInputs["outbreakPreventionForceOff"] = args ? args.outbreakPreventionForceOff : undefined; resourceInputs["outbreakPreventionLicense"] = args ? args.outbreakPreventionLicense : undefined; resourceInputs["outbreakPreventionTimeout"] = args ? args.outbreakPreventionTimeout : undefined; resourceInputs["persistentConnection"] = args ? args.persistentConnection : undefined; resourceInputs["port"] = args ? args.port : undefined; resourceInputs["protocol"] = args ? args.protocol : undefined; resourceInputs["proxyPassword"] = (args === null || args === void 0 ? void 0 : args.proxyPassword) ? pulumi.secret(args.proxyPassword) : undefined; resourceInputs["proxyServerIp"] = args ? args.proxyServerIp : undefined; resourceInputs["proxyServerPort"] = args ? args.proxyServerPort : undefined; resourceInputs["proxyUsername"] = args ? args.proxyUsername : undefined; resourceInputs["sandboxInlineScan"] = args ? args.sandboxInlineScan : undefined; resourceInputs["sandboxRegion"] = args ? args.sandboxRegion : undefined; resourceInputs["sdnsOptions"] = args ? args.sdnsOptions : undefined; resourceInputs["sdnsServerIp"] = args ? args.sdnsServerIp : undefined; resourceInputs["sdnsServerPort"] = args ? args.sdnsServerPort : undefined; resourceInputs["serviceAccountId"] = args ? args.serviceAccountId : undefined; resourceInputs["sourceIp"] = args ? args.sourceIp : undefined; resourceInputs["sourceIp6"] = args ? args.sourceIp6 : undefined; resourceInputs["updateBuildProxy"] = args ? args.updateBuildProxy : undefined; resourceInputs["updateDldb"] = args ? args.updateDldb : undefined; resourceInputs["updateExtdb"] = args ? args.updateExtdb : undefined; resourceInputs["updateFfdb"] = args ? args.updateFfdb : undefined; resourceInputs["updateServerLocation"] = args ? args.updateServerLocation : undefined; resourceInputs["updateUwdb"] = args ? args.updateUwdb : undefined; resourceInputs["vdom"] = args ? args.vdom : undefined; resourceInputs["vdomparam"] = args ? args.vdomparam : undefined; resourceInputs["videofilterExpiration"] = args ? args.videofilterExpiration : undefined; resourceInputs["videofilterLicense"] = args ? args.videofilterLicense : undefined; resourceInputs["webfilterCache"] = args ? args.webfilterCache : undefined; resourceInputs["webfilterCacheTtl"] = args ? args.webfilterCacheTtl : undefined; resourceInputs["webfilterExpiration"] = args ? args.webfilterExpiration : undefined; resourceInputs["webfilterForceOff"] = args ? args.webfilterForceOff : undefined; resourceInputs["webfilterLicense"] = args ? args.webfilterLicense : undefined; resourceInputs["webfilterTimeout"] = args ? args.webfilterTimeout : undefined; } opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts); const secretOpts = { additionalSecretOutputs: ["proxyPassword"] }; opts = pulumi.mergeOptions(opts, secretOpts); super(Fortiguard.__pulumiType, name, resourceInputs, opts); } } exports.Fortiguard = Fortiguard; /** @internal */ Fortiguard.__pulumiType = 'fortios:system/fortiguard:Fortiguard'; //# sourceMappingURL=fortiguard.js.map