UNPKG

@pulumi/nomad

Version:

A Pulumi package for creating and managing nomad cloud resources.

85 lines 4.22 kB
"use strict"; // *** WARNING: this file was generated by pulumi-language-nodejs. *** // *** Do not edit by hand unless you're certain you know what you are doing! *** Object.defineProperty(exports, "__esModule", { value: true }); exports.DynamicHostVolume = void 0; const pulumi = require("@pulumi/pulumi"); const utilities = require("./utilities"); class DynamicHostVolume extends pulumi.CustomResource { /** * Get an existing DynamicHostVolume 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 DynamicHostVolume(name, state, { ...opts, id: id }); } /** * Returns true if the given object is an instance of DynamicHostVolume. 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'] === DynamicHostVolume.__pulumiType; } constructor(name, argsOrState, opts) { let resourceInputs = {}; opts = opts || {}; if (opts.id) { const state = argsOrState; resourceInputs["capabilities"] = state?.capabilities; resourceInputs["capacity"] = state?.capacity; resourceInputs["capacityBytes"] = state?.capacityBytes; resourceInputs["capacityMax"] = state?.capacityMax; resourceInputs["capacityMaxBytes"] = state?.capacityMaxBytes; resourceInputs["capacityMin"] = state?.capacityMin; resourceInputs["capacityMinBytes"] = state?.capacityMinBytes; resourceInputs["constraints"] = state?.constraints; resourceInputs["hostPath"] = state?.hostPath; resourceInputs["name"] = state?.name; resourceInputs["namespace"] = state?.namespace; resourceInputs["nodeId"] = state?.nodeId; resourceInputs["nodePool"] = state?.nodePool; resourceInputs["parameters"] = state?.parameters; resourceInputs["pluginId"] = state?.pluginId; resourceInputs["state"] = state?.state; } else { const args = argsOrState; if (args?.capabilities === undefined && !opts.urn) { throw new Error("Missing required property 'capabilities'"); } if (args?.pluginId === undefined && !opts.urn) { throw new Error("Missing required property 'pluginId'"); } resourceInputs["capabilities"] = args?.capabilities; resourceInputs["capacityMax"] = args?.capacityMax; resourceInputs["capacityMin"] = args?.capacityMin; resourceInputs["constraints"] = args?.constraints; resourceInputs["name"] = args?.name; resourceInputs["namespace"] = args?.namespace; resourceInputs["nodeId"] = args?.nodeId; resourceInputs["nodePool"] = args?.nodePool; resourceInputs["parameters"] = args?.parameters; resourceInputs["pluginId"] = args?.pluginId; resourceInputs["capacity"] = undefined /*out*/; resourceInputs["capacityBytes"] = undefined /*out*/; resourceInputs["capacityMaxBytes"] = undefined /*out*/; resourceInputs["capacityMinBytes"] = undefined /*out*/; resourceInputs["hostPath"] = undefined /*out*/; resourceInputs["state"] = undefined /*out*/; } opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts); super(DynamicHostVolume.__pulumiType, name, resourceInputs, opts); } } exports.DynamicHostVolume = DynamicHostVolume; /** @internal */ DynamicHostVolume.__pulumiType = 'nomad:index/dynamicHostVolume:DynamicHostVolume'; //# sourceMappingURL=dynamicHostVolume.js.map