diff --git a/.gitignore b/.gitignore index 5430ee8..48bb813 100644 --- a/.gitignore +++ b/.gitignore @@ -19,5 +19,5 @@ ChangeLog doc/source/api/* doc/build/* dist -monikerclient/versioninfo +designateclient/versioninfo .testrepository diff --git a/.testr.conf b/.testr.conf index 08b650b..bd46664 100644 --- a/.testr.conf +++ b/.testr.conf @@ -1,4 +1,4 @@ [DEFAULT] -test_command=OS_STDOUT_CAPTURE=1 OS_STDERR_CAPTURE=1 ${PYTHON:-python} -m subunit.run discover -t ./ ./monikerclient/tests $LISTOPT $IDOPTION +test_command=OS_STDOUT_CAPTURE=1 OS_STDERR_CAPTURE=1 ${PYTHON:-python} -m subunit.run discover -t ./ ./designateclient/tests $LISTOPT $IDOPTION test_id_option=--load-list $IDFILE test_list_option=--list diff --git a/MANIFEST.in b/MANIFEST.in index 2921a60..57ab58b 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -1,8 +1,8 @@ include AUTHORS include ChangeLog -include monikerclient/versioninfo +include designateclient/versioninfo include *.txt *.ini *.cfg *.rst *.md -recursive-include monikerclient/resources * +recursive-include designateclient/resources * recursive-include tools * exclude .gitignore diff --git a/bin/moniker b/bin/designate similarity index 90% rename from bin/moniker rename to bin/designate index 833fa0c..510ff8f 100755 --- a/bin/moniker +++ b/bin/designate @@ -15,7 +15,7 @@ # License for the specific language governing permissions and limitations # under the License. import sys -from monikerclient.shell import MonikerShell +from designateclient.shell import DesignateShell -shell = MonikerShell() +shell = DesignateShell() sys.exit(shell.run(sys.argv[1:])) diff --git a/monikerclient/__init__.py b/designateclient/__init__.py similarity index 100% rename from monikerclient/__init__.py rename to designateclient/__init__.py diff --git a/monikerclient/auth.py b/designateclient/auth.py similarity index 97% rename from monikerclient/auth.py rename to designateclient/auth.py index 2299a74..3571e2a 100644 --- a/monikerclient/auth.py +++ b/designateclient/auth.py @@ -49,7 +49,7 @@ class KeystoneAuth(AuthBase): request.headers['X-Auth-Token'] = self.token if self.sudo_tenant_id: - request.headers['X-Moniker-Sudo-Tenant-ID'] = self.sudo_tenant_id + request.headers['X-Designate-Sudo-Tenant-ID'] = self.sudo_tenant_id return request diff --git a/monikerclient/cli/__init__.py b/designateclient/cli/__init__.py similarity index 100% rename from monikerclient/cli/__init__.py rename to designateclient/cli/__init__.py diff --git a/monikerclient/cli/base.py b/designateclient/cli/base.py similarity index 97% rename from monikerclient/cli/base.py rename to designateclient/cli/base.py index 434e21b..c9e46dd 100644 --- a/monikerclient/cli/base.py +++ b/designateclient/cli/base.py @@ -17,9 +17,9 @@ import abc from cliff.command import Command as CliffCommand from cliff.lister import Lister from cliff.show import ShowOne -from monikerclient import exceptions -from monikerclient import utils -from monikerclient.v1 import Client +from designateclient import exceptions +from designateclient import utils +from designateclient.v1 import Client class Command(CliffCommand): diff --git a/monikerclient/cli/diagnostics.py b/designateclient/cli/diagnostics.py similarity index 98% rename from monikerclient/cli/diagnostics.py rename to designateclient/cli/diagnostics.py index 0ff7b01..460b30a 100644 --- a/monikerclient/cli/diagnostics.py +++ b/designateclient/cli/diagnostics.py @@ -14,7 +14,7 @@ # License for the specific language governing permissions and limitations # under the License. import logging -from monikerclient.cli import base +from designateclient.cli import base LOG = logging.getLogger(__name__) diff --git a/monikerclient/cli/domains.py b/designateclient/cli/domains.py similarity index 97% rename from monikerclient/cli/domains.py rename to designateclient/cli/domains.py index 9e0884e..2672973 100644 --- a/monikerclient/cli/domains.py +++ b/designateclient/cli/domains.py @@ -14,8 +14,8 @@ # License for the specific language governing permissions and limitations # under the License. import logging -from monikerclient.cli import base -from monikerclient.v1.domains import Domain +from designateclient.cli import base +from designateclient.v1.domains import Domain LOG = logging.getLogger(__name__) diff --git a/monikerclient/cli/records.py b/designateclient/cli/records.py similarity index 98% rename from monikerclient/cli/records.py rename to designateclient/cli/records.py index 7f2f50c..cca7d03 100644 --- a/monikerclient/cli/records.py +++ b/designateclient/cli/records.py @@ -14,8 +14,8 @@ # License for the specific language governing permissions and limitations # under the License. import logging -from monikerclient.cli import base -from monikerclient.v1.records import Record +from designateclient.cli import base +from designateclient.v1.records import Record LOG = logging.getLogger(__name__) diff --git a/monikerclient/cli/reports.py b/designateclient/cli/reports.py similarity index 98% rename from monikerclient/cli/reports.py rename to designateclient/cli/reports.py index f1c7aa2..d628949 100644 --- a/monikerclient/cli/reports.py +++ b/designateclient/cli/reports.py @@ -13,7 +13,7 @@ # 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 monikerclient.cli import base +from designateclient.cli import base class DomainCountCommand(base.GetCommand): diff --git a/monikerclient/cli/servers.py b/designateclient/cli/servers.py similarity index 96% rename from monikerclient/cli/servers.py rename to designateclient/cli/servers.py index c393cdb..dc0832e 100644 --- a/monikerclient/cli/servers.py +++ b/designateclient/cli/servers.py @@ -14,8 +14,8 @@ # License for the specific language governing permissions and limitations # under the License. import logging -from monikerclient.cli import base -from monikerclient.v1.servers import Server +from designateclient.cli import base +from designateclient.v1.servers import Server LOG = logging.getLogger(__name__) diff --git a/monikerclient/exceptions.py b/designateclient/exceptions.py similarity index 100% rename from monikerclient/exceptions.py rename to designateclient/exceptions.py diff --git a/monikerclient/resources/schemas/v1/domain.json b/designateclient/resources/schemas/v1/domain.json similarity index 100% rename from monikerclient/resources/schemas/v1/domain.json rename to designateclient/resources/schemas/v1/domain.json diff --git a/monikerclient/resources/schemas/v1/record.json b/designateclient/resources/schemas/v1/record.json similarity index 100% rename from monikerclient/resources/schemas/v1/record.json rename to designateclient/resources/schemas/v1/record.json diff --git a/monikerclient/resources/schemas/v1/server.json b/designateclient/resources/schemas/v1/server.json similarity index 100% rename from monikerclient/resources/schemas/v1/server.json rename to designateclient/resources/schemas/v1/server.json diff --git a/monikerclient/shell.py b/designateclient/shell.py similarity index 85% rename from monikerclient/shell.py rename to designateclient/shell.py index 51881c0..c6ac42c 100644 --- a/monikerclient/shell.py +++ b/designateclient/shell.py @@ -17,23 +17,23 @@ import logging import os from cliff.app import App from cliff.commandmanager import CommandManager -from monikerclient.version import version_info as version +from designateclient.version import version_info as version -class MonikerShell(App): +class DesignateShell(App): CONSOLE_MESSAGE_FORMAT = '%(levelname)s: %(message)s' def __init__(self): - super(MonikerShell, self).__init__( - description='Moniker Client', + super(DesignateShell, self).__init__( + description='Designate Client', version=version.version_string(), - command_manager=CommandManager('monikerclient.cli'), + command_manager=CommandManager('designateclient.cli'), ) self.log = logging.getLogger(__name__) def configure_logging(self): - super(MonikerShell, self).configure_logging() + super(DesignateShell, self).configure_logging() # Set requests logging requests_logger = logging.getLogger('requests') @@ -44,7 +44,7 @@ class MonikerShell(App): requests_logger.setLevel(logging.DEBUG) def build_option_parser(self, description, version): - parser = super(MonikerShell, self).build_option_parser( + parser = super(DesignateShell, self).build_option_parser( description, version) parser.add_argument('--os-endpoint', @@ -86,7 +86,7 @@ class MonikerShell(App): help="Defaults to env[OS_REGION_NAME]") parser.add_argument('--sudo-tenant-id', - default=os.environ.get('MONIKER_SUDO_TENANT_ID'), - help="Defaults to env[MONIKER_SUDO_TENANT_ID]") + default=os.environ.get('DESIGNATE_SUDO_TENANT_ID'), + help="Defaults to env[DESIGNATE_SUDO_TENANT_ID]") return parser diff --git a/monikerclient/tests/__init__.py b/designateclient/tests/__init__.py similarity index 100% rename from monikerclient/tests/__init__.py rename to designateclient/tests/__init__.py diff --git a/monikerclient/utils.py b/designateclient/utils.py similarity index 97% rename from monikerclient/utils.py rename to designateclient/utils.py index 8618a10..61f669a 100644 --- a/monikerclient/utils.py +++ b/designateclient/utils.py @@ -16,7 +16,7 @@ import os import pkg_resources import json -from monikerclient import exceptions +from designateclient import exceptions def resource_string(*args, **kwargs): @@ -26,7 +26,7 @@ def resource_string(*args, **kwargs): package = kwargs.pop('package', None) if not package: - package = 'monikerclient' + package = 'designateclient' resource_path = os.path.join('resources', *args) diff --git a/monikerclient/v1/__init__.py b/designateclient/v1/__init__.py similarity index 94% rename from monikerclient/v1/__init__.py rename to designateclient/v1/__init__.py index c02052a..f4ea81b 100644 --- a/monikerclient/v1/__init__.py +++ b/designateclient/v1/__init__.py @@ -15,12 +15,12 @@ # under the License. import requests from stevedore import extension -from monikerclient import exceptions -from monikerclient.auth import KeystoneAuth +from designateclient import exceptions +from designateclient.auth import KeystoneAuth class Client(object): - """ Client for the Moniker v1 API """ + """ Client for the Designate v1 API """ def __init__(self, endpoint=None, auth_url=None, username=None, password=None, tenant_id=None, tenant_name=None, token=None, @@ -61,7 +61,7 @@ class Client(object): setattr(self, ext.name, controller) # Load all controllers - mgr = extension.ExtensionManager('monikerclient.v1.controllers') + mgr = extension.ExtensionManager('designateclient.v1.controllers') mgr.map(_load_controller) def wrap_api_call(self, func, *args, **kw): diff --git a/monikerclient/v1/base.py b/designateclient/v1/base.py similarity index 100% rename from monikerclient/v1/base.py rename to designateclient/v1/base.py diff --git a/monikerclient/v1/diagnostics.py b/designateclient/v1/diagnostics.py similarity index 97% rename from monikerclient/v1/diagnostics.py rename to designateclient/v1/diagnostics.py index f51f5f2..f38e737 100644 --- a/monikerclient/v1/diagnostics.py +++ b/designateclient/v1/diagnostics.py @@ -13,7 +13,7 @@ # 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 monikerclient.v1.base import Controller +from designateclient.v1.base import Controller class DiagnosticsController(Controller): diff --git a/monikerclient/v1/domains.py b/designateclient/v1/domains.py similarity index 95% rename from monikerclient/v1/domains.py rename to designateclient/v1/domains.py index e5870aa..c7afe38 100644 --- a/monikerclient/v1/domains.py +++ b/designateclient/v1/domains.py @@ -14,9 +14,9 @@ # License for the specific language governing permissions and limitations # under the License. import json -from monikerclient import warlock -from monikerclient import utils -from monikerclient.v1.base import CrudController +from designateclient import warlock +from designateclient import utils +from designateclient.v1.base import CrudController Domain = warlock.model_factory(utils.load_schema('v1', 'domain')) diff --git a/monikerclient/v1/records.py b/designateclient/v1/records.py similarity index 95% rename from monikerclient/v1/records.py rename to designateclient/v1/records.py index 750552d..d5467ae 100644 --- a/monikerclient/v1/records.py +++ b/designateclient/v1/records.py @@ -14,10 +14,10 @@ # License for the specific language governing permissions and limitations # under the License. import json -from monikerclient import warlock -from monikerclient import utils -from monikerclient.v1.base import CrudController -from monikerclient.v1.domains import Domain +from designateclient import warlock +from designateclient import utils +from designateclient.v1.base import CrudController +from designateclient.v1.domains import Domain Record = warlock.model_factory(utils.load_schema('v1', 'record')) diff --git a/monikerclient/v1/reports.py b/designateclient/v1/reports.py similarity index 97% rename from monikerclient/v1/reports.py rename to designateclient/v1/reports.py index 462fd18..3e247ad 100644 --- a/monikerclient/v1/reports.py +++ b/designateclient/v1/reports.py @@ -13,7 +13,7 @@ # 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 monikerclient.v1.base import Controller +from designateclient.v1.base import Controller class ReportsController(Controller): diff --git a/monikerclient/v1/servers.py b/designateclient/v1/servers.py similarity index 94% rename from monikerclient/v1/servers.py rename to designateclient/v1/servers.py index 5e50959..1e0b777 100644 --- a/monikerclient/v1/servers.py +++ b/designateclient/v1/servers.py @@ -14,9 +14,9 @@ # License for the specific language governing permissions and limitations # under the License. import json -from monikerclient import warlock -from monikerclient import utils -from monikerclient.v1.base import CrudController +from designateclient import warlock +from designateclient import utils +from designateclient.v1.base import CrudController Server = warlock.model_factory(utils.load_schema('v1', 'server')) diff --git a/monikerclient/version.py b/designateclient/version.py similarity index 90% rename from monikerclient/version.py rename to designateclient/version.py index fd80506..cd56b54 100644 --- a/monikerclient/version.py +++ b/designateclient/version.py @@ -15,4 +15,4 @@ # under the License. import pbr.version -version_info = pbr.version.VersionInfo('python-monikerclient') +version_info = pbr.version.VersionInfo('python-designateclient') diff --git a/monikerclient/warlock.py b/designateclient/warlock.py similarity index 100% rename from monikerclient/warlock.py rename to designateclient/warlock.py diff --git a/doc/source/conf.py b/doc/source/conf.py index 5004b8b..d81ad2d 100644 --- a/doc/source/conf.py +++ b/doc/source/conf.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- # -# monikerclient documentation build configuration file, created by +# designateclient documentation build configuration file, created by # sphinx-quickstart on Wed Oct 31 18:58:17 2012. # # This file is execfile()d with the current directory set to its containing dir. @@ -40,7 +40,7 @@ source_suffix = '.rst' master_doc = 'index' # General information about the project. -project = u'monikerclient' +project = u'designateclient' copyright = u'2012, Managed I.T.' # The version info for the project you're documenting, acts as replacement for @@ -48,10 +48,10 @@ copyright = u'2012, Managed I.T.' # built documents. # # The short X.Y version. -from monikerclient.version import version_info as monikerclient_version -version = monikerclient_version.canonical_version_string() +from designateclient.version import version_info as designateclient_version +version = designateclient_version.canonical_version_string() # The full version, including alpha/beta/rc tags. -release = monikerclient_version.version_string_with_vcs() +release = designateclient_version.version_string_with_vcs() # The language for content autogenerated by Sphinx. Refer to documentation # for a list of supported languages. @@ -165,7 +165,7 @@ html_static_path = ['_static'] #html_file_suffix = None # Output file base name for HTML help builder. -htmlhelp_basename = 'monikerclientdoc' +htmlhelp_basename = 'designateclientdoc' # -- Options for LaTeX output -------------------------------------------------- @@ -184,7 +184,7 @@ latex_elements = { # Grouping the document tree into LaTeX files. List of tuples # (source start file, target name, title, author, documentclass [howto/manual]). latex_documents = [ - ('index', 'monikerclient.tex', u'Moniker Client Documentation', + ('index', 'designateclient.tex', u'Designate Client Documentation', u'Managed I.T.', 'manual'), ] @@ -214,7 +214,7 @@ latex_documents = [ # One entry per manual page. List of tuples # (source start file, name, description, authors, manual section). man_pages = [ - ('index', 'monikerclient', u'Moniker Client Documentation', + ('index', 'designateclient', u'Designate Client Documentation', [u'Managed I.T.'], 1) ] @@ -228,8 +228,8 @@ man_pages = [ # (source start file, target name, title, author, # dir menu entry, description, category) texinfo_documents = [ - ('index', 'monikerclient', u'Moniker Client Documentation', - u'Managed I.T.', 'monikerclient', 'One line description of project.', + ('index', 'designateclient', u'Designate Client Documentation', + u'Managed I.T.', 'designateclient', 'One line description of project.', 'Miscellaneous'), ] diff --git a/doc/source/index.rst b/doc/source/index.rst index 1d3ef9e..e201836 100644 --- a/doc/source/index.rst +++ b/doc/source/index.rst @@ -1,9 +1,9 @@ -.. moniker documentation master file, created by +.. designate documentation master file, created by sphinx-quickstart on Wed Oct 31 18:58:17 2012. You can adapt this file completely to your liking, but it should at least contain the root `toctree` directive. -Welcome to monikerclients's documentation! +Welcome to designateclients's documentation! =================================== Contents: diff --git a/python-monikerclient.sublime-project b/python-designateclient.sublime-project similarity index 100% rename from python-monikerclient.sublime-project rename to python-designateclient.sublime-project diff --git a/setup.cfg b/setup.cfg index 5beea60..f067f43 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,12 +1,12 @@ [metadata] -name = python-monikerclient +name = python-designateclient version = 2013.1 summary = DNS as a Service - Client description-file = README.rst author = Kiall Mac Innes author-email = kiall@managedit.ie -home-page = https://launchpad.net/python-monikerclientclient +home-page = https://launchpad.net/python-designateclientclient classifier = Environment :: OpenStack Intended Audience :: Information Technology @@ -25,49 +25,49 @@ setup-hooks = [files] packages = - monikerclient + designateclient scripts = - bin/moniker + bin/designate [entry_points] -monikerclient.v1.controllers = - reports = monikerclient.v1.reports:ReportsController - diagnostics = monikerclient.v1.diagnostics:DiagnosticsController - domains = monikerclient.v1.domains:DomainsController - records = monikerclient.v1.records:RecordsController - servers = monikerclient.v1.servers:ServersController +designateclient.v1.controllers = + reports = designateclient.v1.reports:ReportsController + diagnostics = designateclient.v1.diagnostics:DiagnosticsController + domains = designateclient.v1.domains:DomainsController + records = designateclient.v1.records:RecordsController + servers = designateclient.v1.servers:ServersController -monikerclient.cli = - domain-list = monikerclient.cli.domains:ListDomainsCommand - domain-get = monikerclient.cli.domains:GetDomainCommand - domain-create = monikerclient.cli.domains:CreateDomainCommand - domain-update = monikerclient.cli.domains:UpdateDomainCommand - domain-delete = monikerclient.cli.domains:DeleteDomainCommand - domain-servers-list = monikerclient.cli.domains:ListDomainServersCommand +designateclient.cli = + domain-list = designateclient.cli.domains:ListDomainsCommand + domain-get = designateclient.cli.domains:GetDomainCommand + domain-create = designateclient.cli.domains:CreateDomainCommand + domain-update = designateclient.cli.domains:UpdateDomainCommand + domain-delete = designateclient.cli.domains:DeleteDomainCommand + domain-servers-list = designateclient.cli.domains:ListDomainServersCommand - record-list = monikerclient.cli.records:ListRecordsCommand - record-get = monikerclient.cli.records:GetRecordCommand - record-create = monikerclient.cli.records:CreateRecordCommand - record-update = monikerclient.cli.records:UpdateRecordCommand - record-delete = monikerclient.cli.records:DeleteRecordCommand + record-list = designateclient.cli.records:ListRecordsCommand + record-get = designateclient.cli.records:GetRecordCommand + record-create = designateclient.cli.records:CreateRecordCommand + record-update = designateclient.cli.records:UpdateRecordCommand + record-delete = designateclient.cli.records:DeleteRecordCommand - server-list = monikerclient.cli.servers:ListServersCommand - server-get = monikerclient.cli.servers:GetServerCommand - server-create = monikerclient.cli.servers:CreateServerCommand - server-update = monikerclient.cli.servers:UpdateServerCommand - server-delete = monikerclient.cli.servers:DeleteServerCommand + server-list = designateclient.cli.servers:ListServersCommand + server-get = designateclient.cli.servers:GetServerCommand + server-create = designateclient.cli.servers:CreateServerCommand + server-update = designateclient.cli.servers:UpdateServerCommand + server-delete = designateclient.cli.servers:DeleteServerCommand - diagnostics-ping = monikerclient.cli.diagnostics:PingCommand - diagnostics-sync-all = monikerclient.cli.diagnostics:SyncAllCommand - diagnostics-sync-domain = monikerclient.cli.diagnostics:SyncDomainCommand - diagnostics-sync-record = monikerclient.cli.diagnostics:SyncRecordCommand + diagnostics-ping = designateclient.cli.diagnostics:PingCommand + diagnostics-sync-all = designateclient.cli.diagnostics:SyncAllCommand + diagnostics-sync-domain = designateclient.cli.diagnostics:SyncDomainCommand + diagnostics-sync-record = designateclient.cli.diagnostics:SyncRecordCommand - report-count-all = monikerclient.cli.reports:CountsCommand - report-count-domains = monikerclient.cli.reports:DomainCountCommand - report-count-records = monikerclient.cli.reports:RecordCountCommand - report-count-tenants = monikerclient.cli.reports:TenantCountCommand - report-tenants-all = monikerclient.cli.reports:TenantsCommand - report-tenant-domains = monikerclient.cli.reports:TenantCommand + report-count-all = designateclient.cli.reports:CountsCommand + report-count-domains = designateclient.cli.reports:DomainCountCommand + report-count-records = designateclient.cli.reports:RecordCountCommand + report-count-tenants = designateclient.cli.reports:TenantCountCommand + report-tenants-all = designateclient.cli.reports:TenantsCommand + report-tenant-domains = designateclient.cli.reports:TenantCommand [build_sphinx] all_files = 1 @@ -80,15 +80,15 @@ tag_date = 0 tag_svn_revision = 0 [compile_catalog] -directory = monikerclient/locale -domain = monikerclient +directory = designateclient/locale +domain = designateclient [update_catalog] -domain = monikerclient -output_dir = monikerclient/locale -input_file = monikerclient/locale/monikerclient.pot +domain = designateclient +output_dir = designateclient/locale +input_file = designateclient/locale/designateclient.pot [extract_messages] keywords = _ gettext ngettext l_ lazy_gettext mapping_file = babel.cfg -output_file = monikerclient/locale/monikerclient.pot +output_file = designateclient/locale/designateclient.pot