]> review.fuel-infra Code Review - puppet-modules/puppet-ceilometer.git/commitdiff
Fix adding notification_driver parameters to the nova.conf
authorFrançois Charlier <francois.charlier@enovance.com>
Mon, 18 Feb 2013 17:33:02 +0000 (18:33 +0100)
committerFrançois Charlier <francois.charlier@enovance.com>
Mon, 18 Feb 2013 17:33:02 +0000 (18:33 +0100)
manifests/agent/compute.pp

index a8e1059b9bd3893e225c237892b0ed336eff6eaa..a2ccd833ec10b14d4ec25f3fc23dfe100655c322 100644 (file)
@@ -56,20 +56,21 @@ class ceilometer::agent::compute(
   }
 
   Nova_config<| |> {
-    before +> Exec[
+    before +> File_line[
       'nova-notification-driver-common',
       'nova-notification-driver-ceilometer'
     ],
   }
 
-  exec { 'nova-notification-driver-common':
-    command => 'git config --file nova.conf --add notification_driver nova.openstack.common.notifier.rabbit_notifier',
-    onlyif  => 'git config --file nova.conf --get notification_driver nova.openstack.common.notifier.rabbit_notifier',
-  }
+  File_line['nova-notification-driver-common', 'nova-notification-driver-ceilometer'] ~> Service['nova-compute']
 
-  exec { 'nova-notification-driver-ceilometer':
-    command => 'git config --file nova.conf --add notification_driver ceilometer.compute.nova_notifier',
-    onlyif  => 'git config --file nova.conf --get notification_driver ceilometer.compute.nova_notifier',
+  file_line {
+    'nova-notification-driver-common':
+      line => 'notification_driver=nova.openstack.common.notifier.rabbit_notifier',
+      path => '/etc/nova/nova.conf';
+    'nova-notification-driver-ceilometer':
+      line => 'notification_driver=ceilometer.compute.nova_notifier',
+      path => '/etc/nova/nova.conf';
   }
 
 }