a stack that will not come up now says what compose said, and the runner gets buildx
Run 2344 on 4e303cd: lint green (the two SC2086 findings are gone), source green,
image and console still red — both at `- starting the stack / compose up failed`.
In the image job the docker install worked and `docker build` produced
openwaf:ci 258MB, so the CLI cause is closed; what fails now is compose, and the
gate threw compose's own output away at the one moment that decides whether the
rest of the run means anything. Both gates now write it to a temp log and print
it on failure.
The stack itself is not the suspect: scripts/compose-smoke.sh on this tree, on a
daemon of its own (COMPOSE_PROJECT_NAME=openwaflocal, EDGE_PORT=18085), reports
348 passed / 0 failed — including the shipped-image preview scenes. So the
remaining difference is the runner's client side, and `docker compose up --build`
reaches the daemon through buildx, which the install step did not put in. Added,
with `docker buildx version` printed next to `docker compose version` so the next
log names all three versions that actually ran.
shellcheck 0.11.0 clean over scripts/*.sh.
This commit is contained in:
@@ -171,8 +171,10 @@ jobs:
|
||||
# the docker CLI. Measured, not guessed: the first real run of this file
|
||||
# (Gitea Actions run 2316, head 6f92d37) died here with
|
||||
# `./scripts/ci-gates.sh: line 44: docker: command not found`, exit 127.
|
||||
# /var/run/docker.sock is mounted from the host, so the CLI and the compose
|
||||
# v2 plugin are all that is missing — the same install the neemle-landing
|
||||
# /var/run/docker.sock is mounted from the host, so what is missing is the
|
||||
# client side: the CLI, the compose v2 plugin, and buildx — `docker compose
|
||||
# up --build` reaches the daemon through buildx, so the compose plugin alone
|
||||
# does not bring this stack up. The same install the neemle-landing
|
||||
# pipeline on this instance uses. Pinned to the Debian bookworm docker.com
|
||||
# repo so the version does not drift with the image.
|
||||
- name: Install Docker CLI + compose plugin
|
||||
@@ -191,7 +193,7 @@ jobs:
|
||||
echo "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/debian bookworm stable" \
|
||||
> /etc/apt/sources.list.d/docker.list
|
||||
apt-get update -qq
|
||||
apt-get install -qq -y docker-ce-cli docker-compose-plugin >/dev/null
|
||||
apt-get install -qq -y docker-ce-cli docker-compose-plugin docker-buildx-plugin >/dev/null
|
||||
fi
|
||||
# compose-smoke.sh calls `docker compose`, and every command in it
|
||||
# talks to the host daemon over the mounted socket. A missing socket is
|
||||
@@ -199,6 +201,7 @@ jobs:
|
||||
# three steps later as a broken product.
|
||||
docker --version
|
||||
docker compose version
|
||||
docker buildx version
|
||||
[ -S /var/run/docker.sock ] || { echo "no /var/run/docker.sock on this runner"; exit 1; }
|
||||
docker info --format 'daemon {{.ServerVersion}} on {{.OperatingSystem}}'
|
||||
|
||||
@@ -253,8 +256,10 @@ jobs:
|
||||
# the docker CLI. Measured, not guessed: the first real run of this file
|
||||
# (Gitea Actions run 2316, head 6f92d37) died here with
|
||||
# `./scripts/ci-gates.sh: line 44: docker: command not found`, exit 127.
|
||||
# /var/run/docker.sock is mounted from the host, so the CLI and the compose
|
||||
# v2 plugin are all that is missing — the same install the neemle-landing
|
||||
# /var/run/docker.sock is mounted from the host, so what is missing is the
|
||||
# client side: the CLI, the compose v2 plugin, and buildx — `docker compose
|
||||
# up --build` reaches the daemon through buildx, so the compose plugin alone
|
||||
# does not bring this stack up. The same install the neemle-landing
|
||||
# pipeline on this instance uses. Pinned to the Debian bookworm docker.com
|
||||
# repo so the version does not drift with the image.
|
||||
- name: Install Docker CLI + compose plugin
|
||||
@@ -273,7 +278,7 @@ jobs:
|
||||
echo "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/debian bookworm stable" \
|
||||
> /etc/apt/sources.list.d/docker.list
|
||||
apt-get update -qq
|
||||
apt-get install -qq -y docker-ce-cli docker-compose-plugin >/dev/null
|
||||
apt-get install -qq -y docker-ce-cli docker-compose-plugin docker-buildx-plugin >/dev/null
|
||||
fi
|
||||
# compose-smoke.sh calls `docker compose`, and every command in it
|
||||
# talks to the host daemon over the mounted socket. A missing socket is
|
||||
@@ -281,6 +286,7 @@ jobs:
|
||||
# three steps later as a broken product.
|
||||
docker --version
|
||||
docker compose version
|
||||
docker buildx version
|
||||
[ -S /var/run/docker.sock ] || { echo "no /var/run/docker.sock on this runner"; exit 1; }
|
||||
docker info --format 'daemon {{.ServerVersion}} on {{.OperatingSystem}}'
|
||||
|
||||
|
||||
@@ -112,7 +112,19 @@ cleanup() {
|
||||
trap cleanup EXIT
|
||||
|
||||
echo '- starting the stack'
|
||||
docker compose up -d --build >/dev/null 2>&1 || { echo "compose up failed"; exit 1; }
|
||||
# What compose said has to reach the log. `compose up failed` with the output
|
||||
# thrown away is the gate going blind at the one moment that decides whether the
|
||||
# rest of the run means anything — the same complaint OPEN-39 records about a
|
||||
# later assertion. Measured: on the Gitea runner this step failed after 5s and
|
||||
# the job log carried the words `compose up failed` and nothing else.
|
||||
UP_LOG=$(mktemp "${TMPDIR:-/tmp}/openwaf-compose-up.XXXXXX")
|
||||
if ! docker compose up -d --build >"$UP_LOG" 2>&1; then
|
||||
echo 'compose up failed — what compose said:'
|
||||
cat "$UP_LOG"
|
||||
exit 1
|
||||
fi
|
||||
rm -f "$UP_LOG"
|
||||
|
||||
for _ in $(seq 1 120); do curl -fsS "$EDGE/healthz" >/dev/null 2>&1 && break; sleep 0.5; done
|
||||
|
||||
CID=$(docker compose ps -q edge)
|
||||
|
||||
@@ -66,7 +66,19 @@ cleanup() {
|
||||
trap cleanup EXIT
|
||||
|
||||
echo '- starting the stack'
|
||||
docker compose up -d --build >/dev/null 2>&1 || { echo 'compose up failed'; exit 1; }
|
||||
# What compose said has to reach the log. `compose up failed` with the output
|
||||
# thrown away is the gate going blind at the one moment that decides whether the
|
||||
# rest of the run means anything — the same complaint OPEN-39 records about a
|
||||
# later assertion. Measured: on the Gitea runner this step failed after 5s and
|
||||
# the job log carried the words `compose up failed` and nothing else.
|
||||
UP_LOG=$(mktemp "${TMPDIR:-/tmp}/openwaf-compose-up.XXXXXX")
|
||||
if ! docker compose up -d --build >"$UP_LOG" 2>&1; then
|
||||
echo 'compose up failed — what compose said:'
|
||||
cat "$UP_LOG"
|
||||
exit 1
|
||||
fi
|
||||
rm -f "$UP_LOG"
|
||||
|
||||
for _ in $(seq 1 120); do
|
||||
[ "$(docker compose ps -q edge | xargs docker inspect --format '{{.State.Health.Status}}')" = healthy ] && break
|
||||
sleep 0.5
|
||||
|
||||
Reference in New Issue
Block a user