How to run commands in parallel on 2.0?

circle.yml

#1

I’ve tried background to start a server (which lives inside docker) and hit it with a simple request:

        - type: shell
        name: Access Application
        command: |
            wget localhost:3000 \
                --retry-connrefused
                --tries 10
        background: true

      - type: shell
        name: Run Application
        command: docker run -p 3000:3000 $TAG

It doesn’t seem to work. The second command (starting the server) gets never executed. It starts when removing the first command (wget) though, but then again nothing else is executed.

Other things I’ve tried:

  1. switching the order and backgrounding the server command without success.
  2. adding background to both commands which results in the next command being executed straight away (shutting down the server)
  3. adding background to both commands and an additional sleep 5 afterwards results in my wget getting killed with “SIGHUP received, redirecting output to ‘wget-log’”

#2

What happened when you tried this? Can you link me to your builds?


#4