UNPKG

@pulumi/gcp

Version:

A Pulumi package for creating and managing Google Cloud Platform resources.

68 lines 2.43 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.getDiskOutput = exports.getDisk = void 0; const pulumi = require("@pulumi/pulumi"); const utilities = require("../utilities"); /** * Get information about a Google Compute Persistent disks. * * [the official documentation](https://cloud.google.com/compute/docs/disks) and its [API](https://cloud.google.com/compute/docs/reference/latest/disks). * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as gcp from "@pulumi/gcp"; * * const persistent_boot_disk = gcp.compute.getDisk({ * name: "persistent-boot-disk", * project: "example", * }); * const _default = new gcp.compute.Instance("default", {bootDisk: { * source: persistent_boot_disk.then(persistent_boot_disk => persistent_boot_disk.selfLink), * autoDelete: false, * }}); * ``` */ function getDisk(args, opts) { opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invoke("gcp:compute/getDisk:getDisk", { "name": args.name, "project": args.project, "zone": args.zone, }, opts); } exports.getDisk = getDisk; /** * Get information about a Google Compute Persistent disks. * * [the official documentation](https://cloud.google.com/compute/docs/disks) and its [API](https://cloud.google.com/compute/docs/reference/latest/disks). * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as gcp from "@pulumi/gcp"; * * const persistent_boot_disk = gcp.compute.getDisk({ * name: "persistent-boot-disk", * project: "example", * }); * const _default = new gcp.compute.Instance("default", {bootDisk: { * source: persistent_boot_disk.then(persistent_boot_disk => persistent_boot_disk.selfLink), * autoDelete: false, * }}); * ``` */ function getDiskOutput(args, opts) { opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invokeOutput("gcp:compute/getDisk:getDisk", { "name": args.name, "project": args.project, "zone": args.zone, }, opts); } exports.getDiskOutput = getDiskOutput; //# sourceMappingURL=getDisk.js.map