Wait for parallel steps to finish


Is there a way to wait for all parallel steps to finish to before continuing on the next step?


You can use a deploy step for that;


      - run:
          name: Linting
          command: |
            if [ "$CIRCLE_NODE_INDEX" -eq "0" ]; then
              bundle exec rake rubocop
      - deploy:
          name: Staging Deploy
          command: |
            if [ "${CIRCLE_BRANCH}" == "staging" ]; then
              bundle exec cap staging deploy
          background: true
       - run:
          name: All ActiveSupport::TestCase tests
          command: bundle exec rails test

I’d like to do something like this. Where it deploys to staging after linting, but before running all the tests. Currently the deploy step just hangs on “Waiting for parallel steps to finish”


The deploy step does exactly this:

There is no other way to pause the build for other containers to finish a given task. Your best bet is to change that deploy back to a run if you want to parallelize the tests.


This topic was automatically closed 41 days after the last reply. New replies are no longer allowed.