Matthew Treinish | 1f7b33d | 2013-10-21 18:07:02 +0000 | [diff] [blame] | 1 | #!/usr/bin/env python |
Matthew Treinish | 1f7b33d | 2013-10-21 18:07:02 +0000 | [diff] [blame] | 2 | |
| 3 | # Copyright 2013 IBM Corp. |
| 4 | # |
| 5 | # Licensed under the Apache License, Version 2.0 (the "License"); you may |
| 6 | # not use this file except in compliance with the License. You may obtain |
| 7 | # a copy of the License at |
| 8 | # |
| 9 | # http://www.apache.org/licenses/LICENSE-2.0 |
| 10 | # |
| 11 | # Unless required by applicable law or agreed to in writing, software |
| 12 | # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT |
| 13 | # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the |
| 14 | # License for the specific language governing permissions and limitations |
| 15 | # under the License. |
| 16 | |
Matthew Treinish | f097171 | 2014-04-11 20:08:53 +0000 | [diff] [blame] | 17 | import argparse |
Matthew Treinish | 4f30eb8 | 2014-01-07 21:04:49 +0000 | [diff] [blame] | 18 | import json |
Matthew Treinish | f097171 | 2014-04-11 20:08:53 +0000 | [diff] [blame] | 19 | import os |
Matthew Treinish | 1f7b33d | 2013-10-21 18:07:02 +0000 | [diff] [blame] | 20 | import sys |
Matthew Treinish | 864fe07 | 2014-03-02 03:47:26 +0000 | [diff] [blame] | 21 | import urlparse |
Matthew Treinish | 1f7b33d | 2013-10-21 18:07:02 +0000 | [diff] [blame] | 22 | |
Matthew Treinish | 4f30eb8 | 2014-01-07 21:04:49 +0000 | [diff] [blame] | 23 | import httplib2 |
Matthew Treinish | c795b9e | 2014-06-09 17:01:10 -0400 | [diff] [blame^] | 24 | from six import moves |
Matthew Treinish | 4f30eb8 | 2014-01-07 21:04:49 +0000 | [diff] [blame] | 25 | |
Matthew Treinish | 1f7b33d | 2013-10-21 18:07:02 +0000 | [diff] [blame] | 26 | from tempest import clients |
| 27 | from tempest import config |
| 28 | |
| 29 | |
Sean Dague | 86bd842 | 2013-12-20 09:56:44 -0500 | [diff] [blame] | 30 | CONF = config.CONF |
Matthew Treinish | 4f30eb8 | 2014-01-07 21:04:49 +0000 | [diff] [blame] | 31 | RAW_HTTP = httplib2.Http() |
Matthew Treinish | f097171 | 2014-04-11 20:08:53 +0000 | [diff] [blame] | 32 | CONF_FILE = None |
| 33 | OUTFILE = sys.stdout |
Matthew Treinish | 1f7b33d | 2013-10-21 18:07:02 +0000 | [diff] [blame] | 34 | |
Matthew Treinish | 1f7b33d | 2013-10-21 18:07:02 +0000 | [diff] [blame] | 35 | |
Matthew Treinish | f097171 | 2014-04-11 20:08:53 +0000 | [diff] [blame] | 36 | def _get_config_file(): |
| 37 | default_config_dir = os.path.join(os.path.abspath( |
| 38 | os.path.dirname(os.path.dirname(__file__))), "etc") |
| 39 | default_config_file = "tempest.conf" |
| 40 | |
| 41 | conf_dir = os.environ.get('TEMPEST_CONFIG_DIR', default_config_dir) |
| 42 | conf_file = os.environ.get('TEMPEST_CONFIG', default_config_file) |
| 43 | path = os.path.join(conf_dir, conf_file) |
| 44 | fd = open(path, 'rw') |
| 45 | return fd |
| 46 | |
| 47 | |
| 48 | def change_option(option, group, value): |
Matthew Treinish | c795b9e | 2014-06-09 17:01:10 -0400 | [diff] [blame^] | 49 | config_parse = moves.configparser.SafeConfigParser() |
Matthew Treinish | f097171 | 2014-04-11 20:08:53 +0000 | [diff] [blame] | 50 | config_parse.optionxform = str |
| 51 | config_parse.readfp(CONF_FILE) |
| 52 | if not config_parse.has_section(group): |
| 53 | config_parse.add_section(group) |
| 54 | config_parse.set(group, option, str(value)) |
| 55 | global OUTFILE |
| 56 | config_parse.write(OUTFILE) |
| 57 | |
| 58 | |
| 59 | def print_and_or_update(option, group, value, update): |
| 60 | print('Config option %s in group %s should be changed to: %s' |
| 61 | % (option, group, value)) |
| 62 | if update: |
| 63 | change_option(option, group, value) |
| 64 | |
| 65 | |
| 66 | def verify_glance_api_versions(os, update): |
Matthew Treinish | 99afd07 | 2013-10-22 18:03:06 +0000 | [diff] [blame] | 67 | # Check glance api versions |
| 68 | __, versions = os.image_client.get_versions() |
| 69 | if CONF.image_feature_enabled.api_v1 != ('v1.1' in versions or 'v1.0' in |
| 70 | versions): |
Matthew Treinish | f097171 | 2014-04-11 20:08:53 +0000 | [diff] [blame] | 71 | print_and_or_update('api_v1', 'image_feature_enabled', |
| 72 | not CONF.image_feature_enabled.api_v1, update) |
Matthew Treinish | 99afd07 | 2013-10-22 18:03:06 +0000 | [diff] [blame] | 73 | if CONF.image_feature_enabled.api_v2 != ('v2.0' in versions): |
Matthew Treinish | f097171 | 2014-04-11 20:08:53 +0000 | [diff] [blame] | 74 | print_and_or_update('api_v2', 'image_feature_enabled', |
| 75 | not CONF.image_feature_enabled.api_v2, update) |
Matthew Treinish | 99afd07 | 2013-10-22 18:03:06 +0000 | [diff] [blame] | 76 | |
| 77 | |
Matthew Treinish | 9b89624 | 2014-04-23 21:25:27 +0000 | [diff] [blame] | 78 | def _get_unversioned_endpoint(base_url): |
| 79 | endpoint_parts = urlparse.urlparse(base_url) |
| 80 | endpoint = endpoint_parts.scheme + '://' + endpoint_parts.netloc |
| 81 | return endpoint |
| 82 | |
| 83 | |
Matthew Treinish | 864fe07 | 2014-03-02 03:47:26 +0000 | [diff] [blame] | 84 | def _get_api_versions(os, service): |
| 85 | client_dict = { |
| 86 | 'nova': os.servers_client, |
| 87 | 'keystone': os.identity_client, |
Matthew Treinish | 2e43963 | 2014-03-05 21:53:33 +0000 | [diff] [blame] | 88 | 'cinder': os.volumes_client, |
Matthew Treinish | 864fe07 | 2014-03-02 03:47:26 +0000 | [diff] [blame] | 89 | } |
| 90 | client_dict[service].skip_path() |
Matthew Treinish | 9b89624 | 2014-04-23 21:25:27 +0000 | [diff] [blame] | 91 | endpoint = _get_unversioned_endpoint(client_dict[service].base_url) |
Matthew Treinish | a508081 | 2014-02-11 15:49:04 +0000 | [diff] [blame] | 92 | __, body = RAW_HTTP.request(endpoint, 'GET') |
Matthew Treinish | 864fe07 | 2014-03-02 03:47:26 +0000 | [diff] [blame] | 93 | client_dict[service].reset_path() |
Matthew Treinish | 4f30eb8 | 2014-01-07 21:04:49 +0000 | [diff] [blame] | 94 | body = json.loads(body) |
Matthew Treinish | 864fe07 | 2014-03-02 03:47:26 +0000 | [diff] [blame] | 95 | if service == 'keystone': |
| 96 | versions = map(lambda x: x['id'], body['versions']['values']) |
| 97 | else: |
| 98 | versions = map(lambda x: x['id'], body['versions']) |
| 99 | return versions |
| 100 | |
| 101 | |
Matthew Treinish | f097171 | 2014-04-11 20:08:53 +0000 | [diff] [blame] | 102 | def verify_keystone_api_versions(os, update): |
Matthew Treinish | 864fe07 | 2014-03-02 03:47:26 +0000 | [diff] [blame] | 103 | # Check keystone api versions |
| 104 | versions = _get_api_versions(os, 'keystone') |
| 105 | if CONF.identity_feature_enabled.api_v2 != ('v2.0' in versions): |
Matthew Treinish | f097171 | 2014-04-11 20:08:53 +0000 | [diff] [blame] | 106 | print_and_or_update('api_v2', 'identity_feature_enabled', |
| 107 | not CONF.identity_feature_enabled.api_v2, update) |
Matthew Treinish | 864fe07 | 2014-03-02 03:47:26 +0000 | [diff] [blame] | 108 | if CONF.identity_feature_enabled.api_v3 != ('v3.0' in versions): |
Matthew Treinish | f097171 | 2014-04-11 20:08:53 +0000 | [diff] [blame] | 109 | print_and_or_update('api_v3', 'identity_feature_enabled', |
| 110 | not CONF.identity_feature_enabled.api_v3, update) |
Matthew Treinish | 864fe07 | 2014-03-02 03:47:26 +0000 | [diff] [blame] | 111 | |
| 112 | |
Matthew Treinish | f097171 | 2014-04-11 20:08:53 +0000 | [diff] [blame] | 113 | def verify_nova_api_versions(os, update): |
Matthew Treinish | 864fe07 | 2014-03-02 03:47:26 +0000 | [diff] [blame] | 114 | versions = _get_api_versions(os, 'nova') |
Matthew Treinish | 4f30eb8 | 2014-01-07 21:04:49 +0000 | [diff] [blame] | 115 | if CONF.compute_feature_enabled.api_v3 != ('v3.0' in versions): |
Matthew Treinish | f097171 | 2014-04-11 20:08:53 +0000 | [diff] [blame] | 116 | print_and_or_update('api_v3', 'compute_feature_enabled', |
| 117 | not CONF.compute_feature_enabled.api_v3, update) |
Matthew Treinish | 4f30eb8 | 2014-01-07 21:04:49 +0000 | [diff] [blame] | 118 | |
| 119 | |
Matthew Treinish | f097171 | 2014-04-11 20:08:53 +0000 | [diff] [blame] | 120 | def verify_cinder_api_versions(os, update): |
Matthew Treinish | 2e43963 | 2014-03-05 21:53:33 +0000 | [diff] [blame] | 121 | # Check cinder api versions |
| 122 | versions = _get_api_versions(os, 'cinder') |
| 123 | if CONF.volume_feature_enabled.api_v1 != ('v1.0' in versions): |
Matthew Treinish | f097171 | 2014-04-11 20:08:53 +0000 | [diff] [blame] | 124 | print_and_or_update('api_v1', 'volume_feature_enabled', |
| 125 | not CONF.volume_feature_enabled.api_v1, update) |
Matthew Treinish | 2e43963 | 2014-03-05 21:53:33 +0000 | [diff] [blame] | 126 | if CONF.volume_feature_enabled.api_v2 != ('v2.0' in versions): |
Matthew Treinish | f097171 | 2014-04-11 20:08:53 +0000 | [diff] [blame] | 127 | print_and_or_update('api_v2', 'volume_feature_enabled', |
| 128 | not CONF.volume_feature_enabled.api_v2, update) |
Matthew Treinish | 2e43963 | 2014-03-05 21:53:33 +0000 | [diff] [blame] | 129 | |
| 130 | |
Matthew Treinish | 8b006d2 | 2014-01-07 15:37:20 +0000 | [diff] [blame] | 131 | def get_extension_client(os, service): |
| 132 | extensions_client = { |
| 133 | 'nova': os.extensions_client, |
| 134 | 'nova_v3': os.extensions_v3_client, |
| 135 | 'cinder': os.volumes_extension_client, |
Matthew Treinish | 8c6706d | 2014-01-07 19:28:18 +0000 | [diff] [blame] | 136 | 'neutron': os.network_client, |
Matthew Treinish | c0120ba | 2014-01-31 20:10:19 +0000 | [diff] [blame] | 137 | 'swift': os.account_client, |
Matthew Treinish | 8b006d2 | 2014-01-07 15:37:20 +0000 | [diff] [blame] | 138 | } |
| 139 | if service not in extensions_client: |
| 140 | print('No tempest extensions client for %s' % service) |
| 141 | exit(1) |
| 142 | return extensions_client[service] |
| 143 | |
| 144 | |
| 145 | def get_enabled_extensions(service): |
| 146 | extensions_options = { |
| 147 | 'nova': CONF.compute_feature_enabled.api_extensions, |
| 148 | 'nova_v3': CONF.compute_feature_enabled.api_v3_extensions, |
| 149 | 'cinder': CONF.volume_feature_enabled.api_extensions, |
Matthew Treinish | 8c6706d | 2014-01-07 19:28:18 +0000 | [diff] [blame] | 150 | 'neutron': CONF.network_feature_enabled.api_extensions, |
Matthew Treinish | c0120ba | 2014-01-31 20:10:19 +0000 | [diff] [blame] | 151 | 'swift': CONF.object_storage_feature_enabled.discoverable_apis, |
Matthew Treinish | 8b006d2 | 2014-01-07 15:37:20 +0000 | [diff] [blame] | 152 | } |
| 153 | if service not in extensions_options: |
| 154 | print('No supported extensions list option for %s' % service) |
| 155 | exit(1) |
| 156 | return extensions_options[service] |
| 157 | |
| 158 | |
| 159 | def verify_extensions(os, service, results): |
| 160 | extensions_client = get_extension_client(os, service) |
Matthew Treinish | 1f7b33d | 2013-10-21 18:07:02 +0000 | [diff] [blame] | 161 | __, resp = extensions_client.list_extensions() |
Matthew Treinish | 8b006d2 | 2014-01-07 15:37:20 +0000 | [diff] [blame] | 162 | if isinstance(resp, dict): |
Ken'ichi Ohmichi | a7e6871 | 2014-05-06 10:47:26 +0900 | [diff] [blame] | 163 | # For both Nova and Neutron we use the alias name rather than the |
| 164 | # 'name' field because the alias is considered to be the canonical |
| 165 | # name. |
| 166 | if service in ['nova', 'nova_v3', 'neutron']: |
Matthew Treinish | 8c6706d | 2014-01-07 19:28:18 +0000 | [diff] [blame] | 167 | extensions = map(lambda x: x['alias'], resp['extensions']) |
Matthew Treinish | c0120ba | 2014-01-31 20:10:19 +0000 | [diff] [blame] | 168 | elif service == 'swift': |
| 169 | # Remove Swift general information from extensions list |
| 170 | resp.pop('swift') |
| 171 | extensions = resp.keys() |
Matthew Treinish | 8c6706d | 2014-01-07 19:28:18 +0000 | [diff] [blame] | 172 | else: |
| 173 | extensions = map(lambda x: x['name'], resp['extensions']) |
| 174 | |
Matthew Treinish | 8b006d2 | 2014-01-07 15:37:20 +0000 | [diff] [blame] | 175 | else: |
| 176 | extensions = map(lambda x: x['name'], resp) |
| 177 | if not results.get(service): |
| 178 | results[service] = {} |
| 179 | extensions_opt = get_enabled_extensions(service) |
| 180 | if extensions_opt[0] == 'all': |
Matthew Treinish | f097171 | 2014-04-11 20:08:53 +0000 | [diff] [blame] | 181 | results[service]['extensions'] = extensions |
Matthew Treinish | 8b006d2 | 2014-01-07 15:37:20 +0000 | [diff] [blame] | 182 | return results |
| 183 | # Verify that all configured extensions are actually enabled |
| 184 | for extension in extensions_opt: |
| 185 | results[service][extension] = extension in extensions |
| 186 | # Verify that there aren't additional extensions enabled that aren't |
| 187 | # specified in the config list |
| 188 | for extension in extensions: |
| 189 | if extension not in extensions_opt: |
| 190 | results[service][extension] = False |
Matthew Treinish | 1f7b33d | 2013-10-21 18:07:02 +0000 | [diff] [blame] | 191 | return results |
| 192 | |
| 193 | |
Matthew Treinish | f097171 | 2014-04-11 20:08:53 +0000 | [diff] [blame] | 194 | def display_results(results, update, replace): |
| 195 | update_dict = { |
| 196 | 'swift': 'object-storage-feature-enabled', |
| 197 | 'nova': 'compute-feature-enabled', |
| 198 | 'nova_v3': 'compute-feature-enabled', |
| 199 | 'cinder': 'volume-feature-enabled', |
| 200 | 'neutron': 'network-feature-enabled', |
| 201 | } |
Matthew Treinish | 8b006d2 | 2014-01-07 15:37:20 +0000 | [diff] [blame] | 202 | for service in results: |
| 203 | # If all extensions are specified as being enabled there is no way to |
| 204 | # verify this so we just assume this to be true |
| 205 | if results[service].get('extensions'): |
Matthew Treinish | f097171 | 2014-04-11 20:08:53 +0000 | [diff] [blame] | 206 | if replace: |
| 207 | output_list = results[service].get('extensions') |
| 208 | else: |
| 209 | output_list = ['all'] |
| 210 | else: |
| 211 | extension_list = get_enabled_extensions(service) |
| 212 | output_list = [] |
| 213 | for extension in results[service]: |
| 214 | if not results[service][extension]: |
| 215 | if extension in extension_list: |
| 216 | print("%s extension: %s should not be included in the " |
| 217 | "list of enabled extensions" % (service, |
| 218 | extension)) |
| 219 | else: |
| 220 | print("%s extension: %s should be included in the list" |
| 221 | " of enabled extensions" % (service, extension)) |
| 222 | output_list.append(extension) |
Matthew Treinish | 8b006d2 | 2014-01-07 15:37:20 +0000 | [diff] [blame] | 223 | else: |
Matthew Treinish | f097171 | 2014-04-11 20:08:53 +0000 | [diff] [blame] | 224 | output_list.append(extension) |
| 225 | if update: |
| 226 | # Sort List |
| 227 | output_list.sort() |
| 228 | # Convert list to a string |
| 229 | output_string = ', '.join(output_list) |
| 230 | if service == 'swift': |
| 231 | change_option('discoverable_apis', update_dict[service], |
| 232 | output_string) |
| 233 | elif service == 'nova_v3': |
| 234 | change_option('api_v3_extensions', update_dict[service], |
| 235 | output_string) |
| 236 | else: |
| 237 | change_option('api_extensions', update_dict[service], |
| 238 | output_string) |
Matthew Treinish | 1f7b33d | 2013-10-21 18:07:02 +0000 | [diff] [blame] | 239 | |
| 240 | |
Matthew Treinish | f097171 | 2014-04-11 20:08:53 +0000 | [diff] [blame] | 241 | def check_service_availability(os, update): |
Matthew Treinish | 221bd7f | 2014-02-07 21:16:09 +0000 | [diff] [blame] | 242 | services = [] |
| 243 | avail_services = [] |
| 244 | codename_match = { |
| 245 | 'volume': 'cinder', |
| 246 | 'network': 'neutron', |
| 247 | 'image': 'glance', |
| 248 | 'object_storage': 'swift', |
| 249 | 'compute': 'nova', |
| 250 | 'orchestration': 'heat', |
| 251 | 'metering': 'ceilometer', |
| 252 | 'telemetry': 'ceilometer', |
Matthew Treinish | 42d50f6 | 2014-04-11 19:47:13 +0000 | [diff] [blame] | 253 | 'data_processing': 'sahara', |
Matthew Treinish | 221bd7f | 2014-02-07 21:16:09 +0000 | [diff] [blame] | 254 | 'baremetal': 'ironic', |
Matthew Treinish | 42d50f6 | 2014-04-11 19:47:13 +0000 | [diff] [blame] | 255 | 'identity': 'keystone', |
| 256 | 'queuing': 'marconi', |
| 257 | 'database': 'trove' |
Matthew Treinish | 221bd7f | 2014-02-07 21:16:09 +0000 | [diff] [blame] | 258 | } |
| 259 | # Get catalog list for endpoints to use for validation |
| 260 | __, endpoints = os.endpoints_client.list_endpoints() |
| 261 | for endpoint in endpoints: |
| 262 | __, service = os.service_client.get_service(endpoint['service_id']) |
| 263 | services.append(service['type']) |
| 264 | # Pull all catalog types from config file and compare against endpoint list |
| 265 | for cfgname in dir(CONF._config): |
| 266 | cfg = getattr(CONF, cfgname) |
| 267 | catalog_type = getattr(cfg, 'catalog_type', None) |
| 268 | if not catalog_type: |
| 269 | continue |
| 270 | else: |
| 271 | if cfgname == 'identity': |
| 272 | # Keystone is a required service for tempest |
| 273 | continue |
| 274 | if catalog_type not in services: |
| 275 | if getattr(CONF.service_available, codename_match[cfgname]): |
| 276 | print('Endpoint type %s not found either disable service ' |
| 277 | '%s or fix the catalog_type in the config file' % ( |
| 278 | catalog_type, codename_match[cfgname])) |
Matthew Treinish | f097171 | 2014-04-11 20:08:53 +0000 | [diff] [blame] | 279 | if update: |
| 280 | change_option(codename_match[cfgname], |
| 281 | 'service_available', False) |
Matthew Treinish | 221bd7f | 2014-02-07 21:16:09 +0000 | [diff] [blame] | 282 | else: |
| 283 | if not getattr(CONF.service_available, |
| 284 | codename_match[cfgname]): |
| 285 | print('Endpoint type %s is available, service %s should be' |
| 286 | ' set as available in the config file.' % ( |
| 287 | catalog_type, codename_match[cfgname])) |
Matthew Treinish | f097171 | 2014-04-11 20:08:53 +0000 | [diff] [blame] | 288 | if update: |
| 289 | change_option(codename_match[cfgname], |
| 290 | 'service_available', True) |
Matthew Treinish | 221bd7f | 2014-02-07 21:16:09 +0000 | [diff] [blame] | 291 | else: |
| 292 | avail_services.append(codename_match[cfgname]) |
| 293 | return avail_services |
Matthew Treinish | d44fe03 | 2014-01-31 20:07:24 +0000 | [diff] [blame] | 294 | |
| 295 | |
Matthew Treinish | f097171 | 2014-04-11 20:08:53 +0000 | [diff] [blame] | 296 | def parse_args(): |
| 297 | parser = argparse.ArgumentParser() |
| 298 | parser.add_argument('-u', '--update', action='store_true', |
| 299 | help='Update the config file with results from api ' |
| 300 | 'queries. This assumes whatever is set in the ' |
| 301 | 'config file is incorrect. In the case of ' |
| 302 | 'endpoint checks where it could either be the ' |
| 303 | 'incorrect catalog type or the service available ' |
| 304 | 'option the service available option is assumed ' |
| 305 | 'to be incorrect and is thus changed') |
| 306 | parser.add_argument('-o', '--output', |
| 307 | help="Output file to write an updated config file to. " |
| 308 | "This has to be a separate file from the " |
| 309 | "original config file. If one isn't specified " |
| 310 | "with -u the new config file will be printed to " |
| 311 | "STDOUT") |
| 312 | parser.add_argument('-r', '--replace-ext', action='store_true', |
| 313 | help="If specified the all option will be replaced " |
| 314 | "with a full list of extensions") |
| 315 | args = parser.parse_args() |
| 316 | return args |
| 317 | |
| 318 | |
Matthew Treinish | f8b816a | 2014-04-23 20:35:49 +0000 | [diff] [blame] | 319 | def main(): |
Matthew Treinish | 8b006d2 | 2014-01-07 15:37:20 +0000 | [diff] [blame] | 320 | print('Running config verification...') |
Matthew Treinish | f097171 | 2014-04-11 20:08:53 +0000 | [diff] [blame] | 321 | opts = parse_args() |
| 322 | update = opts.update |
| 323 | replace = opts.replace_ext |
| 324 | global CONF_FILE |
| 325 | global OUTFILE |
| 326 | if update: |
| 327 | CONF_FILE = _get_config_file() |
| 328 | if opts.output: |
| 329 | OUTFILE = open(opts.output, 'w+') |
Matthew Treinish | 1f7b33d | 2013-10-21 18:07:02 +0000 | [diff] [blame] | 330 | os = clients.ComputeAdminManager(interface='json') |
Matthew Treinish | f097171 | 2014-04-11 20:08:53 +0000 | [diff] [blame] | 331 | services = check_service_availability(os, update) |
Matthew Treinish | 8b006d2 | 2014-01-07 15:37:20 +0000 | [diff] [blame] | 332 | results = {} |
Matthew Treinish | c0120ba | 2014-01-31 20:10:19 +0000 | [diff] [blame] | 333 | for service in ['nova', 'nova_v3', 'cinder', 'neutron', 'swift']: |
Matthew Treinish | 221bd7f | 2014-02-07 21:16:09 +0000 | [diff] [blame] | 334 | if service == 'nova_v3' and 'nova' not in services: |
| 335 | continue |
| 336 | elif service not in services: |
Matthew Treinish | d44fe03 | 2014-01-31 20:07:24 +0000 | [diff] [blame] | 337 | continue |
Matthew Treinish | 8b006d2 | 2014-01-07 15:37:20 +0000 | [diff] [blame] | 338 | results = verify_extensions(os, service, results) |
Matthew Treinish | f097171 | 2014-04-11 20:08:53 +0000 | [diff] [blame] | 339 | verify_keystone_api_versions(os, update) |
| 340 | verify_glance_api_versions(os, update) |
| 341 | verify_nova_api_versions(os, update) |
| 342 | verify_cinder_api_versions(os, update) |
| 343 | display_results(results, update, replace) |
| 344 | if CONF_FILE: |
| 345 | CONF_FILE.close() |
| 346 | OUTFILE.close() |
Matthew Treinish | 1f7b33d | 2013-10-21 18:07:02 +0000 | [diff] [blame] | 347 | |
| 348 | |
| 349 | if __name__ == "__main__": |
Matthew Treinish | f8b816a | 2014-04-23 20:35:49 +0000 | [diff] [blame] | 350 | main() |