Adding support for instances_path

Change-Id: Iaf4d6493c28274c7eba13035878bb185c0621aef
diff --git a/README.rst b/README.rst
index 1ae8d07..db620b6 100644
--- a/README.rst
+++ b/README.rst
@@ -273,6 +273,25 @@
 Client role
 -----------
 
+Nova configured with NFS
+
+.. code-block:: yaml
+
+    nova:
+      compute:
+        instances_path: /mnt/nova/instances
+
+    linux:
+      storage:
+        enabled: true
+        mount:
+          nfs_nova:
+            enabled: true
+            path: ${nova:compute:instances_path}
+            device: 172.31.35.145:/data
+            file_system: nfs
+            opts: rw,vers=3
+
 Nova flavors
 
 .. code-block:: yaml
diff --git a/nova/files/juno/nova-compute.conf.Debian b/nova/files/juno/nova-compute.conf.Debian
index bb4dba5..2220177 100644
--- a/nova/files/juno/nova-compute.conf.Debian
+++ b/nova/files/juno/nova-compute.conf.Debian
@@ -107,6 +107,8 @@
 
 {% endif %}
 
+instances_path = {{ compute.instances_path }}
+
 {%- if compute.notification is defined %}
 notification_driver = {{ compute.notification.driver }}
 
diff --git a/nova/files/kilo/nova-compute.conf.Debian b/nova/files/kilo/nova-compute.conf.Debian
index fcf3ae3..c3e197a 100644
--- a/nova/files/kilo/nova-compute.conf.Debian
+++ b/nova/files/kilo/nova-compute.conf.Debian
@@ -96,6 +96,8 @@
 
 {% endif %}
 
+instances_path = {{ compute.instances_path }}
+
 {%- if compute.notification is defined %}
 notification_driver = {{ compute.notification.driver }}
 
diff --git a/nova/files/liberty/nova-compute.conf.Debian b/nova/files/liberty/nova-compute.conf.Debian
index 283f9c4..21654cd 100644
--- a/nova/files/liberty/nova-compute.conf.Debian
+++ b/nova/files/liberty/nova-compute.conf.Debian
@@ -100,6 +100,8 @@
 instance_usage_audit_period = hour
 {% endif %}
 
+instances_path = {{ compute.instances_path }}
+
 {%- if compute.get('notification', {}).notify_on is defined %}
 {%- for key, value in compute.notification.notify_on.iteritems() %}
 notify_on_{{ key }} = {{ value }}
diff --git a/nova/files/mitaka/nova-compute.conf.Debian b/nova/files/mitaka/nova-compute.conf.Debian
index 7e94913..94b8f18 100644
--- a/nova/files/mitaka/nova-compute.conf.Debian
+++ b/nova/files/mitaka/nova-compute.conf.Debian
@@ -63,6 +63,8 @@
 instance_usage_audit_period = hour
 {%- endif %}
 
+instances_path = {{ compute.instances_path }}
+
 {%- if compute.get('notification', {}).notify_on is defined %}
 {%- for key, value in compute.notification.notify_on.iteritems() %}
 notify_on_{{ key }} = {{ value }}
diff --git a/nova/files/newton/nova-compute.conf.Debian b/nova/files/newton/nova-compute.conf.Debian
index 8b44941..464e346 100644
--- a/nova/files/newton/nova-compute.conf.Debian
+++ b/nova/files/newton/nova-compute.conf.Debian
@@ -80,6 +80,8 @@
 instance_usage_audit_period = hour
 {%- endif %}
 
+instances_path = {{ compute.instances_path }}
+
 {%- if compute.get('notification', {}).notify_on is defined %}
 {%- for key, value in compute.notification.notify_on.iteritems() %}
 notify_on_{{ key }} = {{ value }}
diff --git a/nova/files/ocata/nova-compute.conf.Debian b/nova/files/ocata/nova-compute.conf.Debian
index 42d913b..08e7d77 100644
--- a/nova/files/ocata/nova-compute.conf.Debian
+++ b/nova/files/ocata/nova-compute.conf.Debian
@@ -646,6 +646,7 @@
 #   Any string representing directory path.
 #  (string value)
 #instances_path=$state_path/instances
+instances_path = {{ compute.instances_path }}
 
 #
 # This option enables periodic compute.instance.exists notifications. Each
diff --git a/nova/map.jinja b/nova/map.jinja
index 8e19b15..3b66daf 100644
--- a/nova/map.jinja
+++ b/nova/map.jinja
@@ -48,6 +48,7 @@
         'bind': compute_bind_defaults,
         'debug': false,
         'libvirt': [],
+        'instances_path': '$state_path/instances',
         'notification': false,
         'availability_zone': None,
         'aggregates': [],