mirror of
https://github.com/psviderski/uncloud.git
synced 2026-10-08 22:24:54 +00:00
refactor: postpone spec resolver initialisation when creating Deployment
This commit is contained in:
1 parent
2d923380a3
commit
58b51b974c
10 files changed
+48
-90
No files matched your search
@@ -88,12 +88,7 @@ func scale(ctx context.Context, uncli *cli.CLI, opts scaleOptions) error {
|
||||
}
|
||||
|
||||
spec.Replicas = opts.replicas
|
||||
|
||||
deployment, err := clusterClient.NewDeployment(ctx, spec, nil)
|
||||
if err != nil {
|
||||
return fmt.Errorf("create deployment: %w", err)
|
||||
}
|
||||
|
||||
deployment := clusterClient.NewDeployment(spec, nil)
|
||||
plan, err := deployment.Plan(ctx)
|
||||
if err != nil {
|
||||
return fmt.Errorf("plan deployment: %w", err)
|
||||
|
||||
Reference in new issue
Block a user