diff --git a/.coveragerc b/.coveragerc index 5ed98b3..870bf4d 100644 --- a/.coveragerc +++ b/.coveragerc @@ -1,7 +1,7 @@ [run] branch = True -source = os_failures -omit = os_failures/openstack/* +source = os_faults +omit = os_faults/openstack/* [report] ignore_errors = True diff --git a/.gitreview b/.gitreview index d554149..89df0c4 100644 --- a/.gitreview +++ b/.gitreview @@ -1,4 +1,4 @@ [gerrit] host=review.openstack.org port=29418 -project=openstack/os-failures.git +project=openstack/os-faults.git diff --git a/CONTRIBUTING.rst b/CONTRIBUTING.rst index 073bbf3..a738139 100644 --- a/CONTRIBUTING.rst +++ b/CONTRIBUTING.rst @@ -14,4 +14,4 @@ Pull requests submitted through GitHub will be ignored. Bugs should be filed on Launchpad, not GitHub: - https://bugs.launchpad.net/os_failures + https://bugs.launchpad.net/os_faults diff --git a/HACKING.rst b/HACKING.rst index 7c135de..7eb1294 100644 --- a/HACKING.rst +++ b/HACKING.rst @@ -1,4 +1,4 @@ -os_failures Style Commandments +os_faults Style Commandments =============================================== Read the OpenStack Style Commandments http://docs.openstack.org/developer/hacking/ diff --git a/README.rst b/README.rst index b09275a..1eebb89 100644 --- a/README.rst +++ b/README.rst @@ -1,17 +1,17 @@ -=========== -os-failures -=========== +========= +os-faults +========= -**An OpenStack failures library** +**OpenStack faults injection library** -The library does destructive actions against OpenStack cloud. It provides +The library does destructive actions inside OpenStack cloud. It provides an abstraction layer over different type of cloud deployment. The actions are implemented as drivers (e.g. DevStack driver, Fuel driver, KVM driver etc.). * Free software: Apache license -* Documentation: http://os_failures.readthedocs.io -* Source: https://github.com/shakhat/os-failures -* Bugs: http://bugs.launchpad.net/os_failures +* Documentation: http://os-faults.readthedocs.io +* Source: https://github.com/openstack/os-faults +* Bugs: http://bugs.launchpad.net/os_faults Usage ----- @@ -44,7 +44,7 @@ Build the connection to the cloud deployment and verify it: .. code-block:: python - distractor = os_failures.connect(cloud_config) + distractor = os_faults.connect(cloud_config) distractor.verify() Make some distraction: @@ -69,7 +69,7 @@ Get a service and restart it: .. code-block:: python - distractor = os_failures.connect(cloud_config) + distractor = os_faults.connect(cloud_config) service = distractor.get_service(name='keystone-api') service.restart() diff --git a/doc/source/conf.py b/doc/source/conf.py index 8dcc230..7364be2 100755 --- a/doc/source/conf.py +++ b/doc/source/conf.py @@ -37,7 +37,7 @@ source_suffix = '.rst' master_doc = 'index' # General information about the project. -project = u'os_failures' +project = u'os-faults' copyright = u'2016, OpenStack Foundation' # If true, '()' will be appended to :func: etc. cross-reference text. diff --git a/doc/source/index.rst b/doc/source/index.rst index 9943f34..bd55981 100644 --- a/doc/source/index.rst +++ b/doc/source/index.rst @@ -1,10 +1,10 @@ -.. os_failures documentation master file, created by +.. os-faults documentation master file, created by sphinx-quickstart on Tue Jul 9 22:26:36 2013. You can adapt this file completely to your liking, but it should at least contain the root `toctree` directive. -Welcome to os_failures's documentation! -======================================================== +Welcome to os-faults's documentation! +===================================== Contents: diff --git a/doc/source/installation.rst b/doc/source/installation.rst index be6fd18..9d6dcf8 100644 --- a/doc/source/installation.rst +++ b/doc/source/installation.rst @@ -4,9 +4,9 @@ Installation At the command line:: - $ pip install os_failures + $ pip install os-faults Or, if you have virtualenvwrapper installed:: - $ mkvirtualenv os_failures - $ pip install os_failures + $ mkvirtualenv os-faults + $ pip install os-faults diff --git a/doc/source/usage.rst b/doc/source/usage.rst index 5ee038d..d2bcd5d 100644 --- a/doc/source/usage.rst +++ b/doc/source/usage.rst @@ -1,7 +1,7 @@ -======== +===== Usage -======== +===== -To use os_failures in a project:: +To use os-faults in a project:: - import os_failures + import os_faults diff --git a/examples/due.py b/examples/due.py index 3fa62b1..2048a17 100644 --- a/examples/due.py +++ b/examples/due.py @@ -12,7 +12,7 @@ import logging -import os_failures +import os_faults def main(): @@ -32,7 +32,7 @@ def main(): } logging.info('# Create connection') - distractor = os_failures.connect(cloud_config) + distractor = os_faults.connect(cloud_config) logging.info('# Verify connection to the cloud') distractor.verify() diff --git a/examples/fuel_distribute_key.sh b/examples/fuel_distribute_key.sh index 30e1801..5e16a0a 100755 --- a/examples/fuel_distribute_key.sh +++ b/examples/fuel_distribute_key.sh @@ -1,6 +1,6 @@ #!/bin/bash -x -KEY_FILE_NAME="${HOME}/.ssh/os_failures" +KEY_FILE_NAME="${HOME}/.ssh/os_faults" USERNAME="root" HOST="172.18.171.149" diff --git a/examples/power_off_on_ipmi_node.py b/examples/power_off_on_ipmi_node.py index 1e8fd86..305be6b 100644 --- a/examples/power_off_on_ipmi_node.py +++ b/examples/power_off_on_ipmi_node.py @@ -12,7 +12,7 @@ import logging -import os_failures +import os_faults def main(): @@ -42,7 +42,7 @@ def main(): } logging.info('Create connection to the cluster') - destructor = os_failures.connect(cloud_config) + destructor = os_faults.connect(cloud_config) logging.info('Verify connection to the cluster') destructor.verify() diff --git a/examples/power_off_on_vm_node.py b/examples/power_off_on_vm_node.py index f93d524..37aee34 100644 --- a/examples/power_off_on_vm_node.py +++ b/examples/power_off_on_vm_node.py @@ -12,7 +12,7 @@ import logging -import os_failures +import os_faults def main(): @@ -36,7 +36,7 @@ def main(): } logging.info('Create connection to the cluster') - destructor = os_failures.connect(cloud_config) + destructor = os_faults.connect(cloud_config) logging.info('Verify connection to the cluster') destructor.verify() diff --git a/examples/uno.py b/examples/uno.py index 417548b..14cc1a6 100644 --- a/examples/uno.py +++ b/examples/uno.py @@ -12,7 +12,7 @@ import logging -import os_failures +import os_faults def main(): @@ -37,12 +37,12 @@ def main(): } logging.info('# Create connection') - distractor = os_failures.connect(cloud_config) + distractor = os_faults.connect(cloud_config) logging.info('# Verify connection to the cloud') distractor.verify() - # os_failures library operate with 2 types of objects: + # os_faults library operate with 2 types of objects: # service - is software that runs in the cloud, e.g. keystone, mysql, # rabbitmq, nova-api, glance-api # nodes - nodes that host the cloud, e.g. hardware server with hostname diff --git a/os_failures/__init__.py b/os_faults/__init__.py similarity index 88% rename from os_failures/__init__.py rename to os_faults/__init__.py index 6304567..c3ab296 100644 --- a/os_failures/__init__.py +++ b/os_faults/__init__.py @@ -12,13 +12,13 @@ import pbr.version -from os_failures.drivers import devstack -from os_failures.drivers import fuel -from os_failures.drivers import ipmi -from os_failures.drivers import libvirt_driver +from os_faults.drivers import devstack +from os_faults.drivers import fuel +from os_faults.drivers import ipmi +from os_faults.drivers import libvirt_driver __version__ = pbr.version.VersionInfo( - 'os_failures').version_string() + 'os_faults').version_string() def connect(cloud_config): diff --git a/os_failures/ansible/__init__.py b/os_faults/ansible/__init__.py similarity index 100% rename from os_failures/ansible/__init__.py rename to os_faults/ansible/__init__.py diff --git a/os_failures/ansible/executor.py b/os_faults/ansible/executor.py similarity index 97% rename from os_failures/ansible/executor.py rename to os_faults/ansible/executor.py index f2768af..1a00a31 100644 --- a/os_failures/ansible/executor.py +++ b/os_faults/ansible/executor.py @@ -81,7 +81,7 @@ class MyCallback(callback_pkg.CallbackBase): def resolve_relative_path(file_name): path = os.path.normpath(os.path.join( - os.path.dirname(__import__('os_failures').__file__), '../', file_name)) + os.path.dirname(__import__('os_faults').__file__), '../', file_name)) if os.path.exists(path): return path @@ -99,7 +99,7 @@ class AnsibleRunner(object): ssh_common_args='', become=None): super(AnsibleRunner, self).__init__() - module_path = resolve_relative_path('os_failures/ansible/modules') + module_path = resolve_relative_path('os_faults/ansible/modules') ssh_common_args = ' '.join([ssh_common_args, SSH_COMMON_ARGS]) self.options = Options( diff --git a/os_failures/ansible/modules/__init__.py b/os_faults/ansible/modules/__init__.py similarity index 100% rename from os_failures/ansible/modules/__init__.py rename to os_faults/ansible/modules/__init__.py diff --git a/os_failures/ansible/modules/fuel_network_mgmt.py b/os_faults/ansible/modules/fuel_network_mgmt.py similarity index 100% rename from os_failures/ansible/modules/fuel_network_mgmt.py rename to os_faults/ansible/modules/fuel_network_mgmt.py diff --git a/os_failures/api/__init__.py b/os_faults/api/__init__.py similarity index 100% rename from os_failures/api/__init__.py rename to os_faults/api/__init__.py diff --git a/os_failures/api/cloud_management.py b/os_faults/api/cloud_management.py similarity index 100% rename from os_failures/api/cloud_management.py rename to os_faults/api/cloud_management.py diff --git a/os_failures/api/error.py b/os_faults/api/error.py similarity index 100% rename from os_failures/api/error.py rename to os_faults/api/error.py diff --git a/os_failures/api/node_collection.py b/os_faults/api/node_collection.py similarity index 100% rename from os_failures/api/node_collection.py rename to os_faults/api/node_collection.py diff --git a/os_failures/api/power_management.py b/os_faults/api/power_management.py similarity index 100% rename from os_failures/api/power_management.py rename to os_faults/api/power_management.py diff --git a/os_failures/api/service.py b/os_faults/api/service.py similarity index 100% rename from os_failures/api/service.py rename to os_faults/api/service.py diff --git a/os_failures/drivers/__init__.py b/os_faults/drivers/__init__.py similarity index 100% rename from os_failures/drivers/__init__.py rename to os_faults/drivers/__init__.py diff --git a/os_failures/drivers/devstack.py b/os_faults/drivers/devstack.py similarity index 96% rename from os_failures/drivers/devstack.py rename to os_faults/drivers/devstack.py index 23becc7..300e325 100644 --- a/os_failures/drivers/devstack.py +++ b/os_faults/drivers/devstack.py @@ -17,10 +17,10 @@ import logging import six -from os_failures.ansible import executor -from os_failures.api import cloud_management -from os_failures.api import node_collection -from os_failures.api import service +from os_faults.ansible import executor +from os_faults.api import cloud_management +from os_faults.api import node_collection +from os_faults.api import service HostClass = namedtuple('HostClass', ['ip', 'mac']) diff --git a/os_failures/drivers/fuel.py b/os_faults/drivers/fuel.py similarity index 98% rename from os_failures/drivers/fuel.py rename to os_faults/drivers/fuel.py index 2b1493d..382bcb1 100644 --- a/os_failures/drivers/fuel.py +++ b/os_faults/drivers/fuel.py @@ -17,11 +17,11 @@ import logging import random import six -from os_failures.ansible import executor -from os_failures.api import cloud_management -from os_failures.api import error -from os_failures.api import node_collection -from os_failures.api import service +from os_faults.ansible import executor +from os_faults.api import cloud_management +from os_faults.api import error +from os_faults.api import node_collection +from os_faults.api import service class FuelNodeCollection(node_collection.NodeCollection): diff --git a/os_failures/drivers/ipmi.py b/os_faults/drivers/ipmi.py similarity index 96% rename from os_failures/drivers/ipmi.py rename to os_faults/drivers/ipmi.py index 33c45b8..1c56711 100644 --- a/os_failures/drivers/ipmi.py +++ b/os_faults/drivers/ipmi.py @@ -16,9 +16,9 @@ import logging from pyghmi import exceptions as pyghmi_exception from pyghmi.ipmi import command as ipmi_command -from os_failures.api import error -from os_failures.api import power_management -from os_failures import utils +from os_faults.api import error +from os_faults.api import power_management +from os_faults import utils class IPMIDriver(power_management.PowerManagement): diff --git a/os_failures/drivers/libvirt_driver.py b/os_faults/drivers/libvirt_driver.py similarity index 95% rename from os_failures/drivers/libvirt_driver.py rename to os_faults/drivers/libvirt_driver.py index 594f619..df320ec 100644 --- a/os_failures/drivers/libvirt_driver.py +++ b/os_faults/drivers/libvirt_driver.py @@ -15,9 +15,9 @@ import logging import libvirt -from os_failures.api import error -from os_failures.api import power_management -from os_failures import utils +from os_faults.api import error +from os_faults.api import power_management +from os_faults import utils class LibvirtDriver(power_management.PowerManagement): diff --git a/os_failures/tests/__init__.py b/os_faults/tests/__init__.py similarity index 100% rename from os_failures/tests/__init__.py rename to os_faults/tests/__init__.py diff --git a/os_failures/tests/base.py b/os_faults/tests/base.py similarity index 100% rename from os_failures/tests/base.py rename to os_faults/tests/base.py diff --git a/os_failures/tests/test_os_failures.py b/os_faults/tests/test_os_failures.py similarity index 83% rename from os_failures/tests/test_os_failures.py rename to os_faults/tests/test_os_failures.py index 94c7989..aecadf5 100644 --- a/os_failures/tests/test_os_failures.py +++ b/os_faults/tests/test_os_failures.py @@ -11,16 +11,16 @@ # under the License. """ -test_os_failures +test_os_faults ---------------------------------- -Tests for `os_failures` module. +Tests for `os_faults` module. """ -from os_failures.tests import base +from os_faults.tests import base -class TestOs_failures(base.TestCase): +class Testos_faults(base.TestCase): def test_something(self): pass diff --git a/os_failures/utils.py b/os_faults/utils.py similarity index 97% rename from os_failures/utils.py rename to os_faults/utils.py index 577c3cc..2e1f224 100644 --- a/os_failures/utils.py +++ b/os_faults/utils.py @@ -15,7 +15,7 @@ import logging import threading import traceback -from os_failures.api import error +from os_faults.api import error def run(target, mac_addresses_list): diff --git a/releasenotes/source/conf.py b/releasenotes/source/conf.py index 5d4c497..818512a 100644 --- a/releasenotes/source/conf.py +++ b/releasenotes/source/conf.py @@ -55,7 +55,7 @@ source_suffix = '.rst' master_doc = 'index' # General information about the project. -project = u'os_failures Release Notes' +project = u'os_faults Release Notes' copyright = u'2016, OpenStack Foundation' # The version info for the project you're documenting, acts as replacement for diff --git a/releasenotes/source/index.rst b/releasenotes/source/index.rst index f134097..f1ff63b 100644 --- a/releasenotes/source/index.rst +++ b/releasenotes/source/index.rst @@ -1,5 +1,5 @@ ============================================ - os_failures Release Notes + os_faults Release Notes ============================================ .. toctree:: diff --git a/setup.cfg b/setup.cfg index 1e72b6e..9e01f30 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,5 +1,5 @@ [metadata] -name = os_failures +name = os_faults summary = OpenStack failures library description-file = README.rst @@ -15,12 +15,10 @@ classifier = Programming Language :: Python Programming Language :: Python :: 2 Programming Language :: Python :: 2.7 - Programming Language :: Python :: 3 - Programming Language :: Python :: 3.5 [files] packages = - os_failures + os_faults [build_sphinx] source-dir = doc/source @@ -31,18 +29,18 @@ all_files = 1 upload-dir = doc/build/html [compile_catalog] -directory = os_failures/locale -domain = os_failures +directory = os_faults/locale +domain = os_faults [update_catalog] -domain = os_failures -output_dir = os_failures/locale -input_file = os_failures/locale/os_failures.pot +domain = os_faults +output_dir = os_faults/locale +input_file = os_faults/locale/os_faults.pot [extract_messages] keywords = _ gettext ngettext l_ lazy_gettext mapping_file = babel.cfg -output_file = os_failures/locale/os_failures.pot +output_file = os_faults/locale/os_faults.pot [build_releasenotes] all_files = 1