Allow configure cinder with the nfs driver

This patch allow to use nfs as cinder driver.

To use it, in the localrc we can now set

CINDER_DRIVER=nfs
CINDER_NFS_SERVERPATH=172.16.0.50:/export_cinder

The nfs-server is not setup by devstack.

Change-Id: I8e240d00b58f272d04ab2c0922c551b1f7266260
This commit is contained in:
Mehdi Abaakouk 2013-03-07 15:23:46 +00:00
parent 46b511f200
commit ae9c41727a

View File

@ -281,6 +281,11 @@ function configure_cinder() {
iniset $CINDER_CONF DEFAULT xenapi_nfs_server "$CINDER_XENAPI_NFS_SERVER"
iniset $CINDER_CONF DEFAULT xenapi_nfs_serverpath "$CINDER_XENAPI_NFS_SERVERPATH"
)
elif [ "$CINDER_DRIVER" == "nfs" ]; then
iniset $CINDER_CONF DEFAULT volume_driver "cinder.volume.drivers.nfs.NfsDriver"
iniset $CINDER_CONF DEFAULT nfs_shares_config "$CINDER_CONF_DIR/nfs_shares.conf"
echo "$CINDER_NFS_SERVERPATH" | sudo tee "$CINDER_CONF_DIR/nfs_shares.conf"
sudo chmod 666 $CINDER_CONF_DIR/nfs_shares.conf
elif [ "$CINDER_DRIVER" == "sheepdog" ]; then
iniset $CINDER_CONF DEFAULT volume_driver "cinder.volume.drivers.sheepdog.SheepdogDriver"
elif [ "$CINDER_DRIVER" == "glusterfs" ]; then