Skip to content

Latest commit

 

History

History
177 lines (146 loc) · 8.7 KB

smb_share_settings.md

File metadata and controls

177 lines (146 loc) · 8.7 KB
title linkTitle page_title subcategory description
powerscale_smb_share_settings resource
powerscale_smb_share_settings
powerscale_smb_share_settings Resource - terraform-provider-powerscale
This resource is used to manage the SMB share Settings entity of PowerScale Array. We can Create, Update and Delete the SMB share Settings using this resource. We can also import the existing SMB share Settings from PowerScale array. Note that, SMB share Settings is the native functionality of PowerScale. When creating the resource, we actually load SMB share Settings from PowerScale to the resource state.

powerscale_smb_share_settings (Resource)

This resource is used to manage the SMB share Settings entity of PowerScale Array. We can Create, Update and Delete the SMB share Settings using this resource. We can also import the existing SMB share Settings from PowerScale array. Note that, SMB share Settings is the native functionality of PowerScale. When creating the resource, we actually load SMB share Settings from PowerScale to the resource state.

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
# After `terraform apply` of this example file it will create NFS export on specified paths on the PowerScale Array.
# For more information, Please check the terraform state file.

# PowerScale SMB share settings provide clients network access to file system resources on the cluster
resource "powerscale_smb_share_settings" "example" {

  # Required field both for creating and updating
  zone = "System"

  # Optional fields both for creating and updating
  # Please check the acceptable inputs for each setting in the documentation
  #access_based_enumeration           = true
  #access_based_enumeration_root_only = true
  #allow_delete_readonly              = true
  #allow_execute_always               = true
  #ca_timeout                         = 12
  #ca_write_integrity                 = "write-read-coherent"
  #change_notify                      = "none"
  #create_permissions                 = "default acl"
  #directory_create_mask              = 0
  #directory_create_mode              = 0
  #file_create_mask                   = 448
  #file_create_mode                   = 64
  #file_filter_extensions             = []
  #file_filter_type                   = "deny"
  #file_filtering_enabled             = true
  #hide_dot_files                     = true
  #host_acl                           = []
  #impersonate_guest                  = "never"
  #mangle_byte_start                  = 258
  #mangle_map                         = [
  #    "0x01-0x1F:-1",
  #    "0x22:-1",
  #    "0x2A:-1",
  #    "0x3A:-1",
  #    "0x3C:-1",
  #   "0x3E:-1",
  #    "0x3F:-1",
  #    "0x5C:-1",
  #]
  #ntfs_acl_support                   = true
  #oplocks                            = true
  #smb3_encryption_enabled            = true
  #sparse_file                        = true
  #strict_ca_lockout                  = true
  #strict_flush                       = true
  #strict_locking                     = true
  #scope                             = "effective"
}

# After the execution of above resource block, an SMB share Settings would have been created on the PowerScale array.
# For more information, Please check the terraform state file.

Schema

Required

  • zone (String) Name of the access zone in which to update settings

Optional

  • access_based_enumeration (Boolean) Only enumerate files and folders the requesting user has access to.
  • access_based_enumeration_root_only (Boolean) Access-based enumeration on only the root directory of the share.
  • allow_delete_readonly (Boolean) Allow deletion of read-only files in the share.
  • allow_execute_always (Boolean) Allows users to execute files they have read rights for.
  • ca_timeout (Number) Persistent open timeout for the share.
  • ca_write_integrity (String) Specify the level of write-integrity on continuously available shares. Acceptable values: none, write-read-coherent, full
  • change_notify (String) Specify level of change notification alerts on the share. Acceptable values: all, norecurse, none
  • continuously_available (Boolean) Specify if persistent opens are allowed on the share.
  • create_permissions (String) Set the create permissions for new files and directories in share. Acceptable values: default acl, inherit mode bits, use create mask and mode
  • csc_policy (String) Client-side caching policy for the shares. Acceptable values: manual, documents, programs, none
  • directory_create_mask (Number) Unix umask or mode bits.
  • directory_create_mode (Number) Unix umask or mode bits.
  • file_create_mask (Number) Unix umask or mode bits.
  • file_create_mode (Number) Unix umask or mode bits.
  • file_filter_extensions (List of String) Specifies the list of file extensions.
  • file_filter_type (String) Specifies if filter list is for deny or allow. Default is deny.
  • file_filtering_enabled (Boolean) Enables file filtering on the share.
  • hide_dot_files (Boolean) Hide files and directories that begin with a period '.'.
  • host_acl (List of String) An ACL expressing which hosts are allowed access. A deny clause must be the final entry.
  • impersonate_guest (String) Specify the condition in which user access is done as the guest account. Acceptable values: always, bad user, never
  • impersonate_user (String) User account to be used as guest account.
  • mangle_byte_start (Number) Specifies the wchar_t starting point for automatic byte mangling.
  • mangle_map (List of String) Character mangle map.
  • ntfs_acl_support (Boolean) Support NTFS ACLs on files and directories.
  • oplocks (Boolean) Allow oplock requests.
  • scope (String) When specified as 'effective', or not specified, all fields are returned. When specified as 'user', only fields with non-default values are shown. When specified as 'default', the original values are returned.
  • smb3_encryption_enabled (Boolean) Enables SMB3 encryption for the share.
  • sparse_file (Boolean) Enables sparse file.
  • strict_ca_lockout (Boolean) Specifies if persistent opens would do strict lockout on the share.
  • strict_flush (Boolean) Handle SMB flush operations.
  • strict_locking (Boolean) Specifies whether byte range locks contend against SMB I/O.

Read-Only

  • id (String) ID of SMB share Settings. Value of ID will be same as the access zone.

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_smb_share_settings.example zone 
terraform import powerscale_smb_share_settings.example tfaccAccessZone
# after running this command, populate the zone 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.