blob: 9d0ed83cb0babf52c601e60af43b41a59fbcb573 [file] [log] [blame]
Marc Koderer0abc93b2015-07-15 09:18:35 +02001# Copyright 2014 Mirantis 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.
15
16from __future__ import print_function
17
18from oslo_config import cfg
19
20from tempest import config # noqa
21
22service_available_group = cfg.OptGroup(name="service_available",
23 title="Available OpenStack Services")
24
25ServiceAvailableGroup = [
26 cfg.BoolOpt("manila",
27 default=True,
28 help="Whether or not manila is expected to be available"),
29]
30
31share_group = cfg.OptGroup(name="share", title="Share Service Options")
32
33ShareGroup = [
34 cfg.StrOpt("min_api_microversion",
Clinton Knighte5c8f092015-08-27 15:00:23 -040035 default="2.0",
Marc Koderer0abc93b2015-07-15 09:18:35 +020036 help="The minimum api microversion is configured to be the "
37 "value of the minimum microversion supported by Manila."),
38 cfg.StrOpt("max_api_microversion",
Goutham Pacha Ravi01bfd102016-05-30 15:41:08 -040039 default="2.17",
Marc Koderer0abc93b2015-07-15 09:18:35 +020040 help="The maximum api microversion is configured to be the "
41 "value of the latest microversion supported by Manila."),
42 cfg.StrOpt("region",
43 default="",
44 help="The share region name to use. If empty, the value "
45 "of identity.region is used instead. If no such region "
46 "is found in the service catalog, the first found one is "
47 "used."),
48 cfg.StrOpt("catalog_type",
49 default="share",
50 help="Catalog type of the Share service."),
51 cfg.StrOpt('endpoint_type',
52 default='publicURL',
53 choices=['public', 'admin', 'internal',
54 'publicURL', 'adminURL', 'internalURL'],
55 help="The endpoint type to use for the share service."),
56 cfg.BoolOpt("multitenancy_enabled",
57 default=True,
58 help="This option used to determine backend driver type, "
59 "multitenant driver uses share-networks, but "
60 "single-tenant doesn't."),
61 cfg.ListOpt("enable_protocols",
62 default=["nfs", "cifs"],
63 help="First value of list is protocol by default, "
64 "items of list show enabled protocols at all."),
65 cfg.ListOpt("enable_ip_rules_for_protocols",
66 default=["nfs", "cifs", ],
67 help="Selection of protocols, that should "
68 "be covered with ip rule tests"),
69 cfg.ListOpt("enable_user_rules_for_protocols",
70 default=[],
71 help="Selection of protocols, that should "
72 "be covered with user rule tests"),
73 cfg.ListOpt("enable_cert_rules_for_protocols",
74 default=["glusterfs", ],
75 help="Protocols that should be covered with cert rule tests."),
John Spray061b1452015-11-18 13:15:32 +000076 cfg.ListOpt("enable_cephx_rules_for_protocols",
77 default=["cephfs", ],
78 help="Protocols to be covered with cephx rule tests."),
Marc Koderer0abc93b2015-07-15 09:18:35 +020079 cfg.StrOpt("username_for_user_rules",
80 default="Administrator",
81 help="Username, that will be used in user tests."),
82 cfg.ListOpt("enable_ro_access_level_for_protocols",
83 default=["nfs", ],
84 help="List of protocols to run tests with ro access level."),
Valeriy Ponomaryovad55dc52015-09-23 13:54:00 +030085
86 # Capabilities
87 cfg.StrOpt("capability_storage_protocol",
88 deprecated_name="storage_protocol",
Marc Koderer0abc93b2015-07-15 09:18:35 +020089 default="NFS_CIFS",
90 help="Backend protocol to target when creating volume types."),
Valeriy Ponomaryovad55dc52015-09-23 13:54:00 +030091 cfg.BoolOpt("capability_snapshot_support",
92 help="Defines extra spec that satisfies specific back end "
93 "capability called 'snapshot_support' and will be used "
94 "for setting up custom share type. Defaults to value of "
95 "other config option 'run_snapshot_tests'."),
96
Marc Koderer0abc93b2015-07-15 09:18:35 +020097 cfg.StrOpt("share_network_id",
98 default="",
99 help="Some backend drivers requires share network "
100 "for share creation. Share network id, that will be "
101 "used for shares. If not set, it won't be used."),
102 cfg.StrOpt("alt_share_network_id",
103 default="",
104 help="Share network id, that will be used for shares"
105 " in alt tenant. If not set, it won't be used"),
106 cfg.StrOpt("admin_share_network_id",
107 default="",
108 help="Share network id, that will be used for shares"
109 " in admin tenant. If not set, it won't be used"),
110 cfg.BoolOpt("multi_backend",
111 default=False,
112 help="Runs Manila multi-backend tests."),
113 cfg.ListOpt("backend_names",
114 default=[],
115 help="Names of share backends, that will be used with "
116 "multibackend tests. Tempest will use first two values."),
117 cfg.IntOpt("share_creation_retry_number",
118 default=0,
119 help="Defines number of retries for share creation. "
120 "It is useful to avoid failures caused by unstable "
121 "environment."),
122 cfg.IntOpt("build_interval",
123 default=3,
124 help="Time in seconds between share availability checks."),
125 cfg.IntOpt("build_timeout",
126 default=500,
127 help="Timeout in seconds to wait for a share to become"
128 "available."),
129 cfg.BoolOpt("suppress_errors_in_cleanup",
130 default=False,
131 help="Whether to suppress errors with clean up operation "
132 "or not. There are cases when we may want to skip "
133 "such errors and catch only test errors."),
Valeriy Ponomaryovad55dc52015-09-23 13:54:00 +0300134
135 # Switching ON/OFF test suites filtered by features
Valeriy Ponomaryov9e56c992016-02-17 21:19:39 +0200136 cfg.BoolOpt("run_quota_tests",
137 default=True,
138 help="Defines whether to run quota tests or not."),
Marc Koderer0abc93b2015-07-15 09:18:35 +0200139 cfg.BoolOpt("run_extend_tests",
140 default=True,
141 help="Defines whether to run share extend tests or not. "
142 "Disable this feature if used driver doesn't "
143 "support it."),
144 cfg.BoolOpt("run_shrink_tests",
145 default=True,
146 help="Defines whether to run share shrink tests or not. "
147 "Disable this feature if used driver doesn't "
148 "support it."),
149 cfg.BoolOpt("run_snapshot_tests",
150 default=True,
151 help="Defines whether to run tests that use share snapshots "
152 "or not. Disable this feature if used driver doesn't "
153 "support it."),
Andrew Kerrbf31e912015-07-29 10:39:38 -0400154 cfg.BoolOpt("run_consistency_group_tests",
155 default=True,
156 help="Defines whether to run consistency group tests or not. "
157 "Disable this feature if used driver doesn't support "
158 "it."),
Yogeshbdb88102015-09-29 23:41:02 -0400159 cfg.BoolOpt("run_replication_tests",
160 default=False,
161 help="Defines whether to run replication tests or not. "
162 "Enable this feature if the driver is configured "
163 "for replication."),
Rodrigo Barbieri2aafa262015-09-09 15:52:16 -0300164 cfg.BoolOpt("run_migration_tests",
165 default=False,
166 help="Enable or disable migration tests."),
Xing Yang69b00b52015-11-22 16:10:44 -0500167 cfg.BoolOpt("run_manage_unmanage_tests",
168 default=False,
169 help="Defines whether to run manage/unmanage tests or not. "
170 "These test may leave orphaned resources, so be careful "
171 "enabling this opt."),
172 cfg.BoolOpt("run_manage_unmanage_snapshot_tests",
173 default=False,
174 help="Defines whether to run manage/unmanage snapshot tests "
175 "or not. These tests may leave orphaned resources, so be "
176 "careful enabling this opt."),
Valeriy Ponomaryovad55dc52015-09-23 13:54:00 +0300177
Marc Koderer0abc93b2015-07-15 09:18:35 +0200178 cfg.StrOpt("image_with_share_tools",
179 default="manila-service-image",
180 help="Image name for vm booting with nfs/smb clients tool."),
181 cfg.StrOpt("image_username",
182 default="manila",
183 help="Image username."),
184 cfg.StrOpt("image_password",
185 help="Image password. Should be used for "
186 "'image_with_share_tools' without Nova Metadata support."),
187 cfg.StrOpt("client_vm_flavor_ref",
188 default="100",
189 help="Flavor used for client vm in scenario tests."),
Rodrigo Barbierib7137ad2015-09-06 22:53:16 -0300190 cfg.IntOpt("migration_timeout",
Rodrigo Barbierie3305122016-02-03 14:32:24 -0200191 default=1500,
Rodrigo Barbierib7137ad2015-09-06 22:53:16 -0300192 help="Time to wait for share migration before "
193 "timing out (seconds)."),
Julia Varlamovad10a4a92015-08-31 06:28:28 -0400194 cfg.StrOpt("default_share_type_name",
Julia Varlamovad10a4a92015-08-31 06:28:28 -0400195 help="Default share type name to use in tempest tests."),
Yogeshbdb88102015-09-29 23:41:02 -0400196 cfg.StrOpt("backend_replication_type",
197 default='none',
198 choices=['none', 'writable', 'readable', 'dr'],
199 help="Specify the replication type supported by the backend."),
marcusvrne0d7cfd2016-06-24 12:27:55 -0300200 cfg.IntOpt("share_size",
201 default=1,
202 help="Default size in GB for shares created by share tests."),
Marc Koderer0abc93b2015-07-15 09:18:35 +0200203]