google_netapp_storage_pool

Storage pools act as containers for volumes. All volumes in a storage pool share the following information:

The capacity of the pool can be split up and assigned to volumes within the pool. Storage pools are a billable component of NetApp Volumes. Billing is based on the location, service level, and capacity allocated to a pool independent of consumption at the volume level.

To get more information about storagePool, see:

Open in Cloud Shell

Example Usage - Storage Pool Create

# Create a network or use datasource to reference existing network
resource "google_compute_network" "peering_network" {
  name = "test-network"
}

# Reserve a CIDR for NetApp Volumes to use
# When using shared-VPCs, this resource needs to be created in host project
resource "google_compute_global_address" "private_ip_alloc" {
  name          = "test-address"
  purpose       = "VPC_PEERING"
  address_type  = "INTERNAL"
  prefix_length = 16
  network       = google_compute_network.peering_network.id
}

# Create a Private Service Access connection
# When using shared-VPCs, this resource needs to be created in host project
resource "google_service_networking_connection" "default" {
  network                 = google_compute_network.peering_network.id
  service                 = "netapp.servicenetworking.goog"
  reserved_peering_ranges = [google_compute_global_address.private_ip_alloc.name]
}

# Modify the PSA Connection to allow import/export of custom routes
# When using shared-VPCs, this resource needs to be created in host project
resource "google_compute_network_peering_routes_config" "route_updates" {
  peering = google_service_networking_connection.default.peering
  network = google_compute_network.peering_network.name

  import_custom_routes = true
  export_custom_routes = true
}

# Create a storage pool
# Create this resource in the project which is expected to own the volumes
resource "google_netapp_storage_pool" "test_pool" {
  name = "test-pool"
  # project = <your_project>
  location = "us-central1"
  service_level = "PREMIUM"
  capacity_gib = "2048"
  network = google_compute_network.peering_network.id
}

Argument Reference

The following arguments are supported:


Attributes Reference

In addition to the arguments listed above, the following computed attributes are exported:

Timeouts

This resource provides the following Timeouts configuration options:

Import

storagePool can be imported using any of these accepted formats:

In Terraform v1.5.0 and later, use an import block to import storagePool using one of the formats above. For example:

import {
  id = "projects/{{project}}/locations/{{location}}/storagePools/{{name}}"
  to = google_netapp_storage_pool.default
}

When using the terraform import command, storagePool can be imported using one of the formats above. For example:

$ terraform import google_netapp_storage_pool.default projects/{{project}}/locations/{{location}}/storagePools/{{name}}
$ terraform import google_netapp_storage_pool.default {{project}}/{{location}}/{{name}}
$ terraform import google_netapp_storage_pool.default {{location}}/{{name}}

User Project Overrides

This resource supports User Project Overrides.