Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
101 changes: 101 additions & 0 deletions mmv1/products/netapp/Trial.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,101 @@
# Copyright 2026 Google Inc.
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

---
name: Trial
description: "A 30-day free trial for Google Cloud NetApp Volumes.\nIt is global in scope for a project but requires to be created in a valid cloud region in which Google Cloud NetApp Volumes is available.\n\n**Note:** Modifying the `location` of this resource will cause Terraform to destroy and recreate the trial. \nBecause Google Cloud enforces a limit of one free trial per project every 12 months, this recreation will fail. \nIt is highly recommended to use the `lifecycle { prevent_destroy = true }` block on this resource.\n"
references:
guides:
GCNV Documentation: https://cloud.google.com/netapp/volumes/docs
api: https://cloud.google.com/netapp/volumes/docs/reference/rest/v1beta1/projects.locations/trial
base_url: projects/{{project}}/locations/{{location}}/trial
self_link: projects/{{project}}/locations/{{location}}/trial
create_url: projects/{{project}}/locations/{{location}}/trial:subscribe
delete_url: projects/{{project}}/locations/{{location}}/trial:end
delete_verb: POST
id_format: projects/{{project}}/locations/{{location}}/trial
import_format:
- projects/{{project}}/locations/{{location}}/trial
timeouts:
insert_minutes: 20
delete_minutes: 20
exclude_sweeper: true
async:
type: OpAsync
operation:
base_url: '{{op_id}}'
actions: [create, delete]
result:
resource_inside_response: false
autogen_async: true
exclude_tgc: true
custom_code:
pre_delete: templates/terraform/pre_delete/netapp_trial.go.tmpl
examples:
- name: netapp_trial
primary_resource_id: default
parameters:
- name: location
type: String
description: |
Name of the location.
url_param_only: true
required: true
immutable: true
properties:
- name: name
type: String
description: |
The resource name of the trial.
Format: projects/{project}/locations/{location}/trial
output: true
- name: startTime
type: Time
description: |
The time when the trial started.
output: true
- name: endTime
type: Time
description: |
The time when the trial ends.
output: true
- name: state
type: Enum
description: |
The state of the trial.
Possible values are: `STATE_UNSPECIFIED`, `ACTIVE`, `INACTIVE`, `ELIGIBLE`, `INELIGIBLE`.
output: true
enum_values:
- STATE_UNSPECIFIED
- ACTIVE
- INACTIVE
- ELIGIBLE
- INELIGIBLE
- name: exitReason
type: Enum
description: |
The reason for exiting the trial.
Possible values are: `EXIT_REASON_UNSPECIFIED`, `EXPIRED`, `UPGRADED`, `OPT_OUT`.
output: true
enum_values:
- EXIT_REASON_UNSPECIFIED
- EXPIRED
- UPGRADED
- OPT_OUT
- name: optOutReasons
type: Array
item_type:
type: String
description: |
Contains the reasons for opting out of the free trial if exit reason is OPT_OUT.
output: true
10 changes: 10 additions & 0 deletions mmv1/templates/terraform/examples/netapp_trial.tf.tmpl
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
resource "google_netapp_trial" "{{$.PrimaryResourceId}}" {
location = "us-central1"

# It is highly recommended to include this lifecycle block.
# Modifying the location will cause Terraform to destroy and recreate the trial,
# but Google Cloud strictly enforces a limit of one trial per project every 12 months.
lifecycle {
prevent_destroy = true
}
}
4 changes: 4 additions & 0 deletions mmv1/templates/terraform/pre_delete/netapp_trial.go.tmpl
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
if obj == nil {
obj = make(map[string]interface{})
}
obj["exitReason"] = "OPT_OUT"