UNPKG

@lbrlabs/pulumi-harness

Version:

A Pulumi package for creating and managing Harness resources.

77 lines 3.47 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.GitOpsRepoCert = void 0; const pulumi = require("@pulumi/pulumi"); const utilities = require("../utilities"); /** * Resource for creating a Harness Gitops Repositories Certificates. * * ## Import * * Import a Account level Gitops Repository Certificate * * ```sh * $ pulumi import harness:platform/gitOpsRepoCert:GitOpsRepoCert example <repocert_id> * ``` */ class GitOpsRepoCert extends pulumi.CustomResource { /** * Get an existing GitOpsRepoCert 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 GitOpsRepoCert(name, state, Object.assign(Object.assign({}, opts), { id: id })); } /** * Returns true if the given object is an instance of GitOpsRepoCert. 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'] === GitOpsRepoCert.__pulumiType; } constructor(name, argsOrState, opts) { let resourceInputs = {}; opts = opts || {}; if (opts.id) { const state = argsOrState; resourceInputs["accountId"] = state ? state.accountId : undefined; resourceInputs["agentId"] = state ? state.agentId : undefined; resourceInputs["orgId"] = state ? state.orgId : undefined; resourceInputs["projectId"] = state ? state.projectId : undefined; resourceInputs["requests"] = state ? state.requests : undefined; } else { const args = argsOrState; if ((!args || args.accountId === undefined) && !opts.urn) { throw new Error("Missing required property 'accountId'"); } if ((!args || args.agentId === undefined) && !opts.urn) { throw new Error("Missing required property 'agentId'"); } if ((!args || args.requests === undefined) && !opts.urn) { throw new Error("Missing required property 'requests'"); } resourceInputs["accountId"] = args ? args.accountId : undefined; resourceInputs["agentId"] = args ? args.agentId : undefined; resourceInputs["orgId"] = args ? args.orgId : undefined; resourceInputs["projectId"] = args ? args.projectId : undefined; resourceInputs["requests"] = args ? args.requests : undefined; } opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts); super(GitOpsRepoCert.__pulumiType, name, resourceInputs, opts); } } exports.GitOpsRepoCert = GitOpsRepoCert; /** @internal */ GitOpsRepoCert.__pulumiType = 'harness:platform/gitOpsRepoCert:GitOpsRepoCert'; //# sourceMappingURL=gitOpsRepoCert.js.map