Skip to content

Commit aa47cb3

Browse files
committed
Add config options for cinder nfs backend
Currently the cinder nfs backend leaves out few options in a multi backend deployment. It works in single nfs backend deployment as devstack-plugin-nfs correctly configures all options[1]. We can clearly see the difference between what devstack-plugin-nfs configures[1] and what devstack nfs configures[2]. Following options are missing which are added by this patch. * nas_host * nas_share_path * nas_secure_file_operations * nas_secure_file_permissions * nfs_snapshot_support [1] https://github.com/openstack/devstack-plugin-nfs/blob/dd12367f90fc86d42bfebe8a0ebb694dc0308810/devstack/plugin.sh#L60-L68 [2] https://github.com/openstack/devstack/blob/a52041cd3f067156e478e355f5712a60e12ce649/lib/cinder_backends/nfs#L32-L34 Change-Id: I03cad66abb3c6f2ae1d5cf943ac952a30961f783
1 parent a52041c commit aa47cb3

1 file changed

Lines changed: 9 additions & 0 deletions

File tree

  • lib/cinder_backends

lib/cinder_backends/nfs

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,15 @@ function configure_cinder_backend_nfs {
3232
iniset $CINDER_CONF $be_name volume_backend_name $be_name
3333
iniset $CINDER_CONF $be_name volume_driver "cinder.volume.drivers.nfs.NfsDriver"
3434
iniset $CINDER_CONF $be_name nfs_shares_config "$CINDER_CONF_DIR/nfs-shares-$be_name.conf"
35+
iniset $CINDER_CONF $be_name nas_host localhost
36+
iniset $CINDER_CONF $be_name nas_share_path ${NFS_EXPORT_DIR}
37+
iniset $CINDER_CONF $be_name nas_secure_file_operations \
38+
${NFS_SECURE_FILE_OPERATIONS}
39+
iniset $CINDER_CONF $be_name nas_secure_file_permissions \
40+
${NFS_SECURE_FILE_PERMISSIONS}
41+
42+
# NFS snapshot support is currently opt-in only.
43+
iniset $CINDER_CONF $be_name nfs_snapshot_support True
3544

3645
echo "$CINDER_NFS_SERVERPATH" | tee "$CINDER_CONF_DIR/nfs-shares-$be_name.conf"
3746
}

0 commit comments

Comments
 (0)