@@ -1435,6 +1435,7 @@ Note: You can specify both CPU and memory together, or specify only one (the oth
14351435 return common .ExitWithErrorFromStatusCode (resp .StatusCode (), resp .JSON4XX )
14361436 }
14371437
1438+ service := * resp .JSON202
14381439 fmt .Fprintf (statusOutput , "✅ Resize request accepted for service '%s'!\n " , serviceID )
14391440
14401441 // Handle wait behavior
@@ -1446,12 +1447,14 @@ Note: You can specify both CPU and memory together, or specify only one (the oth
14461447 // Wait for resize to complete
14471448 fmt .Fprintf (statusOutput , "⏳ Waiting for resize to complete (timeout: %v)...\n " , resizeWaitTimeout )
14481449
1449- var dummyService api.Service
14501450 if err := common .WaitForService (cmd .Context (), common.WaitForServiceArgs {
1451- Client : cfg .Client ,
1452- ProjectID : cfg .ProjectID ,
1453- ServiceID : serviceID ,
1454- Handler : & common.StatusWaitHandler {TargetStatus : "READY" , Service : & dummyService },
1451+ Client : cfg .Client ,
1452+ ProjectID : cfg .ProjectID ,
1453+ ServiceID : serviceID ,
1454+ Handler : & common.StatusWaitHandler {
1455+ TargetStatus : "READY" ,
1456+ Service : & service ,
1457+ },
14551458 Output : statusOutput ,
14561459 Timeout : resizeWaitTimeout ,
14571460 TimeoutMsg : "resize may still be in progress" ,
@@ -1468,10 +1471,10 @@ Note: You can specify both CPU and memory together, or specify only one (the oth
14681471 }
14691472
14701473 // Add flags
1471- cmd .Flags ().StringVar (& resizeCPU , "cpu" , "" , "CPU allocation in millicores or 'shared' " )
1472- cmd .Flags ().StringVar (& resizeMemory , "memory" , "" , "Memory allocation in gigabytes or 'shared' " )
1474+ cmd .Flags ().StringVar (& resizeCPU , "cpu" , "" , "CPU allocation in millicores" )
1475+ cmd .Flags ().StringVar (& resizeMemory , "memory" , "" , "Memory allocation in gigabytes" )
14731476 cmd .Flags ().BoolVar (& resizeNoWait , "no-wait" , false , "Don't wait for resize operation to complete" )
1474- cmd .Flags ().DurationVar (& resizeWaitTimeout , "wait-timeout" , 30 * time .Minute , "Wait timeout duration (e.g., 30m, 1h30m, 90s) " )
1477+ cmd .Flags ().DurationVar (& resizeWaitTimeout , "wait-timeout" , 10 * time .Minute , "Maximum time to wait for operation to complete " )
14751478
14761479 return cmd
14771480}
0 commit comments