Provides access to available Google Compute Storage Pool resources for a given project and zone. See more about Hyperdisk Storage Pools in the upstream docs.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as gcp from "@pulumi/gcp";
const myPool = gcp.compute.getStoragePool({
name: "my-storage-pool",
zone: "us-central1-a",
});
export const poolCapacity = myPool.then(myPool => myPool.poolProvisionedCapacityGb);
export const poolType = myPool.then(myPool => myPool.storagePoolType);
import pulumi
import pulumi_gcp as gcp
my_pool = gcp.compute.get_storage_pool(name="my-storage-pool",
zone="us-central1-a")
pulumi.export("poolCapacity", my_pool.pool_provisioned_capacity_gb)
pulumi.export("poolType", my_pool.storage_pool_type)
package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v9/go/gcp/compute"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
myPool, err := compute.LookupStoragePool(ctx, &compute.LookupStoragePoolArgs{
Name: "my-storage-pool",
Zone: "us-central1-a",
}, nil)
if err != nil {
return err
}
ctx.Export("poolCapacity", myPool.PoolProvisionedCapacityGb)
ctx.Export("poolType", myPool.StoragePoolType)
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Gcp = Pulumi.Gcp;
return await Deployment.RunAsync(() =>
{
var myPool = Gcp.Compute.GetStoragePool.Invoke(new()
{
Name = "my-storage-pool",
Zone = "us-central1-a",
});
return new Dictionary<string, object?>
{
["poolCapacity"] = myPool.Apply(getStoragePoolResult => getStoragePoolResult.PoolProvisionedCapacityGb),
["poolType"] = myPool.Apply(getStoragePoolResult => getStoragePoolResult.StoragePoolType),
};
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.gcp.compute.ComputeFunctions;
import com.pulumi.gcp.compute.inputs.GetStoragePoolArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
final var myPool = ComputeFunctions.getStoragePool(GetStoragePoolArgs.builder()
.name("my-storage-pool")
.zone("us-central1-a")
.build());
ctx.export("poolCapacity", myPool.poolProvisionedCapacityGb());
ctx.export("poolType", myPool.storagePoolType());
}
}
variables:
myPool:
fn::invoke:
function: gcp:compute:getStoragePool
arguments:
name: my-storage-pool
zone: us-central1-a
outputs:
poolCapacity: ${myPool.poolProvisionedCapacityGb}
poolType: ${myPool.storagePoolType}
Note
deletion_protectionis always set to false on the data source and will not be represetative of the actual value ongcp.compute.StoragePoolreaosure being read
Using getStoragePool
Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.
function getStoragePool(args: GetStoragePoolArgs, opts?: InvokeOptions): Promise<GetStoragePoolResult>
function getStoragePoolOutput(args: GetStoragePoolOutputArgs, opts?: InvokeOptions): Output<GetStoragePoolResult>def get_storage_pool(name: Optional[str] = None,
project: Optional[str] = None,
zone: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetStoragePoolResult
def get_storage_pool_output(name: Optional[pulumi.Input[str]] = None,
project: Optional[pulumi.Input[str]] = None,
zone: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetStoragePoolResult]func LookupStoragePool(ctx *Context, args *LookupStoragePoolArgs, opts ...InvokeOption) (*LookupStoragePoolResult, error)
func LookupStoragePoolOutput(ctx *Context, args *LookupStoragePoolOutputArgs, opts ...InvokeOption) LookupStoragePoolResultOutput> Note: This function is named LookupStoragePool in the Go SDK.
public static class GetStoragePool
{
public static Task<GetStoragePoolResult> InvokeAsync(GetStoragePoolArgs args, InvokeOptions? opts = null)
public static Output<GetStoragePoolResult> Invoke(GetStoragePoolInvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<GetStoragePoolResult> getStoragePool(GetStoragePoolArgs args, InvokeOptions options)
public static Output<GetStoragePoolResult> getStoragePool(GetStoragePoolArgs args, InvokeOptions options)
fn::invoke:
function: gcp:compute/getStoragePool:getStoragePool
arguments:
# arguments dictionaryThe following arguments are supported:
getStoragePool Result
The following output properties are available:
- Capacity
Provisioning stringType - Creation
Timestamp string - Deletion
Protection bool - Description string
- Effective
Labels Dictionary<string, string> - Id string
- Kind string
- Label
Fingerprint string - Labels Dictionary<string, string>
- Name string
- Performance
Provisioning stringType - Pool
Provisioned stringCapacity Gb - Pool
Provisioned stringIops - Pool
Provisioned stringThroughput - Pulumi
Labels Dictionary<string, string> - Resource
Statuses List<GetStorage Pool Resource Status> - Statuses
List<Get
Storage Pool Status> - Storage
Pool stringType - Zone string
- Project string
- Capacity
Provisioning stringType - Creation
Timestamp string - Deletion
Protection bool - Description string
- Effective
Labels map[string]string - Id string
- Kind string
- Label
Fingerprint string - Labels map[string]string
- Name string
- Performance
Provisioning stringType - Pool
Provisioned stringCapacity Gb - Pool
Provisioned stringIops - Pool
Provisioned stringThroughput - Pulumi
Labels map[string]string - Resource
Statuses []GetStorage Pool Resource Status - Statuses
[]Get
Storage Pool Status - Storage
Pool stringType - Zone string
- Project string
- capacity
Provisioning StringType - creation
Timestamp String - deletion
Protection Boolean - description String
- effective
Labels Map<String,String> - id String
- kind String
- label
Fingerprint String - labels Map<String,String>
- name String
- performance
Provisioning StringType - pool
Provisioned StringCapacity Gb - pool
Provisioned StringIops - pool
Provisioned StringThroughput - pulumi
Labels Map<String,String> - resource
Statuses List<GetStorage Pool Resource Status> - statuses
List<Get
Storage Pool Status> - storage
Pool StringType - zone String
- project String
- capacity
Provisioning stringType - creation
Timestamp string - deletion
Protection boolean - description string
- effective
Labels {[key: string]: string} - id string
- kind string
- label
Fingerprint string - labels {[key: string]: string}
- name string
- performance
Provisioning stringType - pool
Provisioned stringCapacity Gb - pool
Provisioned stringIops - pool
Provisioned stringThroughput - pulumi
Labels {[key: string]: string} - resource
Statuses GetStorage Pool Resource Status[] - statuses
Get
Storage Pool Status[] - storage
Pool stringType - zone string
- project string
- capacity_
provisioning_ strtype - creation_
timestamp str - deletion_
protection bool - description str
- effective_
labels Mapping[str, str] - id str
- kind str
- label_
fingerprint str - labels Mapping[str, str]
- name str
- performance_
provisioning_ strtype - pool_
provisioned_ strcapacity_ gb - pool_
provisioned_ striops - pool_
provisioned_ strthroughput - pulumi_
labels Mapping[str, str] - resource_
statuses Sequence[GetStorage Pool Resource Status] - statuses
Sequence[Get
Storage Pool Status] - storage_
pool_ strtype - zone str
- project str
- capacity
Provisioning StringType - creation
Timestamp String - deletion
Protection Boolean - description String
- effective
Labels Map<String> - id String
- kind String
- label
Fingerprint String - labels Map<String>
- name String
- performance
Provisioning StringType - pool
Provisioned StringCapacity Gb - pool
Provisioned StringIops - pool
Provisioned StringThroughput - pulumi
Labels Map<String> - resource
Statuses List<Property Map> - statuses List<Property Map>
- storage
Pool StringType - zone String
- project String
Supporting Types
GetStoragePoolResourceStatus
- Disk
Count string - Number of disks used.
- Last
Resize stringTimestamp - Timestamp of the last successful resize in RFC3339 text format.
- Max
Total stringProvisioned Disk Capacity Gb - Maximum allowed aggregate disk size in gigabytes.
- Pool
Used stringCapacity Bytes - Space used by data stored in disks within the storage pool (in bytes). This will reflect the total number of bytes written to the disks in the pool, in contrast to the capacity of those disks.
- Pool
Used stringIops - Sum of all the disks' provisioned IOPS, minus some amount that is allowed per disk that is not counted towards pool's IOPS capacity. For more information, see https://cloud.google.com/compute/docs/disks/storage-pools.
- Pool
Used stringThroughput - Sum of all the disks' provisioned throughput in MB/s.
- Pool
User stringWritten Bytes - Amount of data written into the pool, before it is compacted.
- Total
Provisioned stringDisk Capacity Gb - Sum of all the capacity provisioned in disks in this storage pool. A disk's provisioned capacity is the same as its total capacity.
- Total
Provisioned stringDisk Iops - Sum of all the disks' provisioned IOPS.
- Total
Provisioned stringDisk Throughput - Sum of all the disks' provisioned throughput in MB/s, minus some amount that is allowed per disk that is not counted towards pool's throughput capacity.
- Disk
Count string - Number of disks used.
- Last
Resize stringTimestamp - Timestamp of the last successful resize in RFC3339 text format.
- Max
Total stringProvisioned Disk Capacity Gb - Maximum allowed aggregate disk size in gigabytes.
- Pool
Used stringCapacity Bytes - Space used by data stored in disks within the storage pool (in bytes). This will reflect the total number of bytes written to the disks in the pool, in contrast to the capacity of those disks.
- Pool
Used stringIops - Sum of all the disks' provisioned IOPS, minus some amount that is allowed per disk that is not counted towards pool's IOPS capacity. For more information, see https://cloud.google.com/compute/docs/disks/storage-pools.
- Pool
Used stringThroughput - Sum of all the disks' provisioned throughput in MB/s.
- Pool
User stringWritten Bytes - Amount of data written into the pool, before it is compacted.
- Total
Provisioned stringDisk Capacity Gb - Sum of all the capacity provisioned in disks in this storage pool. A disk's provisioned capacity is the same as its total capacity.
- Total
Provisioned stringDisk Iops - Sum of all the disks' provisioned IOPS.
- Total
Provisioned stringDisk Throughput - Sum of all the disks' provisioned throughput in MB/s, minus some amount that is allowed per disk that is not counted towards pool's throughput capacity.
- disk
Count String - Number of disks used.
- last
Resize StringTimestamp - Timestamp of the last successful resize in RFC3339 text format.
- max
Total StringProvisioned Disk Capacity Gb - Maximum allowed aggregate disk size in gigabytes.
- pool
Used StringCapacity Bytes - Space used by data stored in disks within the storage pool (in bytes). This will reflect the total number of bytes written to the disks in the pool, in contrast to the capacity of those disks.
- pool
Used StringIops - Sum of all the disks' provisioned IOPS, minus some amount that is allowed per disk that is not counted towards pool's IOPS capacity. For more information, see https://cloud.google.com/compute/docs/disks/storage-pools.
- pool
Used StringThroughput - Sum of all the disks' provisioned throughput in MB/s.
- pool
User StringWritten Bytes - Amount of data written into the pool, before it is compacted.
- total
Provisioned StringDisk Capacity Gb - Sum of all the capacity provisioned in disks in this storage pool. A disk's provisioned capacity is the same as its total capacity.
- total
Provisioned StringDisk Iops - Sum of all the disks' provisioned IOPS.
- total
Provisioned StringDisk Throughput - Sum of all the disks' provisioned throughput in MB/s, minus some amount that is allowed per disk that is not counted towards pool's throughput capacity.
- disk
Count string - Number of disks used.
- last
Resize stringTimestamp - Timestamp of the last successful resize in RFC3339 text format.
- max
Total stringProvisioned Disk Capacity Gb - Maximum allowed aggregate disk size in gigabytes.
- pool
Used stringCapacity Bytes - Space used by data stored in disks within the storage pool (in bytes). This will reflect the total number of bytes written to the disks in the pool, in contrast to the capacity of those disks.
- pool
Used stringIops - Sum of all the disks' provisioned IOPS, minus some amount that is allowed per disk that is not counted towards pool's IOPS capacity. For more information, see https://cloud.google.com/compute/docs/disks/storage-pools.
- pool
Used stringThroughput - Sum of all the disks' provisioned throughput in MB/s.
- pool
User stringWritten Bytes - Amount of data written into the pool, before it is compacted.
- total
Provisioned stringDisk Capacity Gb - Sum of all the capacity provisioned in disks in this storage pool. A disk's provisioned capacity is the same as its total capacity.
- total
Provisioned stringDisk Iops - Sum of all the disks' provisioned IOPS.
- total
Provisioned stringDisk Throughput - Sum of all the disks' provisioned throughput in MB/s, minus some amount that is allowed per disk that is not counted towards pool's throughput capacity.
- disk_
count str - Number of disks used.
- last_
resize_ strtimestamp - Timestamp of the last successful resize in RFC3339 text format.
- max_
total_ strprovisioned_ disk_ capacity_ gb - Maximum allowed aggregate disk size in gigabytes.
- pool_
used_ strcapacity_ bytes - Space used by data stored in disks within the storage pool (in bytes). This will reflect the total number of bytes written to the disks in the pool, in contrast to the capacity of those disks.
- pool_
used_ striops - Sum of all the disks' provisioned IOPS, minus some amount that is allowed per disk that is not counted towards pool's IOPS capacity. For more information, see https://cloud.google.com/compute/docs/disks/storage-pools.
- pool_
used_ strthroughput - Sum of all the disks' provisioned throughput in MB/s.
- pool_
user_ strwritten_ bytes - Amount of data written into the pool, before it is compacted.
- total_
provisioned_ strdisk_ capacity_ gb - Sum of all the capacity provisioned in disks in this storage pool. A disk's provisioned capacity is the same as its total capacity.
- total_
provisioned_ strdisk_ iops - Sum of all the disks' provisioned IOPS.
- total_
provisioned_ strdisk_ throughput - Sum of all the disks' provisioned throughput in MB/s, minus some amount that is allowed per disk that is not counted towards pool's throughput capacity.
- disk
Count String - Number of disks used.
- last
Resize StringTimestamp - Timestamp of the last successful resize in RFC3339 text format.
- max
Total StringProvisioned Disk Capacity Gb - Maximum allowed aggregate disk size in gigabytes.
- pool
Used StringCapacity Bytes - Space used by data stored in disks within the storage pool (in bytes). This will reflect the total number of bytes written to the disks in the pool, in contrast to the capacity of those disks.
- pool
Used StringIops - Sum of all the disks' provisioned IOPS, minus some amount that is allowed per disk that is not counted towards pool's IOPS capacity. For more information, see https://cloud.google.com/compute/docs/disks/storage-pools.
- pool
Used StringThroughput - Sum of all the disks' provisioned throughput in MB/s.
- pool
User StringWritten Bytes - Amount of data written into the pool, before it is compacted.
- total
Provisioned StringDisk Capacity Gb - Sum of all the capacity provisioned in disks in this storage pool. A disk's provisioned capacity is the same as its total capacity.
- total
Provisioned StringDisk Iops - Sum of all the disks' provisioned IOPS.
- total
Provisioned StringDisk Throughput - Sum of all the disks' provisioned throughput in MB/s, minus some amount that is allowed per disk that is not counted towards pool's throughput capacity.
GetStoragePoolStatus
- Disk
Count string - Number of disks used.
- Last
Resize stringTimestamp - Timestamp of the last successful resize in RFC3339 text format.
- Max
Total stringProvisioned Disk Capacity Gb - Maximum allowed aggregate disk size in gigabytes.
- Pool
Used stringCapacity Bytes - Space used by data stored in disks within the storage pool (in bytes). This will reflect the total number of bytes written to the disks in the pool, in contrast to the capacity of those disks.
- Pool
Used stringIops - Sum of all the disks' provisioned IOPS, minus some amount that is allowed per disk that is not counted towards pool's IOPS capacity. For more information, see https://cloud.google.com/compute/docs/disks/storage-pools.
- Pool
Used stringThroughput - Sum of all the disks' provisioned throughput in MB/s.
- Pool
User stringWritten Bytes - Amount of data written into the pool, before it is compacted.
- Total
Provisioned stringDisk Capacity Gb - Sum of all the capacity provisioned in disks in this storage pool. A disk's provisioned capacity is the same as its total capacity.
- Total
Provisioned stringDisk Iops - Sum of all the disks' provisioned IOPS.
- Total
Provisioned stringDisk Throughput - Sum of all the disks' provisioned throughput in MB/s, minus some amount that is allowed per disk that is not counted towards pool's throughput capacity.
- Disk
Count string - Number of disks used.
- Last
Resize stringTimestamp - Timestamp of the last successful resize in RFC3339 text format.
- Max
Total stringProvisioned Disk Capacity Gb - Maximum allowed aggregate disk size in gigabytes.
- Pool
Used stringCapacity Bytes - Space used by data stored in disks within the storage pool (in bytes). This will reflect the total number of bytes written to the disks in the pool, in contrast to the capacity of those disks.
- Pool
Used stringIops - Sum of all the disks' provisioned IOPS, minus some amount that is allowed per disk that is not counted towards pool's IOPS capacity. For more information, see https://cloud.google.com/compute/docs/disks/storage-pools.
- Pool
Used stringThroughput - Sum of all the disks' provisioned throughput in MB/s.
- Pool
User stringWritten Bytes - Amount of data written into the pool, before it is compacted.
- Total
Provisioned stringDisk Capacity Gb - Sum of all the capacity provisioned in disks in this storage pool. A disk's provisioned capacity is the same as its total capacity.
- Total
Provisioned stringDisk Iops - Sum of all the disks' provisioned IOPS.
- Total
Provisioned stringDisk Throughput - Sum of all the disks' provisioned throughput in MB/s, minus some amount that is allowed per disk that is not counted towards pool's throughput capacity.
- disk
Count String - Number of disks used.
- last
Resize StringTimestamp - Timestamp of the last successful resize in RFC3339 text format.
- max
Total StringProvisioned Disk Capacity Gb - Maximum allowed aggregate disk size in gigabytes.
- pool
Used StringCapacity Bytes - Space used by data stored in disks within the storage pool (in bytes). This will reflect the total number of bytes written to the disks in the pool, in contrast to the capacity of those disks.
- pool
Used StringIops - Sum of all the disks' provisioned IOPS, minus some amount that is allowed per disk that is not counted towards pool's IOPS capacity. For more information, see https://cloud.google.com/compute/docs/disks/storage-pools.
- pool
Used StringThroughput - Sum of all the disks' provisioned throughput in MB/s.
- pool
User StringWritten Bytes - Amount of data written into the pool, before it is compacted.
- total
Provisioned StringDisk Capacity Gb - Sum of all the capacity provisioned in disks in this storage pool. A disk's provisioned capacity is the same as its total capacity.
- total
Provisioned StringDisk Iops - Sum of all the disks' provisioned IOPS.
- total
Provisioned StringDisk Throughput - Sum of all the disks' provisioned throughput in MB/s, minus some amount that is allowed per disk that is not counted towards pool's throughput capacity.
- disk
Count string - Number of disks used.
- last
Resize stringTimestamp - Timestamp of the last successful resize in RFC3339 text format.
- max
Total stringProvisioned Disk Capacity Gb - Maximum allowed aggregate disk size in gigabytes.
- pool
Used stringCapacity Bytes - Space used by data stored in disks within the storage pool (in bytes). This will reflect the total number of bytes written to the disks in the pool, in contrast to the capacity of those disks.
- pool
Used stringIops - Sum of all the disks' provisioned IOPS, minus some amount that is allowed per disk that is not counted towards pool's IOPS capacity. For more information, see https://cloud.google.com/compute/docs/disks/storage-pools.
- pool
Used stringThroughput - Sum of all the disks' provisioned throughput in MB/s.
- pool
User stringWritten Bytes - Amount of data written into the pool, before it is compacted.
- total
Provisioned stringDisk Capacity Gb - Sum of all the capacity provisioned in disks in this storage pool. A disk's provisioned capacity is the same as its total capacity.
- total
Provisioned stringDisk Iops - Sum of all the disks' provisioned IOPS.
- total
Provisioned stringDisk Throughput - Sum of all the disks' provisioned throughput in MB/s, minus some amount that is allowed per disk that is not counted towards pool's throughput capacity.
- disk_
count str - Number of disks used.
- last_
resize_ strtimestamp - Timestamp of the last successful resize in RFC3339 text format.
- max_
total_ strprovisioned_ disk_ capacity_ gb - Maximum allowed aggregate disk size in gigabytes.
- pool_
used_ strcapacity_ bytes - Space used by data stored in disks within the storage pool (in bytes). This will reflect the total number of bytes written to the disks in the pool, in contrast to the capacity of those disks.
- pool_
used_ striops - Sum of all the disks' provisioned IOPS, minus some amount that is allowed per disk that is not counted towards pool's IOPS capacity. For more information, see https://cloud.google.com/compute/docs/disks/storage-pools.
- pool_
used_ strthroughput - Sum of all the disks' provisioned throughput in MB/s.
- pool_
user_ strwritten_ bytes - Amount of data written into the pool, before it is compacted.
- total_
provisioned_ strdisk_ capacity_ gb - Sum of all the capacity provisioned in disks in this storage pool. A disk's provisioned capacity is the same as its total capacity.
- total_
provisioned_ strdisk_ iops - Sum of all the disks' provisioned IOPS.
- total_
provisioned_ strdisk_ throughput - Sum of all the disks' provisioned throughput in MB/s, minus some amount that is allowed per disk that is not counted towards pool's throughput capacity.
- disk
Count String - Number of disks used.
- last
Resize StringTimestamp - Timestamp of the last successful resize in RFC3339 text format.
- max
Total StringProvisioned Disk Capacity Gb - Maximum allowed aggregate disk size in gigabytes.
- pool
Used StringCapacity Bytes - Space used by data stored in disks within the storage pool (in bytes). This will reflect the total number of bytes written to the disks in the pool, in contrast to the capacity of those disks.
- pool
Used StringIops - Sum of all the disks' provisioned IOPS, minus some amount that is allowed per disk that is not counted towards pool's IOPS capacity. For more information, see https://cloud.google.com/compute/docs/disks/storage-pools.
- pool
Used StringThroughput - Sum of all the disks' provisioned throughput in MB/s.
- pool
User StringWritten Bytes - Amount of data written into the pool, before it is compacted.
- total
Provisioned StringDisk Capacity Gb - Sum of all the capacity provisioned in disks in this storage pool. A disk's provisioned capacity is the same as its total capacity.
- total
Provisioned StringDisk Iops - Sum of all the disks' provisioned IOPS.
- total
Provisioned StringDisk Throughput - Sum of all the disks' provisioned throughput in MB/s, minus some amount that is allowed per disk that is not counted towards pool's throughput capacity.
Package Details
- Repository
- Google Cloud (GCP) Classic pulumi/pulumi-gcp
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
google-betaTerraform Provider.
