Don't set governor on VMs
Change-Id: Ifa26361845a6841eff1ab49e6d6542946898c426
diff --git a/linux/system/cpu.sls b/linux/system/cpu.sls
index c2821a1..5292585 100644
--- a/linux/system/cpu.sls
+++ b/linux/system/cpu.sls
@@ -17,6 +17,9 @@
- name: ondemand
- enable: false
+{%- if grains.get('virtual', None) in ['physical', None] %}
+{#- Governor cannot be set in VMs, etc. #}
+
/etc/sysfs.d/governor.conf:
file.managed:
- source: salt://linux/files/governor.conf.jinja
@@ -38,3 +41,5 @@
{%- endfor %}
{%- endif %}
+
+{%- endif %}