Use dynamic host ports in the E2E runner

Aperta
#2,395 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
4/5
Tempo stimato
3-5 giorni
Idoneità per principianti
55/100
Tipo di issue
Funzionalità
Chiarezza
Specificata chiaramente
Stato di attività
Attiva
Stack tecnologico
docker, rust
Ambito
backend, devops

Direzione di ricerca

Start with src/console/ci/e2e/runner.rs and the qBittorrent E2E runner's existing dynamic-port handling; the issue names both as reference points. Add unit tests for TCP/UDP port discovery and address translation, then run the E2E tests, including two concurrent runs. Done means the checker uses discovered host addresses and docs/self-hosted-runner.md no longer lists fixed host ports as a concurrency limit.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

task Testing

Parent EPIC: #2392

Goal

Two e2e_tests_runner executions can run at the same time on one Docker host without colliding on host ports. The runner lets Docker choose free host ports and discovers them, instead of publishing fixed host ports.

Background

src/console/ci/e2e/runner.rs publishes fixed host ports 6969:6969/udp, 7070:7070/tcp, 1212:1212/tcp, and 1313:1313/tcp, parses the tracker's startup log for service addresses, and passes them to the tracker checker. This works only because host and container ports are identical; a second run on the same host cannot publish the ports. The runner already notes this in a code-review comment, and #2386 lists it as a reason for one runner instance per server.

Container names are already random, and the qBittorrent E2E runner already publishes host port 0 and reads the assigned port with docker compose port.

Tasks

  • T1: Reproduce the conflict with two concurrent runs.
  • T2: Add docker port discovery (TCP and UDP) with unit tests.
  • T3: Translate parsed container addresses to host addresses, with unit tests.
  • T4: Publish container ports only and run the checker on discovered host addresses.
  • T5: Verify two concurrent runs pass; remove fixed host ports from the concurrency limits in docs/self-hosted-runner.md.

Out of scope: the shared image tag (sibling subissue), the qBittorrent E2E runner, the shared Cargo target directory.

The full specification is added to docs/issues/open/ by a spec-only pull request.

Lingua principale
Rust
Stelle
532
Fork
56
Merge medio
11h 20m
PR unite (30g)
282

Preparare l'ambiente

Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di torrust/torrust-tracker

Tutte le issue di torrust/torrust-tracker

Issue simili

Altre issue su Rust

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.