diff --git a/magnum_cluster_api/driver.py b/magnum_cluster_api/driver.py index 35c76072..fac9bde5 100644 --- a/magnum_cluster_api/driver.py +++ b/magnum_cluster_api/driver.py @@ -323,7 +323,9 @@ def update_nodegroup_status(self, context, cluster, nodegroup): nodegroup.status = f"{action}_COMPLETE" elif phase in ("Failed", "Unknown"): nodegroup.status = f"{action}_FAILED" - + # Note: Fetch node_count from md object when autoscaling enabled + if utils.get_auto_scaling_enabled(cluster): + nodegroup.node_count = md.obj["spec"]["replicas"] nodegroup.save() return nodegroup