Skip to content

Commit

Permalink
Merge pull request #2774 from saschagrunert/stage-verification
Browse files Browse the repository at this point in the history
Verify provided args on `krel stage`
  • Loading branch information
k8s-ci-robot committed Nov 29, 2022
2 parents 2a7e0e6 + efc3e93 commit 56f2f11
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions cmd/krel/cmd/stage.go
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,11 @@ func runStage(options *anago.StageOptions) error {
options.NoMock = rootOpts.nomock
stage := anago.NewStage(options)
if submitJob {
// Perform a local check of the specified options before launching a
// Cloud Build job:
if err := options.Validate(&anago.State{}); err != nil {
return fmt.Errorf("prechecking stage options: %w", err)
}
return stage.Submit(stream)
}
return stage.Run()
Expand Down

0 comments on commit 56f2f11

Please sign in to comment.