How to get sequencial job to execute even if previous ones fail


Given the following partial configuration, how can I make job2 execute no matter the status of job1 ?

  job1: ...
  job2: ...

      - job1
      - job2:
          - job1
1 Like

Hi @gempain! Thanks for coming back to the community. I would start with this post, which I think is trying to do the same thing. If that doesn’t address it, maybe you can explain some of the differences so we can investigate more.

Hi there, thanks for the reply. Yup, sounds like that thread is trying to do the same, but I feel like the example I gave is a little more straight forward.

I was aware that you could use when: always on a step inside a job, but that’s not what I’m looking for. What I want, is a way to say job2 should be executed after job1 is done, no matter the output of job1 (both on success or failure to be more accurate).

I’ll give you an example use case to show you why when: always at the step level isn’t sufficient. Say we have 3 jobs:

  • job1 runs tests in a node:11 Docker image
  • job2 runs tests in a node:12 Docker image
  • job3 sends a notification webhook with the status of the build

I want job3 to be executed after job1 AND after job2, whether one of them failed or not, because I’d like to send a webhook somwhere to say something like all jobs passed or some jobs failed.

1 Like

I think I understand. Let me look into it and I’ll try to respond ASAP.


@gempain This is not possible at the moment, but you can upvote this idea here to help us prioritize it. Thanks!