forked from mtusi2026/mtusi2026lab7
lab7: mTLS-границы, OpenBao raft, TLS-телеметрия, evidence уровней 3-4
This commit is contained in:
@@ -5,7 +5,7 @@
|
||||
* при первом запуске создаются unseal-ключи (5/3) и root token; файл
|
||||
secrets/openbao-init.json создаётся с правами 0600 и никогда не попадает в Git;
|
||||
* unseal выполняется этим же скриптом после рестарта OpenBao (seal state
|
||||
не переживает рестарт, данные в file storage — переживают);
|
||||
не переживает рестарт, данные в raft storage — переживают);
|
||||
* root token используется только здесь; приложение получает role_id и
|
||||
короткоживущий secret_id и ходит в OpenBao по scoped policy.
|
||||
|
||||
@@ -74,7 +74,9 @@ def wait_health(seconds=90):
|
||||
while True:
|
||||
try:
|
||||
return health()
|
||||
except SystemExit as exc: # req() raises SystemExit on transport errors
|
||||
except (SystemExit, urllib.error.URLError, ConnectionError, ssl.SSLError) as exc:
|
||||
# SystemExit — HTTP-код не из ok; URLError/ConnectionError — сервер
|
||||
# ещё не слушает (raft поднимается дольше file storage).
|
||||
last = exc
|
||||
if time.monotonic() >= deadline:
|
||||
raise SystemExit("openbao is not reachable in %ss: %s" % (seconds, exc))
|
||||
|
||||
Reference in New Issue
Block a user