File tree Expand file tree Collapse file tree 1 file changed +12
-1
lines changed Expand file tree Collapse file tree 1 file changed +12
-1
lines changed Original file line number Diff line number Diff line change @@ -99,14 +99,25 @@ def enable_autoprovisioning_on_cluster(
9999 f' --region={ zone_to_region (args .zone )} --enable-autoprovisioning'
100100 ' --autoprovisioning-config-file'
101101 f' { autoprovisioning_config .config_filename } '
102- ' --autoscaling-profile=optimize-utilization'
103102 )
104103 task = 'Update cluster with autoprovisioning enabled'
105104 return_code = run_command_with_updates (command , task , args )
106105 if return_code != 0 :
107106 xpk_print (f'{ task } request returned ERROR { return_code } ' )
108107 return autoprovisioning_config , return_code
109108
109+ command = (
110+ 'gcloud container clusters update'
111+ f' { args .cluster } --project={ args .project } '
112+ f' --region={ zone_to_region (args .zone )} '
113+ ' --autoscaling-profile=optimize-utilization'
114+ )
115+ task = 'Update cluster with autoscaling-profile'
116+ return_code = run_command_with_updates (command , task , args )
117+ if return_code != 0 :
118+ xpk_print (f'{ task } request returned ERROR { return_code } ' )
119+ return autoprovisioning_config , return_code
120+
110121 # Update created accelerator node pools to support autoprovisioning.
111122 existing_node_pool_names , return_code = get_all_nodepools_programmatic (args )
112123 if return_code != 0 :
You can’t perform that action at this time.
0 commit comments