stack-orchestrator/stack_orchestrator/deploy/k8s
Prathamesh Musale 774b39836e so-l2l: refactor down() for clarity
down() is now a five-phase recipe with each phase a single line:
namespaced cleanup, cluster-scoped PV cleanup, synchronous wait,
optional namespace delete, optional cluster destroy. Each helper
does one thing.

- Extract _stack_label_selector() and _namespace_exists() so down()
  reads declaratively.
- Rename _delete_labeled_resources -> _delete_namespaced_labeled_
  resources to match what it actually does (namespaced phase only).
- Extract _list_delete_namespaced() helper for the Services and
  Endpoints list+delete pattern (k8s client lacks delete_collection
  for those kinds).
- _wait_for_labeled_gone (renamed from _wait_for_labeled_deletions)
  builds listers in clean append-style; DRY the poll/timeout
  iterations via a local remaining() closure.

No behavior changes — same semantics, ~50 fewer lines.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-16 06:10:56 +00:00
..
helm Fix pyright type errors across codebase 2026-01-22 01:10:36 -05:00
__init__.py Rename app -> stack_orchestrator (#625) 2023-11-07 00:06:55 -07:00
cluster_info.py so-l2l Part B: down() deletes by stack label, keeps namespace 2026-04-15 13:17:13 +00:00
deploy_k8s.py so-l2l: refactor down() for clarity 2026-04-16 06:10:56 +00:00
helpers.py Fix Kind port mappings and configmap source path resolution (#742) 2026-04-14 17:33:47 +05:30
k8s_command.py Apply pre-commit linting fixes 2026-01-21 20:58:31 -05:00