Merge "Unhardcoding libvirt group name parameter for socket. Upgrade path"
diff --git a/README.rst b/README.rst
index 239fce5..e5dc847 100644
--- a/README.rst
+++ b/README.rst
@@ -209,6 +209,18 @@
           max_files: 4096
           max_processes: 4096
 
+Group membership for user nova (upgrade related)
+
+.. code-block:: yaml
+
+    nova:
+      compute:
+        enabled: true
+        ...
+        user:
+          groups:
+          - libvirt
+
 Nova services on compute node with OpenContrail
 
 .. code-block:: yaml
diff --git a/nova/compute.sls b/nova/compute.sls
index f2e9f18..128c570 100644
--- a/nova/compute.sls
+++ b/nova/compute.sls
@@ -43,8 +43,12 @@
   - name: nova
   - home: /var/lib/nova
   - shell: /bin/bash
+{%- if compute.user.groups is defined %}
+  - groups: {{ compute.user.groups }}
+{%- else %}
   - groups:
     - libvirtd
+{%- endif %}
 
 /var/lib/nova/.ssh/id_rsa:
   file.managed: