attempts
step modifier
Any step can set the number of times it should be attempted by attaching an attempts
parameter with the number of times it should be tried.
Attempts will retry on a Concourse error as well as build failure.
attempts: integer
The total number of times a step should be tried should it fail, e.g. 5
will try the step up to 5 times before giving up.
When the number of attempts is reached and the step has still not succeeded then the step will fail.
Examples
Retrying a Task
The following will run the task, and retry it 9 times (for a total of 10 attempts) if it fails:
plan:
- get: foo
- task: unit
file: foo/unit.yml
attempts: 10