docs(jupyterhub): clean up docs

This commit is contained in:
Masaki Yatsu
2025-09-08 18:44:25 +09:00
parent 4df776c181
commit 9d5bcba522

View File

@@ -255,7 +255,7 @@ The admin token renewal is handled by a sidecar container (`vault-agent`) runnin
```bash ```bash
# Reads TTL from environment variable (set in .env.local) # Reads TTL from environment variable (set in .env.local)
TTL_RAW="${JUPYTERHUB_VAULT_TOKEN_TTL}" # e.g., "5m", "24h" TTL_RAW="${JUPYTERHUB_VAULT_TOKEN_TTL}" # e.g., "5m", "24h"
# Converts to seconds and calculates renewal interval # Converts to seconds and calculates renewal interval
RENEWAL_INTERVAL=$((TTL_SECONDS / 2)) # TTL/2 with minimum 30s RENEWAL_INTERVAL=$((TTL_SECONDS / 2)) # TTL/2 with minimum 30s
``` ```
@@ -300,7 +300,7 @@ User token renewal is handled within the notebook environment by the `buunstack`
token_info = self.client.auth.token.lookup_self() token_info = self.client.auth.token.lookup_self()
ttl = token_info.get("data", {}).get("ttl", 0) ttl = token_info.get("data", {}).get("ttl", 0)
renewable = token_info.get("data", {}).get("renewable", False) renewable = token_info.get("data", {}).get("renewable", False)
# Renew if TTL < 10 minutes and renewable # Renew if TTL < 10 minutes and renewable
if renewable and ttl > 0 and ttl < 600: if renewable and ttl > 0 and ttl < 600:
self.client.auth.token.renew_self() self.client.auth.token.renew_self()