Coverage for manila/share/drivers/nexenta/options.py: 100%
4 statements
« prev ^ index » next coverage.py v7.11.0, created at 2026-02-18 22:19 +0000
« prev ^ index » next coverage.py v7.11.0, created at 2026-02-18 22:19 +0000
1# Copyright 2019 Nexenta by DDN, Inc.
2# All Rights Reserved.
3#
4# Licensed under the Apache License, Version 2.0 (the "License"); you may
5# not use this file except in compliance with the License. You may obtain
6# a copy of the License at
7#
8# http://www.apache.org/licenses/LICENSE-2.0
9#
10# Unless required by applicable law or agreed to in writing, software
11# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
12# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
13# License for the specific language governing permissions and limitations
14# under the License.
16"""
17:mod:`nexenta.options` -- Contains configuration options for Nexenta drivers.
18=============================================================================
20.. automodule:: nexenta.options
21"""
23from oslo_config import cfg
25nexenta_connection_opts = [
26 cfg.ListOpt('nexenta_rest_addresses',
27 help='One or more comma delimited IP addresses for management '
28 'communication with NexentaStor appliance.'),
29 cfg.IntOpt('nexenta_rest_port',
30 default=8443,
31 help='Port to connect to Nexenta REST API server.'),
32 cfg.StrOpt('nexenta_rest_protocol',
33 default='auto',
34 choices=['http', 'https', 'auto'],
35 help='Use http or https for REST connection (default auto).'),
36 cfg.BoolOpt('nexenta_use_https',
37 default=True,
38 help='Use HTTP secure protocol for NexentaStor '
39 'management REST API connections'),
40 cfg.StrOpt('nexenta_user',
41 default='admin',
42 help='User name to connect to Nexenta SA.'),
43 cfg.StrOpt('nexenta_password',
44 help='Password to connect to Nexenta SA.',
45 required=True,
46 secret=True),
47 cfg.StrOpt('nexenta_volume',
48 default='volume1',
49 help='Volume name on NexentaStor.'),
50 cfg.StrOpt('nexenta_pool',
51 default='pool1',
52 help='Pool name on NexentaStor.'),
53 cfg.BoolOpt('nexenta_nfs',
54 default=True,
55 help='Defines whether share over NFS is enabled.'),
56 cfg.BoolOpt('nexenta_ssl_cert_verify',
57 default=False,
58 help='Defines whether the driver should check ssl cert.'),
59 cfg.FloatOpt('nexenta_rest_connect_timeout',
60 default=30,
61 help='Specifies the time limit (in seconds), within '
62 'which the connection to NexentaStor management '
63 'REST API server must be established'),
64 cfg.FloatOpt('nexenta_rest_read_timeout',
65 default=300,
66 help='Specifies the time limit (in seconds), '
67 'within which NexentaStor management '
68 'REST API server must send a response'),
69 cfg.FloatOpt('nexenta_rest_backoff_factor',
70 default=1,
71 help='Specifies the backoff factor to apply '
72 'between connection attempts to NexentaStor '
73 'management REST API server'),
74 cfg.IntOpt('nexenta_rest_retry_count',
75 default=5,
76 help='Specifies the number of times to repeat NexentaStor '
77 'management REST API call in case of connection errors '
78 'and NexentaStor appliance EBUSY or ENOENT errors'),
79]
81nexenta_nfs_opts = [
82 cfg.HostAddressOpt('nexenta_nas_host',
83 help='Data IP address of Nexenta storage appliance.',
84 required=True),
85 cfg.StrOpt('nexenta_mount_point_base',
86 default='$state_path/mnt',
87 help='Base directory that contains NFS share mount points.'),
88]
90nexenta_dataset_opts = [
91 cfg.StrOpt('nexenta_nfs_share',
92 default='nfs_share',
93 help='Parent filesystem where all the shares will be created. '
94 'This parameter is only used by NexentaStor4 driver.'),
95 cfg.StrOpt('nexenta_share_name_prefix',
96 help='Nexenta share name prefix.',
97 default='share-'),
98 cfg.StrOpt('nexenta_folder',
99 default='folder',
100 help='Parent folder on NexentaStor.'),
101 cfg.StrOpt('nexenta_dataset_compression',
102 default='on',
103 choices=['on', 'off', 'gzip', 'gzip-1', 'gzip-2', 'gzip-3',
104 'gzip-4', 'gzip-5', 'gzip-6', 'gzip-7', 'gzip-8',
105 'gzip-9', 'lzjb', 'zle', 'lz4'],
106 help='Compression value for new ZFS folders.'),
107 cfg.StrOpt('nexenta_dataset_dedupe',
108 default='off',
109 choices=['on', 'off', 'sha256', 'verify'],
110 help='Deduplication value for new ZFS folders. '
111 'Only used by NexentaStor4 driver.'),
112 cfg.BoolOpt('nexenta_thin_provisioning',
113 default=True,
114 help=('If True shares will not be space guaranteed and '
115 'overprovisioning will be enabled.')),
116 cfg.IntOpt('nexenta_dataset_record_size',
117 default=131072,
118 help='Specifies a suggested block size in for files in a file '
119 'system. (bytes)'),
120]