Skip to content

feat(k8s): build deploy-stack manifests from the Applications #6681

Closed

Description

@dan-petty

Problem

Checked at devops-cli main 4ff4b7c.

  • deploy-stack applies fixed raw paths of the environment tree with kubectl apply -f (src/devops_cli/commands/k8s/stack_lifecycle.py:278-312, MANIFESTS_BY_STACK: the NetworkPolicies of argocd, argo-workflows, otel, llm, logging and gitea, the 3 Valkey files, portkey, the ingress routes and agents; used at :1204 and :1257).
  • The infra plan rebuilds some of them from infra components and bases at tags: the default perimeters (dan-petty/homelab#87), the Open WebUI Valkey (dan-petty/homelab#88) and the Argo CD NetworkPolicy (dan-petty/homelab#94). A fixed file is then missing or holds only part of the objects. feat(k8s): take deploy-stack value files from the Applications #6680 covers only the Helm value files.
  • devops_cli.k8s.app_render.render_path_source already builds a path source of an Argo CD Application with Kustomize, as devops k8s image-pins builds it. It fetches a source of another public repository at its revision, and a dry run fetches nothing (app_render.py docstring).
  • src/devops_cli/commands/ai_runs.py:127 names k8s/llm/valkey-runs.yaml, which this plan does not change.

Proposed remedy

Reuse app_render. deploy-stack applies the builds of the path sources of the Applications of each stack, in place of the fixed lists of MANIFESTS_BY_STACK. One table maps each stack to its Applications. PRODUCT_MANIFESTS_BY_STACK does not change.

  • Check the premise first: if the build of an Application holds objects that the fixed list leaves out, write the difference in the PR and keep the fixed list for that stack.
  • Write the tests first, with a fixture Application and a tmp_path tree that uses a local Kustomize component.

Acceptance criteria

  • A new test fails on main and passes on the branch: a fixture path source with a component gives the objects of its build.
  • On the current tree, uv run devops k8s deploy-stack --dry-run prints the same objects (kind and name) for each stack as on main, or the PR lists each difference with its reason.
  • uv run devops ci --check --only test,lint,typecheck passes.

Person steps

None.

Dependencies

None. It lands before dan-petty/homelab#87, dan-petty/homelab#88 and dan-petty/homelab#94.

Alternatives check of 2026-11-21: none.
Tool: none found.
Reason: Searches returned only unrelated web-platform pages and named no tool. The need is an internal refactor of devops-cli's deploy-stack to reuse its own app_render path-source builds, which no external tool covers.

Lacks:

  • Reuse of app_render path-source builds in deploy-stack
  • One per-stack table mapping stacks to Applications
  • Dry-run parity of objects with the fixed manifest lists

Activity

  1. added
    type/feature
    scope/k8s
    source/agent
    status/new
    value/medium
    effort/medium
    on Nov 21, 2026
  2. dan-petty commented on Nov 21, 2026

    @dan-petty
    OwnerAuthor
  3. added
    priority/p2-medium
    on Nov 21, 2026
  4. devops-cli-service commented on Nov 21, 2026

    @devops-cli-service
    Contributor

    The result in the alternatives block of the issue body changed. Before this check: no check. A person decides what the new result means for the item.

    Searches (6)

    Searches run:

    • render Kubernetes manifests from Argo CD Application source without a cluster, results: 5
    • tool builds kustomize manifests of Argo CD Applications offline CLI, results: 5
    • argocd app manifests command render application manifests, results: 5
    • kustomize build remote git repository path tool, results: 5
    • kubernetes manifest renderer application source kustomize helm, results: 5
    • Argo CD, results: 5
  5. added
    owner/agent
    status/in-progress
    and removed
    status/new
    on Nov 21, 2026
  6. 15 remaining items

  7. added
    status/in-review
    and removed
    status/in-progress
    on Nov 22, 2026
  8. removed
    status/in-review
    owner/agent
    on Nov 22, 2026
  9. devops-cli-service commented on Nov 22, 2026

    @devops-cli-service
    Contributor

    Live since 2026-11-22 03:31 UTC

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    effort/mediumpriority/p2-mediumscope/k8ssource/agenttype/featurevalue/medium

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions