Przeglądaj źródła

CTS: sort the configuration - prevent duplicates in the config file

Signed-off-by: Angus Salkeld <asalkeld@redhat.com>
Angus Salkeld 15 lat temu
rodzic
commit
b1d65a7e8c
1 zmienionych plików z 2 dodań i 1 usunięć
  1. 2 1
      cts/corosync.py

+ 2 - 1
cts/corosync.py

@@ -180,7 +180,8 @@ class corosync_flatiron(ClusterManager):
 
     def install_all_config(self):
         tmp1 = {}
-        for c in self.new_config:
+        sorted_keys = sorted(self.new_config.keys())
+        for c in sorted_keys:
             self.log('configuring: ' + c + ' = '+ str(self.new_config[c]))
             self.config.set (c, self.new_config[c])
             self.applied_config[c] = self.new_config[c]