Skip to content

Commit e8c0ed7

Browse files
committed
Fix #858: split up docker compose build
Running locally, a plain `docker compose build` works as expected. On GitHub, buildx tries to build all 3 images in parallel even if you set `COMPOSE_PARALLEL_LIMIT` or use `--parallel 1`. That fails b/c the base image is not available to the other two build jobs.
1 parent 7932f78 commit e8c0ed7

1 file changed

Lines changed: 8 additions & 2 deletions

File tree

.github/workflows/ci_docker_tests.yaml

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,13 @@ jobs:
6666
submodules: recursive
6767

6868
- name: Build Docker images
69-
run: docker compose build
69+
run: |
70+
# Running locally, a plain "docker compose build" works as expected.
71+
# On GitHub, buildx tries to build all 3 images in parallel even if
72+
# you set COMPOSE_PARALLEL_LIMIT or use --parallel 1. That fails b/c
73+
# the qsim-base image is not available to the other two build jobs.
74+
docker compose build qsim-base-image
75+
docker compose build qsim-cxx-tests-image qsim-py-tests-image
7076
7177
- name: Run C++ tests
7278
run: docker run --rm qsim-cxx-tests:latest
@@ -75,7 +81,7 @@ jobs:
7581
run: docker run --rm qsim-py-tests:latest
7682

7783
- name: Run a sample simulation
78-
run: docker run --rm qsim:latest -c /qsim/circuits/circuit_q24
84+
run: docker run --rm qsim-base:latest -c /qsim/circuits/circuit_q24
7985

8086
- name: Test installation process
8187
run: |

0 commit comments

Comments
 (0)