tests/e2e: brownfield, Docker live-restore with no container restart (tests #118)

Aperta
#147 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 2 giorni

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
4/5
Tempo stimato
3-5 giorni
Idoneità per principianti
48/100
Tipo di issue
Funzionalità
Chiarezza
Specificata chiaramente
Stato di attività
Attiva
Stack tecnologico
bash, debian, docker, shell, ubuntu
Ambito
devops, testing

Direzione di ricerca

Start with tests/e2e/scenarios-brownfield.sh and the setup-brownfield fixture added by #124; review #118 and #141 for the live-restore and older Docker setup. Add the scenario’s extra daemon.json fixture and older docker-ce, then run the brownfield end-to-end scenario. Done means its checklist passes, including unchanged container start time through the package upgrade and the audit and fresh-server cases.

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

Descrizione

area: ci area: prep claude enhancement priority: high size: M

Epic #121 · Tests #118 (epic #109) · Milestone Phase 5: Servers already in use · Priority high · Size M · Depends on #118, #124


Why

#118 turns on live-restore with a reload instead of a restart, so containers keep running, and makes the next Docker upgrade safe too.

Scenarios go in tests/e2e/scenarios-brownfield.sh (profile added by #124) and reuse its fixture from setup-brownfield: nginx on 80/443 with a token page, a container -p 8080:80, a deploy user with a key, the 50-site.conf drop-in, UFW with its own rules, a custom fail2ban jail, ptrace_scope = 0, and a "panel" root login on 22 before the run. Extra fixture listed below is added by this issue only.

Extra fixture

  • /etc/docker/daemon.json with a key of the site's own ("dns": ["9.9.9.9"]).
  • The older docker-ce from the #141 test.

Scenario docker-live-restore

  • --existing --yes --only docker: docker info --format '{{.LiveRestoreEnabled}}' is true; the container ID and StartedAt are unchanged; dockerd's ExecMainStartTimestamp is unchanged (a reload, not a restart); daemon.json keeps dns and has the log options.
  • The point of live-restore: then upgrade docker-ce with apt; the container StartedAt is still unchanged and the token on 8080 still answers.
  • Docker Desktop context: with a root context set to a dead socket (docker context create e2e --docker host=unix:///nonexistent + use), the step switches to default and succeeds.
  • Debian only: with distro docker.io instead of Docker CE, the step notes it and adds no docker apt source.
  • Audit: dock.live_restore is PASS here and INFO on a fresh server without it (never WARN or FAIL).
  • With --existing, DOCKER_AUTO_UPDATE is saved as yes only once live-restore is active.
  • Fresh path: --yes --only docker does not restart Docker without a yes (after #65).

Acceptance criteria

  • Removing live-restore from the jq merge turns the upgrade assertion red.
Lingua principale
Shell
Stelle
2
Fork
3
Merge medio
2g 14m
PR unite (30g)
47

Preparare l'ambiente

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 exceev-consulting/server-prep

Tutte le issue di exceev-consulting/server-prep

Issue simili

Altre issue su Shell/Bash

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.