forked from mtusi2026/mtusi2026lab7
wip: apply pki-ingress-mtls groups 1-4
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,26 @@
|
||||
# X-Instance-Id — случайный alias процесса (change `pki-ingress-mtls`)
|
||||
|
||||
Дата: 2026-11-16. Спек `api-conventions`, «Instance id — случайный alias», спек
|
||||
`service-configuration`, «Идентификатор экземпляра процесса», спек `load-balancing`,
|
||||
«Failover hook»; design, решение 9.
|
||||
|
||||
## Красный прогон до кода (задача 2.1)
|
||||
|
||||
Стенд — `make run_docker` на `44fe711` (приложение и compose до change: HTTP на
|
||||
`127.0.0.1:8080`, `X-Instance-Id` = hostname контейнера), тест
|
||||
`test_instance_id_is_random_alias` — из рабочего дерева:
|
||||
|
||||
```
|
||||
$ BASE_URL=http://localhost:8080 EXPECT_REPLICAS=2 uv run pytest student-tests -k "alias or coverage"
|
||||
student-tests/test_api_conventions.py::test_instance_id_is_random_alias FAILED
|
||||
E AssertionError: X-Instance-Id '808684c7392c' is not a 16 hex character alias
|
||||
…
|
||||
$ docker compose ps api --format '{{.Name}} {{.ID}}'
|
||||
mtusi-lab7-api-1 efb4060010a5
|
||||
mtusi-lab7-api-2 808684c7392c
|
||||
```
|
||||
|
||||
Значение — 12 символов, начало ID контейнера `mtusi-lab7-api-2` (его hostname). В том же
|
||||
прогоне `test_every_scenario_is_covered` называет маркер нового сценария неизвестным: сценарий
|
||||
есть только в дельте change, в основной спек он попадёт при архивации (`QUESTIONS.md`,
|
||||
`## pki-ingress-mtls`).
|
||||
Reference in New Issue
Block a user