From 65c7cd0e020f3022f4dc81827512e4ae95df2881 Mon Sep 17 00:00:00 2001 From: zhurong Date: Wed, 6 Sep 2017 13:46:27 +0800 Subject: [PATCH] Remove the unused rootwrap config Watcher doesn't use rootwrap, but have the rootwrap config. So remove the unused rootwrap config. Change-Id: Icc32fc958ca8deb08d7b0e5404cbbe19b3ae98c7 --- watcher/conf/__init__.py | 2 -- watcher/conf/_opts.py | 4 +--- watcher/conf/utils.py | 36 ------------------------------------ 3 files changed, 1 insertion(+), 41 deletions(-) delete mode 100644 watcher/conf/utils.py diff --git a/watcher/conf/__init__.py b/watcher/conf/__init__.py index 01a5eed9a..ca7f77aff 100755 --- a/watcher/conf/__init__.py +++ b/watcher/conf/__init__.py @@ -37,13 +37,11 @@ from watcher.conf import nova_client from watcher.conf import paths from watcher.conf import planner from watcher.conf import service -from watcher.conf import utils CONF = cfg.CONF service.register_opts(CONF) api.register_opts(CONF) -utils.register_opts(CONF) paths.register_opts(CONF) exception.register_opts(CONF) db.register_opts(CONF) diff --git a/watcher/conf/_opts.py b/watcher/conf/_opts.py index 73398f196..250c6f03e 100644 --- a/watcher/conf/_opts.py +++ b/watcher/conf/_opts.py @@ -30,7 +30,6 @@ from watcher.conf import neutron_client as conf_neutron_client from watcher.conf import nova_client as conf_nova_client from watcher.conf import paths from watcher.conf import planner as conf_planner -from watcher.conf import utils def list_opts(): @@ -39,8 +38,7 @@ def list_opts(): ('DEFAULT', (conf_api.AUTH_OPTS + exception.EXC_LOG_OPTS + - paths.PATH_OPTS + - utils.UTILS_OPTS)), + paths.PATH_OPTS)), ('api', conf_api.API_SERVICE_OPTS), ('database', db.SQL_OPTS), ('watcher_planner', conf_planner.WATCHER_PLANNER_OPTS), diff --git a/watcher/conf/utils.py b/watcher/conf/utils.py deleted file mode 100644 index 7c2981ce8..000000000 --- a/watcher/conf/utils.py +++ /dev/null @@ -1,36 +0,0 @@ -# -*- encoding: utf-8 -*- -# Copyright (c) 2016 Intel Corp -# -# Authors: Prudhvi Rao Shedimbi -# -# Licensed under the Apache 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://www.apache.org/licenses/LICENSE-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. - -from oslo_config import cfg - -UTILS_OPTS = [ - cfg.StrOpt('rootwrap_config', - default="/etc/watcher/rootwrap.conf", - help='Path to the rootwrap configuration file to use for ' - 'running commands as root.'), - cfg.StrOpt('tempdir', - help='Explicitly specify the temporary working directory.'), -] - - -def register_opts(conf): - conf.register_opts(UTILS_OPTS) - - -def list_opts(): - return [('DEFAULT', UTILS_OPTS)]