summaryrefslogtreecommitdiffstats
path: root/src/pybind/mgr/nfs/tests/test_nfs.py
diff options
context:
space:
mode:
authorSage Weil <sage@newdream.net>2021-07-02 18:39:29 +0200
committerSage Weil <sage@newdream.net>2021-07-14 22:20:11 +0200
commit82e939d89c3b6e2ce6faad9a5315c5372fef341d (patch)
tree7a2be7ed6d68218afb43adbf52d5303b3e908092 /src/pybind/mgr/nfs/tests/test_nfs.py
parentmgr/nfs/export: accept a JSON or ganesha EXPORT config (diff)
downloadceph-82e939d89c3b6e2ce6faad9a5315c5372fef341d.tar.xz
ceph-82e939d89c3b6e2ce6faad9a5315c5372fef341d.zip
mgr/nfs: change nfs pool to .nfs
This is a new pool that we can migrate all past NFS configuration to, simplifying the migration process (and also allowing us to pick a .-prefixed name). Signed-off-by: Sage Weil <sage@newdream.net>
Diffstat (limited to 'src/pybind/mgr/nfs/tests/test_nfs.py')
-rw-r--r--src/pybind/mgr/nfs/tests/test_nfs.py22
1 files changed, 10 insertions, 12 deletions
diff --git a/src/pybind/mgr/nfs/tests/test_nfs.py b/src/pybind/mgr/nfs/tests/test_nfs.py
index 3e1911d7279..c21139e4fba 100644
--- a/src/pybind/mgr/nfs/tests/test_nfs.py
+++ b/src/pybind/mgr/nfs/tests/test_nfs.py
@@ -83,13 +83,13 @@ EXPORT
conf_nodeb = '%url "rados://ganesha/ns/export-1"'
conf_nfs_foo = '''
-%url "rados://nfs-ganesha/foo/export-1"
+%url "rados://.nfs/foo/export-1"
-%url "rados://nfs-ganesha/foo/export-2"'''
+%url "rados://.nfs/foo/export-2"'''
clusters = {
'foo': {
- 'pool': 'nfs-ganesha',
+ 'pool': '.nfs',
'namespace': 'foo',
'type': "ORCHESTRATOR",
'daemon_conf': 'conf-nfs.foo',
@@ -166,9 +166,7 @@ EXPORT
# mock nfs services
cluster_info = self.clusters['foo']
orch_nfs_services = [
- ServiceDescription(spec=NFSServiceSpec(service_id='foo',
- pool=cluster_info['pool'],
- namespace=cluster_info['namespace']))
+ ServiceDescription(spec=NFSServiceSpec(service_id='foo'))
] if enable else []
"""
@@ -271,17 +269,17 @@ EXPORT
"minor_versions": [1, 2]
}),
RawBlock('RADOS_KV', values={
- "pool": "nfs-ganesha",
+ "pool": ".nfs",
"namespace": "vstart",
"userid": "vstart",
"nodeid": "a"
}),
RawBlock('RADOS_URLS', values={
"userid": "vstart",
- "watch_url": "'rados://nfs-ganesha/vstart/conf-nfs.vstart'"
+ "watch_url": "'rados://.nfs/vstart/conf-nfs.vstart'"
}),
RawBlock('%url', values={
- "value": "rados://nfs-ganesha/vstart/conf-nfs.vstart"
+ "value": "rados://.nfs/vstart/conf-nfs.vstart"
})
]
daemon_raw_config = """
@@ -302,7 +300,7 @@ NFS_CORE_PARAM {
}
RADOS_KV {
- pool = nfs-ganesha;
+ pool = .nfs;
namespace = vstart;
UserId = vstart;
nodeid = a;
@@ -310,10 +308,10 @@ NFS_CORE_PARAM {
RADOS_URLS {
Userid = vstart;
- watch_url = 'rados://nfs-ganesha/vstart/conf-nfs.vstart';
+ watch_url = 'rados://.nfs/vstart/conf-nfs.vstart';
}
- %url rados://nfs-ganesha/vstart/conf-nfs.vstart
+ %url rados://.nfs/vstart/conf-nfs.vstart
"""
daemon_config = GaneshaConfParser(daemon_raw_config).parse()
assert daemon_config == expected_daemon_config