CORD-1486 Set kernel boot options for nodes

Top-level config option like shown below should set the kernel boot options for the nodes.

kernel_opts: '''isolcpus=1-2 nohz_full=1-2 rcu_nocbs=1-2 hugepagesz=2M hugepages=1024'''

Change-Id: I36198254f220f04c192b0417b5926f3427db0033
diff --git a/build.gradle b/build.gradle
index 9d4b45c..1254337 100644
--- a/build.gradle
+++ b/build.gradle
@@ -311,6 +311,7 @@
             .p(config.common.virtualbox_support, "virtualbox_support")
             .p(config.common.power_helper_user, "power_helper_user")
             .p(config.common.power_helper_host, "power_helper_host")
+            .p(config.common.kernel_opts, "kernel_opts")
     }
 
     if (config.passwords) {
@@ -372,6 +373,7 @@
             .p(config.common.virtualbox_support, "virtualbox_support")
             .p(config.common.power_helper_user, "power_helper_user")
             .p(config.common.power_helper_host, "power_helper_host")
+            .p(config.common.kernel_opts, "kernel_opts")
     }
 
     if (config.passwords) {
diff --git a/roles/maas/defaults/main.yml b/roles/maas/defaults/main.yml
index 7d677a8..2469dd6 100644
--- a/roles/maas/defaults/main.yml
+++ b/roles/maas/defaults/main.yml
@@ -25,6 +25,7 @@
     #   'domain' specifies the domain name configured in to MAAS
     domain: "{{ domain | default('cord.lab') }}"
     upstream_dns: "{{ upstream_dns | default('8.8.8.8 8.8.8.4') }}"
+    kernel_opts: "{{ kernel_opts | default('') }}"
 
 interfaces:
     # CHANGE:
diff --git a/roles/maas/tasks/config-maas.yml b/roles/maas/tasks/config-maas.yml
index d7e0d1c..761eebb 100644
--- a/roles/maas/tasks/config-maas.yml
+++ b/roles/maas/tasks/config-maas.yml
@@ -67,6 +67,13 @@
     upstream_dns: '{{maas.upstream_dns}}'
     state: present
 
+- name: Set Kernel options for performance
+  maas:
+    key: '{{apikey.stdout}}'
+    maas: 'http://{{mgmt_ip_address.stdout}}/MAAS/api/1.0'
+    kernel_opts: '{{maas.kernel_opts}}'
+    state: present
+
 - name: Ensure Boot Resources
   maas_boot_resource:
     key: '{{apikey.stdout}}'