powerscale_cluster_snmp (Resource)
This resource is used to manage the Cluster SNMP settings of PowerScale Array. We can Create, Update and Delete the Cluster SNMP using this resource. We can also import the existing Cluster SNMP settings from PowerScale array.
Example Usage
/*
Copyright (c) 2024 Dell Inc., or its subsidiaries. All Rights Reserved.
Licensed under the Mozilla Public 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://mozilla.org/MPL/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.
*/
# Available actions: Create, Update, Delete and Import.
# If resource arguments are omitted, `terraform apply` will load Cluster SNMP Settings from PowerScale, and save to terraform state file.
# If any resource arguments are specified, `terraform apply` will try to load CLuster SNMP Settings (if not loaded) and update the settings.
# `terraform destroy` will delete the resource from terraform state file rather than deleting SNMP Settings from PowerScale.
# For more information, Please check the terraform state file.
# PowerScale Cluster SNMP Settings allow you to change the settings of SNMP
resource "powerscale_cluster_snmp" "example_snmp_settings" {
# Required field
enabled = true //enables/disables cluster SNMP Settings
# Optional fields both for creating and updating
# read_only_community ="Public"
# snmp_v1_v2c_access = true
# snmp_v3_auth_protocol = "SHA"
}
# After the execution of above resource block, Cluster SNMP Settings would have been cached in terraform state file, or
# SNMP Settings would have been updated on PowerScale.
# For more information, Please check the terraform state file.
Schema
Required
enabled
(Boolean) True if the Cluster SNMP is enabled. If true, eithersnmp_v1v2_access
orsnmp_v3_access
is required.
Optional
read_only_community
(String) The read-only community string for the Cluster SNMP.snmp_v1_v2c_access
(Boolean) The SNMPv1/v2c access for the Cluster SNMP. Also requiresread_only_community
.snmp_v3_access
(Boolean) The SNMPv3 access for the Cluster SNMP. Also requires snmp_v3_password.snmp_v3_auth_protocol
(String) The SNMPv3 authentication protocol for the Cluster SNMP. Accepted values areMD5
andSHA
.snmp_v3_password
(String) The SNMPv3 authentication password for the Cluster SNMP.snmp_v3_priv_password
(String) The SNMPv3 privacy protocol password for the Cluster SNMP.snmp_v3_priv_protocol
(String) The SNMPv3 privacy protocol for the Cluster SNMP.snmp_v3_read_only_user
(String) The SNMPv3 read-only user for the Cluster SNMP.snmp_v3_security_level
(String) The SNMPv3 security level for the Cluster SNMP.system_contact
(String) The system contact for the Cluster SNMP.system_location
(String) The system location for the Cluster SNMP.
Read-Only
id
(String) ID of the Cluster SNMP.
Unless specified otherwise, all fields of this resource can be updated.
Import
Import is supported using the following syntax:
# Copyright (c) 2024 Dell Inc., or its subsidiaries. All Rights Reserved.
# Licensed under the Mozilla Public 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://mozilla.org/MPL/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.
# The command is
# terraform import powerscale_cluster_snmp.example_snmp_settings <anyString>
# Example:
terraform import powerscale_cluster_snmp.example_snmp_settings "cluster_snmp"
# after running this command, populate the enabled field and other required parameters in the config file to start managing this resource.
# Note: running "terraform show" after importing shows the current config/state of the resource. You can copy/paste that config to make it easier to manage the resource.