UNPKG

@pulumi/harness

Version:

A Pulumi package for creating and managing Harness resources.

100 lines 3.11 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.getTemplateOutput = exports.getTemplate = void 0; const pulumi = require("@pulumi/pulumi"); const utilities = require("../utilities"); /** * Data source for retrieving a Harness pipeline. * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as harness from "@pulumi/harness"; * * //For account level template * const example = harness.platform.getTemplate({ * identifier: "identifier", * version: "version", * }); * //For org level template * const example1 = harness.platform.getTemplate({ * identifier: "identifier", * version: "version", * orgId: "org_id", * }); * //For project level template * const example2 = harness.platform.getTemplate({ * identifier: "identifier", * version: "version", * orgId: "org_id", * projectId: "project_id", * }); * ``` */ function getTemplate(args, opts) { args = args || {}; opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invoke("harness:platform/getTemplate:getTemplate", { "branchName": args.branchName, "childType": args.childType, "gitDetails": args.gitDetails, "identifier": args.identifier, "isStable": args.isStable, "name": args.name, "orgId": args.orgId, "projectId": args.projectId, "scope": args.scope, "version": args.version, }, opts); } exports.getTemplate = getTemplate; /** * Data source for retrieving a Harness pipeline. * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as harness from "@pulumi/harness"; * * //For account level template * const example = harness.platform.getTemplate({ * identifier: "identifier", * version: "version", * }); * //For org level template * const example1 = harness.platform.getTemplate({ * identifier: "identifier", * version: "version", * orgId: "org_id", * }); * //For project level template * const example2 = harness.platform.getTemplate({ * identifier: "identifier", * version: "version", * orgId: "org_id", * projectId: "project_id", * }); * ``` */ function getTemplateOutput(args, opts) { args = args || {}; opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invokeOutput("harness:platform/getTemplate:getTemplate", { "branchName": args.branchName, "childType": args.childType, "gitDetails": args.gitDetails, "identifier": args.identifier, "isStable": args.isStable, "name": args.name, "orgId": args.orgId, "projectId": args.projectId, "scope": args.scope, "version": args.version, }, opts); } exports.getTemplateOutput = getTemplateOutput; //# sourceMappingURL=getTemplate.js.map