Skip to content

Commit bbf5db8

Browse files
committed
ci/e2e: pipeline hardening and fixes
1 parent 4f096a2 commit bbf5db8

1 file changed

Lines changed: 36 additions & 5 deletions

File tree

.github/workflows/ci.yml

Lines changed: 36 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -255,21 +255,41 @@ jobs:
255255
256256
- name: Populate deterministic demo content
257257
run: |
258-
curl -fsS -X POST http://localhost:9999/api/schedule/demo-sources/run
258+
timeout 180 bash -c '
259+
until response="$(curl -fsS -X POST \
260+
http://localhost:9999/api/schedule/demo-sources/run)" \
261+
&& grep -Eq "\"result\"[[:space:]]*:[[:space:]]*\"triggered\"" \
262+
<<<"$response"; do
263+
sleep 3
264+
done
265+
printf "%s\n" "$response"
266+
'
259267
timeout 180 bash -c '
260268
until curl -fsS \
261269
-o /tmp/llar-demo-items.html \
262270
http://localhost:8023/reader/group/source-tag/demo/source/all/items \
263-
&& grep -q "Local-first tools" /tmp/llar-demo-items.html; do
271+
&& grep -q "Local-first tools" /tmp/llar-demo-items.html \
272+
&& grep -q "Designing for ownership" /tmp/llar-demo-items.html \
273+
&& grep -q "Community archives rediscover" /tmp/llar-demo-items.html \
274+
&& grep -q "The software that keeps working" /tmp/llar-demo-items.html; do
275+
sleep 3
276+
done
277+
'
278+
timeout 180 bash -c '
279+
until response="$(curl -fsS -X POST \
280+
http://localhost:9999/api/schedule/update-todays-vibe/run)" \
281+
&& grep -Eq "\"result\"[[:space:]]*:[[:space:]]*\"triggered\"" \
282+
<<<"$response"; do
264283
sleep 3
265284
done
285+
printf "%s\n" "$response"
266286
'
267-
curl -fsS -X POST http://localhost:9999/api/schedule/update-todays-vibe/run
268287
timeout 180 bash -c '
269288
until curl -fsS \
270289
-o /tmp/llar-demo-vibe.html \
271290
http://localhost:8023/reader/tools/todays-vibe \
272-
&& grep -q "data-vibe-cluster-id" /tmp/llar-demo-vibe.html; do
291+
&& grep -Eq "data-vibe-source-count=\"([2-9]|[1-9][0-9]+)\"" \
292+
/tmp/llar-demo-vibe.html; do
273293
sleep 3
274294
done
275295
'
@@ -286,7 +306,7 @@ jobs:
286306
curl -fsS -o /tmp/llar-demo-gems.html 'http://localhost:8023/reader/tools/gems?browse=true'
287307
grep -q "A new night-train map" /tmp/llar-demo-gems.html
288308
curl -fsS -o /tmp/llar-demo-vibe.html http://localhost:8023/reader/tools/todays-vibe
289-
grep -q "data-vibe-cluster-id" /tmp/llar-demo-vibe.html
309+
grep -Eq 'data-vibe-source-count="([2-9]|[1-9][0-9]+)"' /tmp/llar-demo-vibe.html
290310
curl -fsS -o /tmp/llar-demo-image.svg http://localhost:8023/static/demo/local-first.svg
291311
grep -q "LOCAL FIRST" /tmp/llar-demo-image.svg
292312
@@ -322,6 +342,17 @@ jobs:
322342
if-no-files-found: ignore
323343
retention-days: 7
324344

345+
- name: Upload compose E2E response diagnostics
346+
if: failure()
347+
uses: actions/upload-artifact@v4
348+
with:
349+
name: compose-e2e-responses
350+
path: |
351+
/tmp/llar-demo-*.html
352+
/tmp/llar-demo-*.svg
353+
if-no-files-found: ignore
354+
retention-days: 7
355+
325356
- name: Compose logs
326357
if: always()
327358
run: docker compose logs --no-color

0 commit comments

Comments
 (0)