UNPKG

@pulumiverse/cpln

Version:

A Pulumi package for creating and managing Control Plane (cpln) resources.

97 lines 4.75 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.Workload = void 0; const pulumi = require("@pulumi/pulumi"); const utilities = require("./utilities"); class Workload extends pulumi.CustomResource { /** * Get an existing Workload 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 Workload(name, state, { ...opts, id: id }); } /** * Returns true if the given object is an instance of Workload. 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'] === Workload.__pulumiType; } constructor(name, argsOrState, opts) { let resourceInputs = {}; opts = opts || {}; if (opts.id) { const state = argsOrState; resourceInputs["containers"] = state?.containers; resourceInputs["cplnId"] = state?.cplnId; resourceInputs["description"] = state?.description; resourceInputs["extras"] = state?.extras; resourceInputs["firewallSpec"] = state?.firewallSpec; resourceInputs["gvc"] = state?.gvc; resourceInputs["identityLink"] = state?.identityLink; resourceInputs["jobs"] = state?.jobs; resourceInputs["loadBalancer"] = state?.loadBalancer; resourceInputs["localOptions"] = state?.localOptions; resourceInputs["name"] = state?.name; resourceInputs["options"] = state?.options; resourceInputs["requestRetryPolicy"] = state?.requestRetryPolicy; resourceInputs["rolloutOptions"] = state?.rolloutOptions; resourceInputs["securityOptions"] = state?.securityOptions; resourceInputs["selfLink"] = state?.selfLink; resourceInputs["sidecar"] = state?.sidecar; resourceInputs["statuses"] = state?.statuses; resourceInputs["supportDynamicTags"] = state?.supportDynamicTags; resourceInputs["tags"] = state?.tags; resourceInputs["type"] = state?.type; resourceInputs["vm"] = state?.vm; } else { const args = argsOrState; if (args?.gvc === undefined && !opts.urn) { throw new Error("Missing required property 'gvc'"); } if (args?.type === undefined && !opts.urn) { throw new Error("Missing required property 'type'"); } resourceInputs["containers"] = args?.containers; resourceInputs["description"] = args?.description; resourceInputs["extras"] = args?.extras; resourceInputs["firewallSpec"] = args?.firewallSpec; resourceInputs["gvc"] = args?.gvc; resourceInputs["identityLink"] = args?.identityLink; resourceInputs["jobs"] = args?.jobs; resourceInputs["loadBalancer"] = args?.loadBalancer; resourceInputs["localOptions"] = args?.localOptions; resourceInputs["name"] = args?.name; resourceInputs["options"] = args?.options; resourceInputs["requestRetryPolicy"] = args?.requestRetryPolicy; resourceInputs["rolloutOptions"] = args?.rolloutOptions; resourceInputs["securityOptions"] = args?.securityOptions; resourceInputs["sidecar"] = args?.sidecar; resourceInputs["supportDynamicTags"] = args?.supportDynamicTags; resourceInputs["tags"] = args?.tags; resourceInputs["type"] = args?.type; resourceInputs["vm"] = args?.vm; resourceInputs["cplnId"] = undefined /*out*/; resourceInputs["selfLink"] = undefined /*out*/; resourceInputs["statuses"] = undefined /*out*/; } opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts); super(Workload.__pulumiType, name, resourceInputs, opts); } } exports.Workload = Workload; /** @internal */ Workload.__pulumiType = 'cpln:index/workload:Workload'; //# sourceMappingURL=workload.js.map