From: Daira Hopwood Date: Fri, 15 Feb 2013 03:13:13 +0000 (+0000) Subject: OpenStack: change provider names to rackspace.com and rackspace.co.uk. X-Git-Url: https://git.rkrishnan.org/specifications/%5B/%5D%20/flags/status?a=commitdiff_plain;h=0d78618c55a2bf847d603314b1cd86ef49f026bd;p=tahoe-lafs%2Ftahoe-lafs.git OpenStack: change provider names to rackspace.com and rackspace.co.uk. Signed-off-by: David-Sarah Hopwood --- diff --git a/src/allmydata/storage/backends/cloud/openstack/openstack_container.py b/src/allmydata/storage/backends/cloud/openstack/openstack_container.py index afc41e90..0aa20996 100644 --- a/src/allmydata/storage/backends/cloud/openstack/openstack_container.py +++ b/src/allmydata/storage/backends/cloud/openstack/openstack_container.py @@ -24,13 +24,13 @@ UNSAFE_DEBUG = False DEFAULT_AUTH_URLS = { - "rackspace": "https://identity.api.rackspacecloud.com/v1.0", - "rackspace-uk": "https://lon.identity.api.rackspacecloud.com/v1.0", + "rackspace.com": "https://identity.api.rackspacecloud.com/v1.0", + "rackspace.co.uk": "https://lon.identity.api.rackspacecloud.com/v1.0", } def configure_openstack_container(storedir, config): api_key = config.get_or_create_private_config("openstack_api_key") - provider = config.get_config("storage", "openstack.provider", "rackspace").lower() + provider = config.get_config("storage", "openstack.provider", "rackspace.com").lower() if provider not in DEFAULT_AUTH_URLS: raise InvalidValueError("[storage]openstack.provider %r is not recognized\n" "Valid providers are: %s" % (provider, ", ".join(DEFAULT_AUTH_URLS.keys()))) diff --git a/src/allmydata/test/test_client.py b/src/allmydata/test/test_client.py index ab3b0f6a..7eb58f4f 100644 --- a/src/allmydata/test/test_client.py +++ b/src/allmydata/test/test_client.py @@ -357,13 +357,13 @@ class Basic(testutil.ReallyEqualMixin, unittest.TestCase): "[storage]\n" + "enabled = true\n" + "backend = cloud.openstack\n" + - "openstack.provider = rackspace\n" + + "openstack.provider = rackspace.com\n" + "openstack.username = alex\n" + "openstack.container = test\n") fileutil.write(os.path.join(basedir, "tahoe.cfg"), config) c = client.Client(basedir) - mock_AuthenticationClient.assert_called_with("dummy", "rackspace", + mock_AuthenticationClient.assert_called_with("dummy", "rackspace.com", "https://identity.api.rackspacecloud.com/v1.0", "alex", 23*60*60) container_call_args = mock_OpenStackContainer.call_args_list @@ -382,7 +382,7 @@ class Basic(testutil.ReallyEqualMixin, unittest.TestCase): "enabled = true\n" + "readonly = true\n" + "backend = cloud.openstack\n" + - "openstack.provider = rackspace\n" + + "openstack.provider = rackspace.com\n" + "openstack.username = alex\n" + "openstack.container = test\n") self.failUnlessRaises(InvalidValueError, client.Client, basedir) @@ -396,7 +396,7 @@ class Basic(testutil.ReallyEqualMixin, unittest.TestCase): "[storage]\n" + "enabled = true\n" + "backend = cloud.openstack\n" + - "openstack.provider = rackspace\n" + + "openstack.provider = rackspace.com\n" + "openstack.container = test\n") self.failUnlessRaises(MissingConfigEntry, client.Client, basedir) @@ -409,7 +409,7 @@ class Basic(testutil.ReallyEqualMixin, unittest.TestCase): "[storage]\n" + "enabled = true\n" + "backend = cloud.openstack\n" + - "openstack.provider = rackspace\n" + + "openstack.provider = rackspace.com\n" + "openstack.username = alex\n") self.failUnlessRaises(MissingConfigEntry, client.Client, basedir) @@ -421,7 +421,7 @@ class Basic(testutil.ReallyEqualMixin, unittest.TestCase): "[storage]\n" + "enabled = true\n" + "backend = cloud.openstack\n" + - "openstack.provider = rackspace\n" + + "openstack.provider = rackspace.com\n" + "openstack.username = alex\n" + "openstack.container = test\n") self.failUnlessRaises(MissingConfigEntry, client.Client, basedir) diff --git a/src/allmydata/test/test_storage.py b/src/allmydata/test/test_storage.py index 6e8be1d1..8a00f8b8 100644 --- a/src/allmydata/test/test_storage.py +++ b/src/allmydata/test/test_storage.py @@ -408,7 +408,7 @@ class CloudCommon(unittest.TestCase, ShouldFailMixin, WorkdirMixin): class OpenStackCloudBackend(ServiceParentMixin, WorkdirMixin, ShouldFailMixin, unittest.TestCase): - PROVIDER = "rackspace" + PROVIDER = "rackspace.com" AUTH_SERVICE_URL = "auth_service_url" USERNAME = "username" CONTAINER = "container"