Commits

Enis Afgan committed 759a4ef

Store deployment_version in cluster config only if it's a new cluster or migrations ran

Comments (0)

Files changed (1)

cm/util/master.py

             cc['services'] = svcs
             cc['cluster_type'] = self.app.manager.initial_cluster_type
             cc['persistent_data_version'] = self.app.PERSISTENT_DATA_VERSION
-            cc['deployment_version'] = self.app.ud.get('deployment_version', self.app.DEPLOYMENT_VERSION)
+            # If 'deployment_version' is not in UD, don't store it in the config
+            if 'deployment_version' in self.app.ud:
+                cc['deployment_version'] = self.app.ud['deployment_version']
             misc.dump_yaml_to_file(cc, file_name)
             # Reload the user data object in case anything has changed
             self.app.ud = misc.merge_yaml_objects(cc, self.app.ud)