How to trigger the failed build using Restart from stage without using UI

Viewed 81

I want to trigger the previously failed build using its build number and Failed stage name in declarative pipeline without using UI

Say for Ex:

  • Build #1 Failed at Deploy stage
  • I don't want to build or test the Build #1 again
  • I catch the failed stage details using ${env.FAILED_STAGE}
  • Trigger build #2 as Build #1 as input parameter and the failed stage value
  • Here is the counterpart, I am not sure how to use Restart from stage option in Jenkins file

Could someone help me on this

0 Answers
Related