Run CLI P2P E2E in Compose CI

This commit is contained in:
vorotamoroz
2026-07-09 02:02:02 +00:00
parent af72cac4e3
commit b9a27ffef9
5 changed files with 81 additions and 14 deletions
+24 -12
View File
@@ -1,24 +1,21 @@
# Run the Compose-packaged CLI P2P smoke benchmark.
#
# This workflow is intentionally non-required at first. It exercises the local
# Compose package for CouchDB + Nostr relay + CLI runner, and uploads the
# benchmark JSON results for inspection.
# This workflow is intentionally manual-only. It exercises the local Compose
# package for CouchDB + Nostr relay + CLI runner, and uploads the benchmark JSON
# results for inspection without adding benchmark work to pull-request CI.
name: cli-p2p-compose-smoke
on:
pull_request:
paths:
- '.github/workflows/cli-p2p-compose-smoke.yml'
- 'package.json'
- 'package-lock.json'
- 'src/apps/cli/**'
- 'test/bench-network/**'
workflow_dispatch:
inputs:
cases:
description: 'Comma-separated benchmark cases'
required: false
default: 'couchdb-baseline,p2p-direct-local'
signalling_cases:
description: 'Comma-separated signalling-shim P2P benchmark cases'
required: false
default: 'p2p-signalling-netem-home-wifi'
md_files:
description: 'Markdown file count'
required: false
@@ -63,13 +60,28 @@ jobs:
BENCH_PEERS_TIMEOUT: '20'
LIVESYNC_P2P_RELAY_READY_TIMEOUT_MS: '60000'
BENCH_LIVESYNC_TEST_TEE: '0'
run: docker compose -f test/bench-network/compose.yml run --rm bench-runner
run: docker compose -f test/bench-network/compose.yml run --build --rm bench-runner
- name: Run Compose P2P signalling-shim smoke benchmark
env:
BENCH_CASES: ${{ inputs.signalling_cases || 'p2p-signalling-netem-home-wifi' }}
BENCH_MD_FILE_COUNT: ${{ inputs.md_files || '2' }}
BENCH_MD_MIN_SIZE_BYTES: '128'
BENCH_MD_MAX_SIZE_BYTES: '256'
BENCH_BIN_FILE_COUNT: ${{ inputs.bin_files || '1' }}
BENCH_BIN_SIZE_BYTES: '512'
BENCH_SYNC_TIMEOUT: '180'
BENCH_PEERS_TIMEOUT: '60'
LIVESYNC_P2P_RELAY_READY_TIMEOUT_MS: '60000'
BENCH_LIVESYNC_TEST_TEE: '0'
NETEM_PROFILE: 'home-wifi'
run: docker compose -f test/bench-network/compose.yml --profile signalling-shim run --build --rm bench-runner-signalling-shim
- name: Show Compose diagnostics
if: failure()
run: |
docker compose -f test/bench-network/compose.yml ps
docker compose -f test/bench-network/compose.yml logs --no-color couchdb nostr-relay
docker compose -f test/bench-network/compose.yml --profile signalling-shim logs --no-color couchdb nostr-relay p2p-signalling-shim || true
- name: Upload benchmark results
if: always()